Commit 87dc86d68c93c2b5b836501ece57583d1d6d1a2e

Werner Lemberg 2013-01-24T08:39:43

[truetype] Revert change from 2013-01-22. FreeType's `height' value is the baseline-to-baseline distance... * src/truetype/ttobjs.c (tt_size_reset): Undo.

diff --git a/ChangeLog b/ChangeLog
index 11843b5..3f440e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2013-01-23  Werner Lemberg  <wl@gnu.org>
+
+	[truetype] Revert change from 2013-01-22.
+
+	FreeType's `height' value is the baseline-to-baseline distance...
+
+	* src/truetype/ttobjs.c (tt_size_reset): Undo.
+
 2013-01-23  Alexei Podtelezhnikov  <apodtele@gmail.com>
 
 	[base, truetype] New internal FT_Hypot function.
diff --git a/src/truetype/ttobjs.c b/src/truetype/ttobjs.c
index 590b66c..ca4a377 100644
--- a/src/truetype/ttobjs.c
+++ b/src/truetype/ttobjs.c
@@ -1177,12 +1177,11 @@
         FT_PIX_ROUND( FT_MulFix( face->root.ascender, metrics->y_scale ) );
       metrics->descender =
         FT_PIX_ROUND( FT_MulFix( face->root.descender, metrics->y_scale ) );
+      metrics->height =
+        FT_PIX_ROUND( FT_MulFix( face->root.height, metrics->y_scale ) );
       metrics->max_advance =
         FT_PIX_ROUND( FT_MulFix( face->root.max_advance_width,
                                  metrics->x_scale ) );
-
-      /* the height is derived from rounded values */
-      metrics->height = metrics->ascender - metrics->descender;
     }
 
     /* compute new transformation */