Auto sizing dock layout controls

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Auto sizing dock layout controls

deniska
I have a composite I need to add 2 composites to. One composite has fixed height and I want it at the south edge. Second one should fill the rest of the layout. I've tried using south and north edges, but I still have an empty space in the middle of the layout. Also tried to find example in Demo Browser, but all examples there seem to have controls at all edges, while I have only 2.

Would appreciate any help.
Thanks in advance,
Denis.
Reply | Threaded
Open this post in threaded view
|

Re: Auto sizing dock layout controls

Derrell Lipman
On Tue, May 29, 2012 at 8:32 AM, deniska <[hidden email]> wrote:
I have a composite I need to add 2 composites to. One composite has fixed
height and I want it at the south edge. Second one should fill the rest of
the layout. I've tried using south and north edges, but I still have an
empty space in the middle of the layout. Also tried to find example in Demo
Browser, but all examples there seem to have controls at all edges, while I
have only 2.

The easiest way to accomplish that is to use a VBox layout instead, and use it like this:


var vBox = new qx.ui.container.Composite(new qx.ui.layout.VBox());

// create north container. Specify layout and add contents
var north = new qx.ui.container.Composite();


// create south container. Specify layout and add contents
var south = new qx.ui.container.Composite();

// Add the north container with flex to take up available space
vBox.add(north, { flex : 1 });

// Add south container without flex, to take up only as much
// space as it requires
vBox.add(south);


------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
qooxdoo-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
Reply | Threaded
Open this post in threaded view
|

Re: Auto sizing dock layout controls

deniska
That solves my problem.

Many thanks.