diff options
author | Bradley T. Hughes <bradley.hughes@nokia.com> | 2009-05-29 12:37:04 +0200 |
---|---|---|
committer | Bradley T. Hughes <bradley.hughes@nokia.com> | 2009-05-29 12:37:04 +0200 |
commit | eaf85eb428bc1336c16187b5e4df61f63a19068c (patch) | |
tree | ea017ac92bea46c6ec10f75775c4a2d18330cf23 /src/gui/widgets/qabstractscrollarea.cpp | |
parent | 429cd0ee393ad2eef9cea253f7e4dc8940e0cad7 (diff) | |
parent | 766cf07cbe7ebfda01dad163bb070fff7e3077d5 (diff) | |
download | qt4-tools-eaf85eb428bc1336c16187b5e4df61f63a19068c.tar.gz |
Merge branch 'master' of git@scm.dev.nokia.troll.no:qt/qt
Diffstat (limited to 'src/gui/widgets/qabstractscrollarea.cpp')
-rw-r--r-- | src/gui/widgets/qabstractscrollarea.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/gui/widgets/qabstractscrollarea.cpp b/src/gui/widgets/qabstractscrollarea.cpp index b91e3dd8f9..79ca11dc42 100644 --- a/src/gui/widgets/qabstractscrollarea.cpp +++ b/src/gui/widgets/qabstractscrollarea.cpp @@ -1266,6 +1266,12 @@ QSize QAbstractScrollArea::minimumSizeHint() const int hsbExt = d->hbar->sizeHint().height(); int vsbExt = d->vbar->sizeHint().width(); int extra = 2 * d->frameWidth; + QStyleOption opt; + opt.initFrom(this); + if ((d->frameStyle != QFrame::NoFrame) + && style()->styleHint(QStyle::SH_ScrollView_FrameOnlyAroundContents, &opt, this)) { + extra += style()->pixelMetric(QStyle::PM_ScrollView_ScrollBarSpacing, &opt, this); + } return QSize(d->scrollBarContainers[Qt::Horizontal]->sizeHint().width() + vsbExt + extra, d->scrollBarContainers[Qt::Vertical]->sizeHint().height() + hsbExt + extra); } |