PDA

View Full Version : Layout components next to each other and then in new row



dekel.y
17 Apr 2014, 3:15 AM
Hi All,
I have unknown number of buttons and a panel.
I would like to place the buttons in a row but when overflow, move the rest of the buttons to a new row.
can anyone assist? I'm not familiar with any such layout.

Thanks
Dekel

Farish
17 Apr 2014, 4:13 AM
you can use the column layout: http://docs.sencha.com/extjs/4.0.7/#!/api/Ext.layout.container.Column

when the columnWidth sum exceeds 1.0, it will automatically move the next component to next row.

dekel.y
1 May 2014, 5:07 AM
column layout is not enough because I need to know number of columns.
I just want to add components and when reached the border of the panel, start a new row.

Dekel

dekel.y
1 May 2014, 6:26 AM
Found it.
use column layout but do not specify columnWidth