summaryrefslogtreecommitdiffstats
path: root/src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2020-01-27 11:04:14 +0100
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2020-02-01 17:48:37 +0100
commite56b8e1e59b6df7c7abd48b163abe6846849eb7a (patch)
tree4ddabe9efcebf8eb4a8e9b2f296c748753a3e064 /src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h
parent0c8ff269dcda7de68c475535d575c0bb34af788b (diff)
QWindowsXPStyle: Fix MDI button size for maximized QMdiSubWindows
The controls as drawn by the UxTheme library are too tiny; add an additional correction factor to QWindowsXPStylePrivate::drawBackgroundThruNativeBuffer(), allowing to scale the result via the QImage. For the MDI button size, calulcate the factor by comparing the theme size to the subcontrol rectangle. Fixes: QTBUG-75927 Change-Id: Iab0911b51d13f3de0d9278a32cb4598ce709d745 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: André de la Rocha <andre.rocha@qt.io>
Diffstat (limited to 'src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h')
-rw-r--r--src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h b/src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h
index ad7754e3d4..06b37a6e5c 100644
--- a/src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h
+++ b/src/plugins/styles/windowsvista/qwindowsxpstyle_p_p.h
@@ -241,8 +241,8 @@ public:
bool isTransparent(XPThemeData &themeData);
QRegion region(XPThemeData &themeData);
- bool drawBackground(XPThemeData &themeData);
- bool drawBackgroundThruNativeBuffer(XPThemeData &themeData, qreal aditionalDevicePixelRatio);
+ bool drawBackground(XPThemeData &themeData, qreal correctionFactor = 1);
+ bool drawBackgroundThruNativeBuffer(XPThemeData &themeData, qreal aditionalDevicePixelRatio, qreal correctionFactor);
bool drawBackgroundDirectly(HDC dc, XPThemeData &themeData, qreal aditionalDevicePixelRatio);
bool hasAlphaChannel(const QRect &rect);