Hacker News new | ask | show | jobs
by pohl 5594 days ago
...it seems like it would be very difficult to layout and design a web front-end from within Java code alone.t seems like it would be very difficult to layout and design a web front-end from within Java code alone.

You don't have to, and you're not necessarily even supposed to. You work with DOM elements and CSS styles just as you would anyway. Every Widget in GWT inherits from the UIObject class. Each instance corresponds to exactly one tag in your DOM, and has methods for getting/setting styles. Your java code would just handle putting the element where you want it in the DOM, and setting the style(s). The layout is in your CSS, just as usual.