Reputation: 1179
I set up fixed size for window:
w.setFixedSize(200, 400);
Now my window is not resizable. Ok, i want to do it resizabe again:
w.resize(200, 400);
But it's not working. So, how can i do it resizable or remove fixed size?
Upvotes: 1
Views: 1989
Reputation: 318
From the Qt documentation:QLayout Class Reference
sizeConstraint : SizeConstraint
This property holds the resize mode of the layout
The default mode is SetDefaultConstraint.
Access functions:
SizeConstraint sizeConstraint () const
void setSizeConstraint ( SizeConstraint )
SizeConstraint is an enum with this possible values:
enum QLayout:: SizeConstraint { SetDefaultConstraint , SetNoConstraint , SetMinimumSize , SetFixedSize , SetMaximumSize , SetMinAndMaxSize , Auto , FreeResize , Minimum , Fixed SetFixedSize ...}
you can use SetDefaultConstraint or SetNoConstraint or ... for your situation.
Upvotes: 2