From 324b96e720159b8c277759f6e000aaf0ed21828b Mon Sep 17 00:00:00 2001 From: Marco Martin Date: Tue, 4 Jan 2011 19:10:38 +0000 Subject: [PATCH] use a size hint svn path=/trunk/KDE/kdelibs/; revision=1211733 --- dialog.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dialog.cpp b/dialog.cpp index c54b7a097..8092a584c 100644 --- a/dialog.cpp +++ b/dialog.cpp @@ -312,9 +312,9 @@ void Dialog::syncToGraphicsWidget() QSize newSize(qMin(int(graphicsWidget->size().width()) + left + right, maxSize.width()), qMin(int(graphicsWidget->size().height()) + top + bottom, maxSize.height())); - //FIXME: hardcoded extra boder for a possible scrollbar in an extender based dialog - QSize newMinimumSize(qMin(int(graphicsWidget->minimumSize().width()) + left + right + 32, maxSize.width()), - qMin(int(graphicsWidget->minimumSize().height()) + top + bottom, maxSize.height())); + const QSizeF minimum = graphicsWidget->effectiveSizeHint(Qt::MinimumSize); + QSize newMinimumSize(qMin(int(minimum.width()) + left + right, maxSize.width()), + qMin(int(minimum.height()) + top + bottom, maxSize.height())); QSize newMaximumSize(qMin(int(graphicsWidget->maximumSize().width()) + left + right, maxSize.width()),