-
3 Oct 2011 3:14 AM #1
Answered: Different row styles in a grid
Answered: Different row styles in a grid
Hello everybody,
How can I make rows in the grid look different depending on some condition? I mean smth like that:
HTML Code:<table> <tr class="class1">...</tr> <tr class="class2">...</tr> </table>
-
Best Answer Posted by sven
You can set a custom GridViewConfig to your GridView. In that you need to override the getRowStyle method
-
3 Oct 2011 3:20 AM #2
You can set a custom GridViewConfig to your GridView. In that you need to override the getRowStyle method
-
3 Oct 2011 4:12 AM #3
From the documentation:
getRowStyle ( ModelData model, int rowIndex, ListStore<ModelData> ds ) : java.lang.String Returns one to many CSS style names separated by spaces.
How should I use it? I thought I needed an opposite method, smth like setRowStyle, didn't I?
-
3 Oct 2011 4:21 AM #4
Simple extend GridViewConfig and override that method. In that method you can return the styles you want to display.
-
4 Oct 2011 2:48 AM #5
I've got it. Thank you, Sven.
Is it possible to make an "hover" pseudo-class or some acronym in the stylesheet then?


Reply With Quote