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 http://img443.imageshack.us/img443/3958/columnformat.png
stocksFlexTable.getRowFormatter().addStyleName(0, "watchListHeader");
alt text http://img508.imageshack.us/img508/4986/rowformat.png
Here is a link to the JavaDocs. Under ColumnFormatter it briefly mentions limitations... does this mean this is ex开发者_如何学运维pected behavior? Seems to me formatting by column is nearly useless if I can't even format the text! Is there an easy workaround?
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.
精彩评论