Can someone please help me with this?
I have received and researched several soultions to this seemingly simple task
without finding a working one.
I have a widget. It consists of a frame which contains some text and
a button. Click on the button and the text disappears and the
frame resizes to show only the button. Click on the button and the
text reappears and the frame expands to it's previous size.
This widget lives alone in a GroupBox on an existing form.
It is not a top level widget.
For now I don't care whether the form resizes or not, I just want the
above functionality..
No matter what I try, the text disappears but the frame refuses to
resize.
Several people have indicated that
layout()->setSizeConstraint(QLayout::SetFixedSize);
is the answer. I've tried that, I believe that is only true for top level (ie Dialogs)
widgets.
I've attached a simple.ui file.
many thanks...
Mark
Bookmarks