summaryrefslogtreecommitdiffstats
path: root/src/widgets/styles
diff options
context:
space:
mode:
authorRolf Eike Beer <eb@emlix.com>2018-07-18 11:07:52 +0200
committerRolf Eike Beer <eb@emlix.com>2018-08-20 13:02:41 +0000
commit6553921dd537e416da2f4d1441ab6d63059cda60 (patch)
treeeab1cf769bd43b27c4a307fc2ea5a232cfb76031 /src/widgets/styles
parentb9923b30f082e5f3ccfd4b0f10c4386727b8a53f (diff)
QWindowsStyle: respect rectangle when drawing PE_IndicatorViewItemCheck
The hardcoded value is based on the values set in qcommonstyle.cpp, but in case this is changed using a proxy style the actual values are not respected. They would even be wrong if nothing is changed but QStyleHelper::dpiScaled(13.) does not return 13. Change-Id: Ib451d07800b3b4e8cafd1f4fef84cd9bf02f9bba Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'src/widgets/styles')
-rw-r--r--src/widgets/styles/qwindowsstyle.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/widgets/styles/qwindowsstyle.cpp b/src/widgets/styles/qwindowsstyle.cpp
index 4b9d0b5adc..d4ccd0931e 100644
--- a/src/widgets/styles/qwindowsstyle.cpp
+++ b/src/widgets/styles/qwindowsstyle.cpp
@@ -840,7 +840,7 @@ void QWindowsStyle::drawPrimitive(PrimitiveElement pe, const QStyleOption *opt,
: opt->palette.text().color());
if (opt->state & State_NoChange)
p->setBrush(opt->palette.brush(QPalette::Button));
- p->drawRect(opt->rect.x() + 1, opt->rect.y() + 1, 11, 11);
+ p->drawRect(opt->rect.x() + 1, opt->rect.y() + 1, opt->rect.width() - 2, opt->rect.height() - 2);
}
#endif // QT_CONFIG(itemviews)
if (!(opt->state & State_Off)) {