summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2020-10-23 18:43:25 +0200
committerMichael Weghorn <m.weghorn@posteo.de>2020-10-28 15:26:51 +0100
commit804f051e8504338ada4ab1fe958aa7fc66a1297c (patch)
treee2976e6197e92ad230937cfd6a0fd963638c03d1 /vcl
parent815f58fe60dca8ee41f362748a144fc16c89b1f9 (diff)
tdf#136555 apply window bg color for button boxes
The default background color of the frame is APPBACKGROUND, which is matched to GetWorkspaceColor(). That color is visible in Writer as the default document workspace background. Originally I just saw the dark background of the button box in the start center, and thought the workspace color in Qt is wrong and changed it in the reverted commit, missing the change of the color around the Writer document. Now that the button boxes's background color isn't fixed via the "branding" setting, we also must react to changed style settings, so we override the DataChanged function. This also reverts commit ef267dc5c1e46d236478ff32fc14925a0eeb0266. Regressed-by: a927e0964ba0442d53fffb22c577e54bcf183ed7 Change-Id: I62396355054523baef1197a8a8af61c2f0d29ef3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104743 Reviewed-by: Michael Weghorn <m.weghorn@posteo.de> Tested-by: Jenkins
Diffstat (limited to 'vcl')
-rw-r--r--vcl/qt5/Qt5Frame.cxx7
1 files changed, 6 insertions, 1 deletions
diff --git a/vcl/qt5/Qt5Frame.cxx b/vcl/qt5/Qt5Frame.cxx
index eb39d6016bfa..936216b9de68 100644
--- a/vcl/qt5/Qt5Frame.cxx
+++ b/vcl/qt5/Qt5Frame.cxx
@@ -1022,6 +1022,7 @@ void Qt5Frame::UpdateSettings(AllSettings& rSettings)
Color aText = toColor(pal.color(QPalette::Active, QPalette::Text));
Color aBase = toColor(pal.color(QPalette::Active, QPalette::Base));
Color aButn = toColor(pal.color(QPalette::Active, QPalette::ButtonText));
+ Color aMid = toColor(pal.color(QPalette::Active, QPalette::Mid));
Color aHigh = toColor(pal.color(QPalette::Active, QPalette::Highlight));
Color aHighText = toColor(pal.color(QPalette::Active, QPalette::HighlightedText));
Color aLink = toColor(pal.color(QPalette::Active, QPalette::Link));
@@ -1045,7 +1046,6 @@ void Qt5Frame::UpdateSettings(AllSettings& rSettings)
style.SetFieldColor(aBase);
style.SetWindowColor(aBase);
style.SetActiveTabColor(aBase);
- style.SetWorkspaceColor(aBase);
style.SetAlternatingRowColor(toColor(pal.color(QPalette::Active, QPalette::AlternateBase)));
// Buttons
@@ -1077,9 +1077,14 @@ void Qt5Frame::UpdateSettings(AllSettings& rSettings)
style.BatchSetBackgrounds(aBack);
style.SetInactiveTabColor(aBack);
+ // Workspace
+ style.SetWorkspaceColor(aMid);
+
// Selection
style.SetHighlightColor(aHigh);
style.SetHighlightTextColor(aHighText);
+ style.SetActiveColor(aHigh);
+ style.SetActiveTextColor(aHighText);
// Links
style.SetLinkColor(aLink);