PDA

View Full Version : listWidget resize



buckadl
12th June 2007, 16:08
Hi all,

I have a simple dialog I am trying to create in QtDesigner. What I have so far is a ToolBox and a StackedWidget layed out in a horizontal layout. As I resize the dialog, the ToolBox expands to a maximum width and stops, while the StackedWidget continues to grow to fill the remaining horizontal space. This all works as I had hoped.

On one page of the StackedWidget, I have added a single ListWidget. My wish is for the ListWidget on this page to shrink/expand to always fill its page of the StackedWidget. I have tried a good many combinations of settings (SizePolicy/Geometry) and found none that will get the ListWidget to "keep up" with the size of the StackedWidget page it is a child of.

Any help would be greatly appreciated.

jacek
12th June 2007, 21:03
It looks like you forgot to set the layout for that stacked widget's page. Just click on the page and then choose one of the "Lay Out xxx" options from the "Form" menu.

marcel
12th June 2007, 21:04
Set a layout -vertical or horizontal - to a widget and add the list widget to this layout. Then add the first widget to the stacked widget. http://www.qtcentre.org/forum/images/icons/icon7.png

Regards

buckadl
12th June 2007, 21:56
It looks like you forgot to set the layout for that stacked widget's page. Just click on the page and then choose one of the "Lay Out xxx" options from the "Form" menu.
Thanks - that did it!