diff options
author | Alessandro Portale <aportale@trolltech.com> | 2009-03-25 19:40:44 (GMT) |
---|---|---|
committer | Alessandro Portale <aportale@trolltech.com> | 2009-03-25 19:40:44 (GMT) |
commit | 6c078d9b6cde43119495eb4aceac397da303d04c (patch) | |
tree | ca2160a545d1f16cda97f23f5671f29de7fc40c3 /src/gui/text/qfontengine.cpp | |
parent | b9f70293686a1aa2fce26656435130c54886f331 (diff) | |
download | Qt-6c078d9b6cde43119495eb4aceac397da303d04c.zip Qt-6c078d9b6cde43119495eb4aceac397da303d04c.tar.gz Qt-6c078d9b6cde43119495eb4aceac397da303d04c.tar.bz2 |
alphaMask needs to be const, because first bytesPerLine() is called and then bits(). The non-const bits() may detach and realign the data, so that the previous result of bytesPerLine() ist invalid. On S60, we actually had a 'skew' effect because of that.
Diffstat (limited to 'src/gui/text/qfontengine.cpp')
-rw-r--r-- | src/gui/text/qfontengine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/text/qfontengine.cpp b/src/gui/text/qfontengine.cpp index c4dffdf..47fe5c2 100644 --- a/src/gui/text/qfontengine.cpp +++ b/src/gui/text/qfontengine.cpp @@ -542,7 +542,7 @@ void QFontEngine::addBitmapFontToPath(qreal x, qreal y, const QGlyphLayout &glyp advanceY += glyphs.advances_y[i]; continue; } - QImage alphaMask = alphaMapForGlyph(glyphs.glyphs[i]); + const QImage alphaMask = alphaMapForGlyph(glyphs.glyphs[i]); const int w = alphaMask.width(); const int h = alphaMask.height(); |