From ab188f2e90b49fc4e07f04dc512f9fb9864efa0b Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Fri, 25 Jan 2008 17:44:26 -0500 Subject: [PATCH] [cairo-ft] Disable embedded bitmaps if hinting style NONE is requested --- src/cairo-ft-font.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/cairo-ft-font.c b/src/cairo-ft-font.c index d70f379db..708578dc8 100644 --- a/src/cairo-ft-font.c +++ b/src/cairo-ft-font.c @@ -1288,9 +1288,6 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) if (antialias) { cairo_subpixel_order_t subpixel_order; - if (!bitmap) - ft_options.load_flags |= FT_LOAD_NO_BITMAP; - /* disable hinting if requested */ if (FcPatternGetBool (pattern, FC_HINTING, 0, &hinting) != FcResultMatch) @@ -1353,6 +1350,14 @@ _get_pattern_ft_options (FcPattern *pattern, cairo_ft_options_t *ret) ft_options.base.hint_style = CAIRO_HINT_STYLE_NONE; } #endif /* FC_HINT_STYLE */ + + /* Force embedded bitmaps off if no hinting requested */ + if (ft_options.base.hint_style == CAIRO_HINT_STYLE_NONE) + bitmap = FcFalse; + + if (!bitmap) + ft_options.load_flags |= FT_LOAD_NO_BITMAP; + } else { ft_options.base.antialias = CAIRO_ANTIALIAS_NONE; }