1. #1
    Sencha User
    Join Date
    Aug 2010
    Posts
    35
    Vote Rating
    0
    Alona Oz is on a distinguished road

      0  

    Default Horizontal Layout with HBoxLayout

    Horizontal Layout with HBoxLayout


    I try to create a very simple example that draws labels and shows them one after one horizontally. For some reason it doesn't work, all labels are displayed vertically, below is my test code.

    Please help.

    Code:
    public class MYTest implements EntryPoint {
        public void onModuleLoad() {
     
            LayoutContainer c = new LayoutContainer();
            HBoxLayout layout = new HBoxLayout();
            layout.setPadding(new Padding(5));
            layout.setHBoxLayoutAlign(HBoxLayout.HBoxLayoutAlign.TOP);
            c.setLayout(layout);
            c.add(new Button("first"), new HBoxLayoutData(new Margins(0, 5, 0, 0)));
            c.add(new Button("second"), new HBoxLayoutData(new Margins(0, 5, 0, 0)));
     
            Viewport viewport = new Viewport();
            viewport.setLayout(new FitLayout());
            viewport.add(c);
            RootPanel.get().add(viewport);
        }
    }

  2. #2
    Software Architect
    Join Date
    Sep 2007
    Posts
    13,966
    Vote Rating
    130
    sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light

      0  

    Default


    This works fine for me:

    Are you sure that you have the needed css files in place?

  3. #3
    Sencha User
    Join Date
    Aug 2010
    Posts
    35
    Vote Rating
    0
    Alona Oz is on a distinguished road

      0  

    Default


    Yes, that was the problem
    10x

Similar Threads

  1. [FIXED-469] 0.98 Ext.layout.HBoxLayout invaild file
    By mrsunshine in forum Sencha Touch 1.x: Bugs
    Replies: 2
    Last Post: 7 Nov 2010, 8:16 PM
  2. [CLOSED] Bug in layout HBoxLayout
    By ionut.rachita in forum Ext GWT: Bugs (2.x)
    Replies: 6
    Last Post: 21 Apr 2010, 7:51 AM
  3. Replies: 8
    Last Post: 27 May 2009, 2:08 AM
  4. How to have 50%-50% horizontal layout
    By bereal in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 27 Aug 2008, 5:10 AM

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar