Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
520
AppStylist with Infragistics Grids
posted

I have several different types of Grids in my application.  Some display data rows from which the user choosers a row,  Others are simply for display - there is nothing to select.  Others allow the user to edit data in the grid.  Some allow single row selection.  Some allow multiple row selection.  Some have one column of data that can be edited, etc.

I can't seem to find a way to define my color theme to display colors logically to a user in all these cases.  What do you suggest?

Is there a way to define multiple color "themes" for a grid within the same theme?

An example of a need for a difference is with defining hover and selected colors.

If not, how do you suggest this be handled.  I currently have a grid that displays multiple rows of data.  Each row has a trashcan icon that when clicked will cause the row to be deleted.  The user can also select multiple rows and press a button to delete those rows.

The theme defines a hover color for cells in the grid and also selected colors, which looks great for other grids, but looks weird with this grid since data can not be edited. 

One possible solution I can think of is to create multiple classes derived from the UltraGrid and style them independently.  Does the AppStylist allow for the styling of these sort of classes?

If not, what do you suggest?

Andy

Parents
  • 467250
    Offline posted

    In a case like there, were it seems like you have a few distinct 'cases' or types of grids, the best way to handle it is probably to use StyleSets. 

    In AppStylist, you can open up your Style Library and there's a Default StyleSet that applies to everything. You could then define only the grid settings that you want to apply to ALL grids in the default StyleSet. 

    Then you can create additional StyleSets: one for each particular grid 'case'. So one for the editable grids, one for the non-editable grids, etc. The StyleSet can be 'based on' the default styleset (in which case it will pick up all the settings on the styleset and then only the properties you set on that styleset with override the defaults) or not, it's up to you. 

    Then, in your application, you set the grid.StyleSetName to the name of the StyleSet you want. 

Reply Children
No Data