What I'm trying to accomplish is a very simple and straight forward need, or I thought, but for the life of me, I can't seem to find a way to do it.
In my qt application I want to be able to make a widget or a layout fill the entire space of the parent widget.
For example, let's say I want to have a label with a fixed height and beneath it a stacked widget which occupies the rest of the height of the window. Here's what I do in the qt-creator designer:
- drag a label to the form
- drag a stacked widget to the form
- select both of them and then right click > lay out > lay out vertically
- select the
verticalLayoutobject and in thelayoutStretchproperty have0,1
Now, how do I make the verticalLayout occupy all of the width/height of the centralWidget?
Nothing seems to work for me.
Thanks.