summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@behdad.org>2010-05-19 15:54:43 -0400
committerBehdad Esfahbod <behdad@behdad.org>2010-05-19 15:54:43 -0400
commitcc66aacf34962b7e874c11da26f2a0c987e69737 (patch)
treed292fbbf52db8466d01c98e100732087b6d5afd4 /modules
parent138f5264b74a31646e289f39c52e6bddcf6a64f7 (diff)
downloadpango-cc66aacf34962b7e874c11da26f2a0c987e69737.tar.gz
Adjust to hb-ng scale cleanup
Diffstat (limited to 'modules')
-rw-r--r--modules/basic/basic-fc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/modules/basic/basic-fc.c b/modules/basic/basic-fc.c
index 28889449..b3619c3e 100644
--- a/modules/basic/basic-fc.c
+++ b/modules/basic/basic-fc.c
@@ -33,8 +33,7 @@
#include <hb-ft.h>
#include <hb-glib.h>
-#define PANGO_SCALE_26_6 (PANGO_SCALE / (1<<6))
-#define PANGO_UNITS_26_6(d) ((d) * PANGO_SCALE_26_6)
+#define PANGO_UNITS_26_6(d) ((d) << 4)
/* No extra fields needed */
@@ -249,8 +248,8 @@ basic_engine_shape (PangoEngineShape *engine G_GNUC_UNUSED,
&context);
hb_font_set_scale (hb_font,
/* XXX CTM */
- PANGO_UNITS_26_6 (ft_face->size->metrics.x_scale),
- PANGO_UNITS_26_6 (ft_face->size->metrics.y_scale));
+ ((guint64) ft_face->size->metrics.x_scale * ft_face->units_per_EM) >> 12,
+ ((guint64) ft_face->size->metrics.y_scale * ft_face->units_per_EM) >> 12);
is_hinted = fc_font->is_hinted;
hb_font_set_ppem (hb_font,
is_hinted ? ft_face->size->metrics.x_ppem : 0,