I've looked through the forums without finding any usable information regarding this issue, so I'll go ahead and explicitly ask the question.
I'm evaluating how much effort it would take to migrate our existing GWT application to using SmartGWT and came across this conundrum.
I have VLayout which contains a HLayout, which in turn contains two GWT widgets, a Hyperlink and an Anchor. The code looks something like this:
The problem is that the two GWT widgets end up spaced widely apart. Examining the page through Firebug, I discovered that the widgets are placed inside WidgetCanvases with default widths of 100px.
My question is: why set the width to an arbitrary value like that? What's the reasoning behind that implementation? And what solution do I have to remove the default, other than explicitly wrapping every single GWT widget I use inside a sized WidgetCanvas?
For the record, I'm using Smart GWT 3.0, GWT 2.3.0 and Firefox 3.5.3.
I'm evaluating how much effort it would take to migrate our existing GWT application to using SmartGWT and came across this conundrum.
I have VLayout which contains a HLayout, which in turn contains two GWT widgets, a Hyperlink and an Anchor. The code looks something like this:
Code:
Label userLabel = new Label("Welcome, user"); userLabel.setAlign(Alignment.RIGHT); userLabel.setAutoHeight(); userLabel.setWidth100(); Hyperlink link = new Hyperlink("My Profile"); Anchor anchor = new Anchor("Help"); HLayout links = new HLayout(); links.setAlign(ALignment.RIGHT); links.setAutoHeight(); links.setWidth100(); links.setMembersMargin(10); links.addMember(link); links.addMember(anchor); VLayout titlePanel = new VLayout(); titlePanel.setHeight(60); titlePanel.setWidth100(); titlePanel.setMembersMargin(5); titlePanel.setPadding(5); titlePanel.addMember(userLabel); titlePanel.addMember(links);
My question is: why set the width to an arbitrary value like that? What's the reasoning behind that implementation? And what solution do I have to remove the default, other than explicitly wrapping every single GWT widget I use inside a sized WidgetCanvas?
For the record, I'm using Smart GWT 3.0, GWT 2.3.0 and Firefox 3.5.3.
Comment