diff options
author | Jan-Arve Sæther <jan-arve.saether@nokia.com> | 2010-04-26 09:53:55 (GMT) |
---|---|---|
committer | Jan-Arve Sæther <jan-arve.saether@nokia.com> | 2010-04-26 09:53:55 (GMT) |
commit | 3dd2b86db2b10998dc0a49e2310dd2e8699159cf (patch) | |
tree | e7fec79e43b1652e4da4dcc2786fa530c479d482 /src/gui/widgets/qradiobutton.cpp | |
parent | 8daa3ee6591f0ec5f65552a8a9290228d6e9f0ab (diff) | |
download | Qt-3dd2b86db2b10998dc0a49e2310dd2e8699159cf.zip Qt-3dd2b86db2b10998dc0a49e2310dd2e8699159cf.tar.gz Qt-3dd2b86db2b10998dc0a49e2310dd2e8699159cf.tar.bz2 |
QRadioButton did not have a minimumSizeHint()
Fortunately the *default* horizontal size policy was
QSizePolicy::Minimum. However if the size policy was set to for instance
Preferred it could shrink down until it disappeared.
The following patch will do the same as QLabel does it:
sizeHint is the same as minimumSizeHint.
Task-number: QTBUG-2606
Diffstat (limited to 'src/gui/widgets/qradiobutton.cpp')
-rw-r--r-- | src/gui/widgets/qradiobutton.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gui/widgets/qradiobutton.cpp b/src/gui/widgets/qradiobutton.cpp index 20b6c720..56bd709 100644 --- a/src/gui/widgets/qradiobutton.cpp +++ b/src/gui/widgets/qradiobutton.cpp @@ -207,6 +207,14 @@ QSize QRadioButton::sizeHint() const /*! \reimp */ +QSize QRadioButton::minimumSizeHint() const +{ + return sizeHint(); +} + +/*! + \reimp +*/ bool QRadioButton::hitButton(const QPoint &pos) const { QStyleOptionButton opt; |