Utils: Fix setting of minimal height of InfoLabels in QFormLayout

Calling setMinimumHeight is not compatible with QFormLayout if the label
has multiple lines. Overriding minimumSizeHint on the other hand is.

Change-Id: Id2167b295620322cec75035d7cc7125cc3221c4d
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Alessandro Portale
2019-12-21 22:58:24 +01:00
parent e34263853c
commit 25323be13d
3 changed files with 16 additions and 1 deletions

View File

@@ -51,6 +51,7 @@ public:
void setType(InfoType type);
bool filled() const;
void setFilled(bool filled);
QSize minimumSizeHint() const override;
protected:
void paintEvent(QPaintEvent *event) override;