From 88788667a083efc6c04d1df641077f5a06be57b5 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Mon, 9 Jan 2017 16:47:15 +0100 Subject: [PATCH] QWindowsVistaStyle: Set theme flag noContent for PE_FrameLineEdit When the flag is not set, custom background colors for QLineEdit will not work. Set the flag as does QWindowsXpStyle. Task-number: QTBUG-57862 Change-Id: I6e653c2cdc8cc523673e1629bf42f833c8504431 Reviewed-by: Joerg Bornemann --- src/widgets/styles/qwindowsvistastyle.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/widgets/styles/qwindowsvistastyle.cpp b/src/widgets/styles/qwindowsvistastyle.cpp index 972deef150..1bdd8bf0c8 100644 --- a/src/widgets/styles/qwindowsvistastyle.cpp +++ b/src/widgets/styles/qwindowsvistastyle.cpp @@ -600,6 +600,7 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt XPThemeData theme(widget, painter, QWindowsXPStylePrivate::EditTheme, EP_EDITBORDER_NOSCROLL, stateId, option->rect); + theme.noContent = true; painter->save(); QRegion clipRegion = option->rect; clipRegion -= option->rect.adjusted(2, 2, -2, -2);