I'm trying to use xul to create a lay out like this:
- there is a box contains of a tree of data
there is a box containing some buttons right below the previous box.
I decided to use because otherwise the second box will be put right next to the first one (unless I use vbox). The problem is no matter what value I assign to flex, the box does not stretch out fully as I want. It only takes a small space at the left corner, not the whole window. Can someone help me with this please?
My code is as follow:
<!-- there're 2 rows, 1 for data, 1 for toolbar --> <rows> <!-- row 1 is for a tree of data --> <row flex="1"> <vbox flex="1"> <tree id="MyTree" flex="1" height="1" width="1"> <treecols> <treecol flex="1" label="Column1"/> <treecol flex="1" label="Column2"/> </treecols> <treehead> <treerow> <treecell label="Name"/> <treecell label="Address"/> </treerow> </treehead> <treechildren flex="1"> <treeitem container="true" open="true"> <treerow> <treecell class="treecell-indent" label="Group 1"/> </treerow> <treechildren> <treeitem> <treerow> <treecell class="treecell-indent" label="Item 1"/> <treecell label="xyz"/> <treecell label="adfjakdhk"/> </treerow> </treeitem> </treechildren> </treeitem> </treechildren> </tree> </vbox> </row> <!-- row 2 is for tool bar--> <row> <!--buttons are here--> </row> </rows> </grid>