From 63279938670e753b825ebb42c68d9b6be3a3937a Mon Sep 17 00:00:00 2001 From: Vincent van Ravesteijn Date: Sun, 29 Apr 2012 14:26:24 +0200 Subject: [PATCH] Fix bug #7667: Pixmap cache and CT lead to random colors The signature of the character in cache should take into account the change tracking baseColor (author) and mergeColor (added/deleted). If not, we will mixup different cached pixmaps. --- src/frontends/qt4/GuiPainter.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/frontends/qt4/GuiPainter.cpp b/src/frontends/qt4/GuiPainter.cpp index 3ade5c9188..5cb43a039b 100644 --- a/src/frontends/qt4/GuiPainter.cpp +++ b/src/frontends/qt4/GuiPainter.cpp @@ -96,7 +96,9 @@ QString GuiPainter::generateStringSignature(QString const & str, FontInfo const sig.append(QChar(static_cast(f.series()))); sig.append(QChar(static_cast(f.realShape()))); sig.append(QChar(static_cast(f.size()))); - sig.append(QChar(static_cast(f.color()))); + Color const & color = f.realColor(); + sig.append(QChar(static_cast(color.baseColor))); + sig.append(QChar(static_cast(color.mergeColor))); if (!monochrome_min_.empty()) { QColor const & min = monochrome_min_.top(); QColor const & max = monochrome_max_.top(); -- 2.39.5