[LyX/master] Use semantic latex and math colors for dark theme icon overlay

Juergen Spitzmueller spitz at lyx.org
Sat Dec 12 09:26:55 UTC 2020


commit 882f06121bbeb19dcc5d1bb9834b7ca7e142ba8d
Author: Juergen Spitzmueller <spitz at lyx.org>
Date:   Sat Dec 12 10:56:51 2020 +0100

    Use semantic latex and math colors for dark theme icon overlay
---
 src/frontends/qt/GuiApplication.cpp |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/frontends/qt/GuiApplication.cpp b/src/frontends/qt/GuiApplication.cpp
index a4c9132..44dfd84 100644
--- a/src/frontends/qt/GuiApplication.cpp
+++ b/src/frontends/qt/GuiApplication.cpp
@@ -580,14 +580,13 @@ QPixmap prepareForDarkMode(QPixmap pixmap)
 	// create a layer with blue text turned to lighter blue
 	QPixmap blue_overlay(pixmap.size());
 	QColor math_blue(0, 0, 255);
-	blue_overlay.fill(math_blue.lighter());
+	blue_overlay.fill(guiApp->colorCache().get(Color(Color_math)));
 	blue_overlay.setMask(pixmap.createMaskFromColor(math_blue, Qt::MaskOutColor));
 
 	// create a layer with ("latex") red text turned to lighter red
 	QPixmap red_overlay(pixmap.size());
 	QColor math_red(128, 0, 0);
-	QColor math_red_light(233, 175, 175);
-	red_overlay.fill(math_red_light);
+	red_overlay.fill(guiApp->colorCache().get(Color(Color_latex)));
 	red_overlay.setMask(pixmap.createMaskFromColor(math_red, Qt::MaskOutColor));
 
 	// put layers on top of existing pixmap


More information about the lyx-cvs mailing list