summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOwais Akhtar <[email protected]>2025-12-19 11:12:01 +0200
committerOwais Akhtar <[email protected]>2025-12-23 09:48:20 +0200
commit12cb3cba81153cb409c32e37b1bb85c485acf3f7 (patch)
treeab164792ba7914c3426ccb77ee5c4b05f88bd38e
parentea45e2232354d499e7e6809e4b0ef5cb4abd853f (diff)
Fix font fallback rendering incorrect glyphsHEADdev
The fallback glyph runs were not accounted for when generating the glyphs to textures. Pick-to: 6.11 Change-Id: I7d6c38c6d915d25e7db9eec2a4910a20290ae0ee Reviewed-by: Paul Olav Tvete <[email protected]>
-rw-r--r--src/canvaspainter/engine/qcdistancefieldglyphcache.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/canvaspainter/engine/qcdistancefieldglyphcache.cpp b/src/canvaspainter/engine/qcdistancefieldglyphcache.cpp
index 73473e8..ab0945c 100644
--- a/src/canvaspainter/engine/qcdistancefieldglyphcache.cpp
+++ b/src/canvaspainter/engine/qcdistancefieldglyphcache.cpp
@@ -71,7 +71,6 @@ QCDistanceFieldGlyphCache::generate(const QString &text, const QRectF &rect, con
cache = new QCRhiDistanceFieldGlyphCache(m_rhi);
FontKeyData f{ nullptr, cache, {} };
m_glyphCaches.insert(key, std::move(f));
- cache->setRawFont(rFont);
data = &m_glyphCaches[key];
}
@@ -114,6 +113,7 @@ QCDistanceFieldGlyphCache::generate(const QString &text, const QRectF &rect, con
qsizetype index = 0;
const QPointF glyphPos(rect.x(), rect.y() + textY);
for (const auto &run : std::as_const(glyphRuns)) {
+ cache->setRawFont(run.rawFont());
cache->addGlyphs(glyphPos, run);
cache->update();