tags:

views:

57

answers:

1

In GWT I am using the following CSS to apply a format:

.watchListHeader {
  background-color: #2062B8;
  color: white;
  font-style: italic;
}

Here is what I get when I apply the format in two different ways.

stocksFlexTable.getColumnFormatter().addStyleName(0, "watchListHeader");

alt text

stocksFlexTable.getRowFormatter().addStyleName(0, "watchListHeader");

alt text

Here is a link to the JavaDocs. Under ColumnFormatter it briefly mentions limitations... does this mean this is expected behavior? Seems to me formatting by column is nearly useless if I can't even format the text! Is there an easy workaround?

+1  A: 

Ok I found the answer to my question. It is detailed very well at the following site. http://www.quirksmode.org/css/columns.html

In summary:

  • In general row formatting overrides column formatting
  • W3C specifies that only border, background, width and visibility may can be used. Exception: IE7 and lower allow all declarations.
  • Background color and width are the only two that are fully supported across browsers and not quirky.
Derek Litz