summaryrefslogtreecommitdiffstats
path: root/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>2015-08-17 17:59:06 +0200
committerTor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>2015-09-02 09:11:31 +0000
commit54dbdc26bacd3ab776c99ebef734404ef2e08ce5 (patch)
tree6c3d5614ea3beefd023ab0a259ecf207655ba2ce /src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
parentba94e26b8b233456b004084892464ec55b20800c (diff)
Move min left/right bearing calculations to QFontEngine baseclass
The logic used in the FreeType font engine can be generalized and move to the QFontEngine baseclass. This allows the CoreText font engine to correctly report the minimum left/right bearings, which decreases the chance that an optimization in QTextLayout's line breaking algorithm will produce wrong results. The calculation of left and right bearing has been moved to the glyph_metrics_t type to reduce code duplication. This allows us to use the with and height of the bounding box to determine if the glyph has any contours. Change-Id: I864697d3f31ed56f22f04666199b6c5023c5e585 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
Diffstat (limited to 'src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h')
-rw-r--r--src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h b/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
index f8ec1d326f..1c33ae7d84 100644
--- a/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
+++ b/src/platformsupport/fontdatabases/mac/qfontengine_coretext_p.h
@@ -96,8 +96,6 @@ public:
QImage alphaRGBMapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t) Q_DECL_OVERRIDE;
glyph_metrics_t alphaMapBoundingBox(glyph_t glyph, QFixed, const QTransform &matrix, GlyphFormat) Q_DECL_OVERRIDE;
QImage bitmapForGlyph(glyph_t, QFixed subPixelPosition, const QTransform &t) Q_DECL_OVERRIDE;
- qreal minRightBearing() const Q_DECL_OVERRIDE;
- qreal minLeftBearing() const Q_DECL_OVERRIDE;
QFixed emSquareSize() const Q_DECL_OVERRIDE;
bool supportsTransformation(const QTransform &transform) const Q_DECL_OVERRIDE;