diff options
Diffstat (limited to 'src/gui/kernel/qwidget.cpp')
-rw-r--r-- | src/gui/kernel/qwidget.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp index e88026c..7a8b700 100644 --- a/src/gui/kernel/qwidget.cpp +++ b/src/gui/kernel/qwidget.cpp @@ -3816,6 +3816,11 @@ void QWidget::setMaximumSize(int maxw, int maxh) d->updateGeometry_helper(d->extra->minw == d->extra->maxw && d->extra->minh == d->extra->maxh); } +bool QWidgetPrivate::hasHeightForWidth() const +{ + return layout ? layout->hasHeightForWidth() : size_policy.hasHeightForWidth(); +} + /*! \overload @@ -7961,6 +7966,18 @@ QSize QWidget::minimumSizeHint() const return QSize(-1, -1); } +/*! + \internal + This is a bit hackish, but ideally this would have been a virtual + function so that subclasses could reimplement their own function. + Instead we add a virtual function to QWidgetPrivate. +*/ +bool QWidget::hasHeightForWidth() const +{ + Q_D(const QWidget); + return d->hasHeightForWidth(); +} + /*! \fn QWidget *QWidget::parentWidget() const |