fix glyph's CMAP index might be corrupted
authorKonstantin Ritt <ritt.ks@gmail.com>
Mon, 7 May 2012 23:57:34 +0000 (02:57 +0300)
committerQt by Nokia <qt-info@nokia.com>
Tue, 8 May 2012 09:47:29 +0000 (11:47 +0200)
when SMP sybmol is present in the font.
this is a simple typo fix, actually

Change-Id: I54a4df43ece1a36f5c7997d121b7655afb2069e3
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
src/plugins/platforms/windows/qwindowsfontengine.cpp

index f4bd3f0..e367707 100644 (file)
@@ -227,7 +227,7 @@ int QWindowsFontEngine::getGlyphIndexes(const QChar *str, int numChars, QGlyphLa
         if (symbol) {
             for (; i < numChars; ++i, ++glyph_pos) {
                 unsigned int uc = getChar(str, i, numChars);
-                glyphs->glyphs[i] = getTrueTypeGlyphIndex(cmap, uc);
+                glyphs->glyphs[glyph_pos] = getTrueTypeGlyphIndex(cmap, uc);
                 if(!glyphs->glyphs[glyph_pos] && uc < 0x100)
                     glyphs->glyphs[glyph_pos] = getTrueTypeGlyphIndex(cmap, uc + 0xf000);
             }