[LyX/master] Fix #13326

Koji Yokota <[email protected]>
Newsgroups gmane.editors.lyx.cvs
Message-ID <[email protected]>
commit 6903b162dde53352c052dcb0b248a82bbbee71c6
Author: Koji Yokota <[email protected]>
Date:   Thu Jul 30 01:10:23 2026 +0900

    Fix #13326
---
 src/frontends/qt/GuiPrefs.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/frontends/qt/GuiPrefs.cpp b/src/frontends/qt/GuiPrefs.cpp
index 6998430780..8cbe6d4522 100644
--- a/src/frontends/qt/GuiPrefs.cpp
+++ b/src/frontends/qt/GuiPrefs.cpp
@@ -1606,12 +1606,15 @@ void PrefColors::cacheAllThemes()
 	guiApp->setOverrideCursor(QCursor(Qt::WaitCursor));
 	themes_cache_.clear();
 	theme_names_cache_.clear();
+	// back up lcolor since readTheme() and LyXRC::read() change lcolor
+	ColorSet const backup = lcolor;
 	LyXRC dummyrc;
 	for (int id = 0; id < themesLW->count(); ++id) {
 		FileName const fn(fromqstr(theme_fullpaths_[id]));
 		themes_cache_.push_back(readTheme(fn, dummyrc));
 		theme_names_cache_.push_back(themesLW->item(id)->text());
 	}
+	lcolor = backup;
 	guiApp->restoreOverrideCursor();
 }
 
-- 
lyx-cvs mailing list
[email protected]
https://lists.lyx.org/mailman/listinfo/lyx-cvs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.