1

I am adding sizegrip(QSizegrip) to verticall bar on bottom-right side it is resizing both horizontally and vertically actually it should allow only vertically , how to do this? Any other solutions are welcome.

image for details

Sagar A W
  • 338
  • 1
  • 12

2 Answers2

1

On Object which one you want to restrict apply these flags based on requirement

    setMaximumWidth(Default_width);
    setMaximumHeight(Default_height);
Sagar A W
  • 338
  • 1
  • 12
0

You could override the event method (or https://doc.qt.io/Qt-5/qwidget.html#mouseMoveEvent), check for a MouseMove event and accordingly limit the maximum horizontal size of the dialog.

Navie
  • 164
  • 1
  • 8