Honour QSizePolicy::Fixed too

Some widgets, for example QPushButton, instead of having an explicit max size,
they communicate the need for a max size through their size policy
This commit is contained in:
Sergio Martins
2020-06-07 19:53:06 +01:00
parent ab8545e2c2
commit d5797a3aea
8 changed files with 107 additions and 6 deletions

View File

@@ -46,6 +46,7 @@ public:
return m_thisWidget;
}
QSize sizeHint() const override;
QSize minSize() const override;
QSize maxSizeHint() const override;
QRect geometry() const override;
@@ -64,7 +65,7 @@ public:
void setHeight(int height) override;
static QSize widgetMinSize(const QWidget *w);
static QSize widgetMaxSize(const QWidget *w);
private:
QWidget *const m_thisWidget;
Q_DISABLE_COPY(Widget_qwidget)