Page 2 of 2 FirstFirst 12
Results 11 to 17 of 17

Thread: Beta 1 - NorthSouthContainer behavior different from TopBottomComponent of DP5?

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #11
    Sencha User
    Join Date
    Jan 2009
    Posts
    46
    Vote Rating
    0
      0  

    Default

    Adding container.forceLayout() does not help.

    Screenshot_20120206_155127.jpg
    Konstantin Scheglov

  2. #12
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Vote Rating
    131
      0  

    Default

    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"));
          }
        }
      }

  3. #13
    Sencha User
    Join Date
    Jan 2009
    Posts
    46
    Vote Rating
    0
      0  

    Default

    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.jpg
    Konstantin Scheglov

  4. #14
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Vote Rating
    131
      0  

    Default

    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.

  5. #15
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Vote Rating
    131
      0  

    Default

    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. #16
    Sencha User
    Join Date
    Jan 2009
    Posts
    46
    Vote Rating
    0
      0  

    Default

    OK, thank you for help and fixes.
    Konstantin Scheglov

  7. #17
    Sencha Premium Member
    Join Date
    Sep 2007
    Posts
    13,976
    Vote Rating
    131
      0  

    Default

    The change will be in the next beta release.

Page 2 of 2 FirstFirst 12

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •