[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - vcl/coretext

Khaled Hosny khaledhosny at eglug.org
Thu Jun 20 04:12:11 PDT 2013


 vcl/coretext/ctfonts.cxx |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

New commits:
commit f4a57bb8d00cfd22e63bc5e51755953adae492df
Author: Khaled Hosny <khaledhosny at eglug.org>
Date:   Tue Jun 18 01:26:16 2013 +0200

    Some notes
    
    Change-Id: I665826017f03b123a8b80d6cf31e37d18e169d10
    (cherry picked from commit 984dadaf69a945c8f5e0680bca4b5830b9ebc094)
    Reviewed-on: https://gerrit.libreoffice.org/4384
    Reviewed-by: Noel Power <noel.power at suse.com>
    Tested-by: Noel Power <noel.power at suse.com>

diff --git a/vcl/coretext/ctfonts.cxx b/vcl/coretext/ctfonts.cxx
index 70c7399..ae77b71 100644
--- a/vcl/coretext/ctfonts.cxx
+++ b/vcl/coretext/ctfonts.cxx
@@ -137,7 +137,8 @@ void CTTextStyle::GetFontMetric( float fPixelSize, ImplFontMetricData& rMetric )
 
 bool CTTextStyle::GetGlyphBoundRect( sal_GlyphId nGlyphId, Rectangle& rRect ) const
 {
-    CGGlyph nCGGlyph = nGlyphId & GF_IDXMASK; // NOTE: CoreText handles glyph fallback itself
+    CGGlyph nCGGlyph = nGlyphId & GF_IDXMASK;
+    // XXX: this is broken if the glyph came from fallback font
     CTFontRef aCTFontRef = (CTFontRef)CFDictionaryGetValue( mpStyleDict, kCTFontAttributeName );
 
     const CTFontOrientation aFontOrientation = kCTFontDefaultOrientation; // TODO: horz/vert
@@ -196,8 +197,8 @@ bool CTTextStyle::GetGlyphOutline( sal_GlyphId nGlyphId, basegfx::B2DPolyPolygon
 {
     rResult.clear();
 
-    // TODO: GF_FONTMASK if using non-native glyph fallback
     CGGlyph nCGGlyph = nGlyphId & GF_IDXMASK;
+    // XXX: this is broken if the glyph came from fallback font
     CTFontRef pCTFont = (CTFontRef)CFDictionaryGetValue( mpStyleDict, kCTFontAttributeName );
     CGPathRef xPath = CTFontCreatePathForGlyph( pCTFont, nCGGlyph, NULL );
 


More information about the Libreoffice-commits mailing list