-
6 Feb 2012 12:52 PM #11
Konstantin Scheglov
-
6 Feb 2012 12:55 PM #12
Sorry, you are correct. You are missing the center region completly, which is required to position it at the south. The layout method is not doing anything without a center widget defined.
Code:public class ImageViewer implements EntryPoint { public void onModuleLoad() { RootPanel rootPanel = RootPanel.get(); { NorthSouthContainer container = new NorthSouthContainer(); container.setBorders(true); rootPanel.add(container, 10, 10); container.setWidget(new HTML()); container.setSize("250px", "200px"); // "south" rendered on "north", not stretched horizontally container.setSouthWidget(new Button("SSSSSSSSSSSS")); } } }
-
6 Feb 2012 1:00 PM #13
1. Why I do this? Because I can. GXT 3 is about making things easier and safer, right? :-)
2. I've tried to add container after setting south widget. No difference.
Screenshot_20120206_155833.jpgKonstantin Scheglov
-
6 Feb 2012 1:04 PM #14
You should not write your code in a way that forces two layoutchains, as this will always end in being slow. Before adding something to the rootpanel, first build it completly. The good thing is that GXT alraedy caches multiple layout chains.
However a NorthSouthContainer always requires the center region, please see the edited post.
-
6 Feb 2012 1:09 PM #15
I updated the code to update atleast the width if no center region is specified, this change is in SVN now. However the south part will always be displayed under the center region. If there is no, than its under the north region. If that is also missing than its the top part.
-
6 Feb 2012 1:10 PM #16
OK, thank you for help and fixes.
Konstantin Scheglov
-
6 Feb 2012 1:19 PM #17
The change will be in the next beta release.
Thank you for reporting this bug. We will make it our priority to review this report.


Reply With Quote