I've inherited a GWT project that uses Panels and Panels beyond belief, all of which generated tons开发者_如何学Go of nested tables. I want to style this program and to do so, I'd like to have all of my elements become <div>
's so I can CSS style them properly -- can someone tell me how to go about doing that? Are there widgets in GWT that don't use tables, etc?
Googling for [gwt panels] I found this page which lists which panels are backed by tables and which are backed by divs. You should start by eliminating panels which are purely holding other panels, or nothing at all. Then, if you can, refactor panels that use tables to ones that use divs.
You can use the div based widgets such as FlowPanels and do your layout in css if you want to avoid tables. It works well for me. use getElement.setId() for setting the id of your panel.
精彩评论