From 037ad03182ce3c174a5a9afc6780212bb2fe8a12 Mon Sep 17 00:00:00 2001 From: Konstantin Ritt Date: Wed, 1 Apr 2015 06:54:45 +0400 Subject: [QFontEngineFT] Avoid double-negation of info.x Make it consistent with fetchMetricsOnly path. Change-Id: I6a2d2568d5579255582217515a4e598722547c60 Reviewed-by: Friedemann Kleint Reviewed-by: Lars Knoll --- src/gui/text/qfontengine_ft.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/gui/text') diff --git a/src/gui/text/qfontengine_ft.cpp b/src/gui/text/qfontengine_ft.cpp index 0437561572..7949bbc2a4 100644 --- a/src/gui/text/qfontengine_ft.cpp +++ b/src/gui/text/qfontengine_ft.cpp @@ -949,7 +949,7 @@ QFontEngineFT::Glyph *QFontEngineFT::loadGlyph(QGlyphSet *set, uint glyph, info.height = slot->bitmap.rows / vfactor; info.width = hsubpixel ? slot->bitmap.width / 3 : slot->bitmap.width; - info.x = -slot->bitmap_left; + info.x = slot->bitmap_left; info.y = slot->bitmap_top; glyph_buffer_size = info.width * info.height * 4; @@ -1014,11 +1014,11 @@ QFontEngineFT::Glyph *QFontEngineFT::loadGlyph(QGlyphSet *set, uint glyph, hpixels = hpixels*3 + 8; info.width = hpixels; info.height = TRUNC(top - bottom); - info.x = -TRUNC(left); + info.x = TRUNC(left); info.y = TRUNC(top); if (hsubpixel) { info.width /= 3; - info.x += 1; + info.x -= 1; } bool large_glyph = (((short)(slot->linearHoriAdvance>>10) != slot->linearHoriAdvance>>10) @@ -1146,7 +1146,7 @@ QFontEngineFT::Glyph *QFontEngineFT::loadGlyph(QGlyphSet *set, uint glyph, g->linearAdvance = slot->linearHoriAdvance >> 10; g->width = info.width; g->height = info.height; - g->x = -info.x; + g->x = info.x; g->y = info.y; g->advance = info.xOff; g->format = format; -- cgit v1.2.3