[Libreoffice-commits] core.git: vcl/coretext

Khaled Hosny khaledhosny at eglug.org
Sat Jun 29 17:50:00 PDT 2013


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

New commits:
commit 5e0813fc8ef1eb1b19392e46801a231b6f4e931c
Author: Khaled Hosny <khaledhosny at eglug.org>
Date:   Sun Jun 30 02:33:01 2013 +0200

    fdo#66385: bad line spacing under Core Text
    
    We should be setting mnExtLeading not mnIntLeading, at least this is
    what ATSUI code was doing.
    
    Change-Id: Ibe69da4ea60630a31593b538f55fd2cd95642bf9

diff --git a/vcl/coretext/ctfonts.cxx b/vcl/coretext/ctfonts.cxx
index b19dca5..9caf4f4 100644
--- a/vcl/coretext/ctfonts.cxx
+++ b/vcl/coretext/ctfonts.cxx
@@ -121,8 +121,8 @@ void CTTextStyle::GetFontMetric( float fPixelSize, ImplFontMetricData& rMetric )
 
     rMetric.mnAscent       = lrint( CTFontGetAscent( aCTFontRef ) * fPixelSize);
     rMetric.mnDescent      = lrint( CTFontGetDescent( aCTFontRef ) * fPixelSize);
-    rMetric.mnIntLeading   = lrint( CTFontGetLeading( aCTFontRef ) * fPixelSize);
-    rMetric.mnExtLeading   = 0;
+    rMetric.mnExtLeading   = lrint( CTFontGetLeading( aCTFontRef ) * fPixelSize);
+    rMetric.mnIntLeading   = 0;
     // since ImplFontMetricData::mnWidth is only used for stretching/squeezing fonts
     // setting this width to the pixel height of the fontsize is good enough
     // it also makes the calculation of the stretch factor simple


More information about the Libreoffice-commits mailing list