Basically I\'ve got a QGridLayout
with a few widgets in it. The important ones are 2 labels, which I use for drawing images to the screen. Well, if the user wan
You need to store the original size of your widget parent window before applying any changes to the layout and restore it when the user switches back to the original.
Notice that you need to work with the widget parent window size and not the widget parent size.
in your widget before applying the layout changes:
minimumWindowSize = this->window().size();
when you finished reorganizing the widget to the compact size
this->window().resize(minimumWindowSize);