I found another related problem, as shown in the attachment, if the row is 
highlighted, the font color is white, which is difficult to see under 
yellow background color, how to change the color property when the row is 
selected?

On Wednesday, June 20, 2012 6:36:49 PM UTC+8, tong123123 wrote:
>
> there is some progress, I use the code as follow:
>
>> // set RowStyles
>> table.setRowStyles(new RowStyles<Log>(){
>> @Override
>> public String getStyleNames(Log row, int rowIndex) {
>> if (row.getSeverity_cd().equalsIgnoreCase("W ")){
>>     return "warning";
>> }else if (row.getSeverity_cd().equalsIgnoreCase("C ")){
>>     return "critical";
>> }else
>>     return null;
>> } 
>> });
>>
>
> and the result is shown as attached.
>
> just feel the css need use something like following:
> .critical{
>    background-color:red !important;
> }
>
> which seem not normal css syntax (!important). 
>
> and I do not know where is the origin rowStyle come from (at first, I want 
> to use CellTable.getRowStyles in else part but found not this api and so 
> return null, so lucky the origin style still preserve, that is, if the 
> row.getSeverity_cd() equals to other character than 'W ', 'C ', the origin 
> style can preserve, but I do not know the background machanism).
>
>  
>
>
>
>
>
>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/ai8tH-esP88J.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to