* src/base/ftobjs.c (ft_recompute_scaled_metrics): re-enable conservative rounding of metrics to avoid breaking clients like Pango (see http://bugzilla.gnome.org/show_bug.cgi?id=327852)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
diff --git a/ChangeLog b/ChangeLog
index 108525b..16c650f 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-02-26 David Turner <david@freetype.org>
+
+ * src/base/ftobjs.c (ft_recompute_scaled_metrics): re-enable conservative
+ rounding of metrics to avoid breaking clients like Pango
+ (see http://bugzilla.gnome.org/show_bug.cgi?id=327852)
+
2006-02-25 Werner Lemberg <wl@gnu.org>
* devel/ftoption.h: Synchronize with
diff --git a/src/base/ftobjs.c b/src/base/ftobjs.c
index 6ed420a..c237d65 100644
--- a/src/base/ftobjs.c
+++ b/src/base/ftobjs.c
@@ -2063,6 +2063,19 @@
{
/* Compute root ascender, descender, test height, and max_advance */
+#if 1
+ metrics->ascender = FT_PIX_CEIL( FT_MulFix( face->ascender,
+ metrics->y_scale ) );
+
+ metrics->descender = FT_PIX_FLOOR( FT_MulFix( face->descender,
+ metrics->y_scale ) );
+
+ metrics->height = FT_PIX_ROUND( FT_MulFix( face->height,
+ metrics->y_scale ) );
+
+ metrics->max_advance = FT_PIX_ROUND( FT_MulFix( face->max_advance_width,
+ metrics->x_scale ) );
+#else
metrics->ascender = FT_MulFix( face->ascender,
metrics->y_scale );
@@ -2074,6 +2087,7 @@
metrics->max_advance = FT_MulFix( face->max_advance_width,
metrics->x_scale );
+#endif
}