diff options
author | Samuel Rødal <samuel.rodal@digia.com> | 2012-10-03 07:55:36 (GMT) |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-10-03 08:13:05 (GMT) |
commit | d252cc7896200d6c82c345453fcb4d4fc3b42834 (patch) | |
tree | 6305c66b4ebef86851878db64be4fa2e0105b17f /src/opengl | |
parent | ae0d6aa62eb86d0ea90846abf2a5fc8c210aa923 (diff) | |
download | Qt-d252cc7896200d6c82c345453fcb4d4fc3b42834.zip Qt-d252cc7896200d6c82c345453fcb4d4fc3b42834.tar.gz Qt-d252cc7896200d6c82c345453fcb4d4fc3b42834.tar.bz2 |
Fixed text drawing in OpenGL 2 paint engine.
Regression introduced in 0aa9b30432cec3b7.
Partial backport of 12590582a2f676912690 in Qt 5.
Task-number: QTBUG-24453
Change-Id: I9522cff661849981096d4efe70164841739ff359
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Diffstat (limited to 'src/opengl')
-rw-r--r-- | src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp index ff2905c..6962d09 100644 --- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp +++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp @@ -1449,8 +1449,7 @@ void QGL2PaintEngineEx::drawStaticTextItem(QStaticTextItem *textItem) // don't try to cache huge fonts or vastly transformed fonts QFontEngine *fontEngine = textItem->fontEngine(); const qreal pixelSize = fontEngine->fontDef.pixelSize; - if (pixelSize * pixelSize * qAbs(det) < QT_MAX_CACHED_GLYPH_SIZE * QT_MAX_CACHED_GLYPH_SIZE || - det < 0.25f || det > 4.f) { + if (pixelSize * pixelSize * qAbs(det) < QT_MAX_CACHED_GLYPH_SIZE * QT_MAX_CACHED_GLYPH_SIZE && det >= 0.25f && det <= 4.f) { QFontEngineGlyphCache::Type glyphType = fontEngine->glyphFormat >= 0 ? QFontEngineGlyphCache::Type(textItem->fontEngine()->glyphFormat) : d->glyphCacheType; |