summaryrefslogtreecommitdiffstats
path: root/src/opengl/gl2paintengineex
diff options
context:
space:
mode:
authorEskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>2010-07-07 09:04:33 (GMT)
committerJason McDonald <jason.mcdonald@nokia.com>2010-07-12 01:48:00 (GMT)
commitf05788e40d0e71dd6c5f5bb68ada801e1a5d7acd (patch)
treec530548d2e1b65afbcc62da8f46486d3e7372955 /src/opengl/gl2paintengineex
parent75c5bc5f7efd5f7055b689a244147e69733280a4 (diff)
downloadQt-f05788e40d0e71dd6c5f5bb68ada801e1a5d7acd.zip
Qt-f05788e40d0e71dd6c5f5bb68ada801e1a5d7acd.tar.gz
Qt-f05788e40d0e71dd6c5f5bb68ada801e1a5d7acd.tar.bz2
Fix text drawing into alpha pixmap with opengl engine
The merge 03dc74984749adf5b11482bf871a47086217845c mistakenly merged the glyphMargin() (which had been removed in 4.7 because QGLTextureGlyphCache now inherits from the image glyph cache) with the glyphPadding() which had been introduced in separate commits in both branches (probably backported.) This broke text drawing into a pixmap with an alpha with the GL engine, because we'd assume a margin of 1, but the alphaMapForGlyph() function doesn't support margins. Task-number: QTBUG-11987 Reviewed-by: Gunnar (cherry picked from commit 4e915e3942c1523ffdda01e36c019f842062b794)
Diffstat (limited to 'src/opengl/gl2paintengineex')
-rw-r--r--src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp5
-rw-r--r--src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h1
2 files changed, 0 insertions, 6 deletions
diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
index 5371c5e..410cf21 100644
--- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
+++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl.cpp
@@ -276,11 +276,6 @@ void QGLTextureGlyphCache::fillTexture(const Coord &c, glyph_t glyph)
}
}
-int QGLTextureGlyphCache::glyphMargin() const
-{
- return 1;
-}
-
int QGLTextureGlyphCache::glyphPadding() const
{
return 1;
diff --git a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
index 84e9021..6bcd655 100644
--- a/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
+++ b/src/opengl/gl2paintengineex/qtextureglyphcache_gl_p.h
@@ -72,7 +72,6 @@ public:
virtual void createTextureData(int width, int height);
virtual void resizeTextureData(int width, int height);
virtual void fillTexture(const Coord &c, glyph_t glyph);
- virtual int glyphMargin() const;
virtual int glyphPadding() const;
inline GLuint texture() const { return m_texture; }