diff options
author | Behdad Esfahbod <behdad@gnome.org> | 2006-01-20 06:04:42 +0000 |
---|---|---|
committer | Behdad Esfahbod <behdad@src.gnome.org> | 2006-01-20 06:04:42 +0000 |
commit | 4a1860a37c7dc01771cc0234fba3ffcea069e114 (patch) | |
tree | db4416aebf2173ee5c43e6f179f5b8a500ad04d1 /pango/pangocairo-font.c | |
parent | fdf1de1313bb5830f23610c90c18aa9277325ee1 (diff) | |
download | pango-4a1860a37c7dc01771cc0234fba3ffcea069e114.tar.gz |
Add a comment about using cairo_scaled_font_text_extents instead of
2006-01-20 Behdad Esfahbod <behdad@gnome.org>
* pango/pangocairo-font.c (_pango_cairo_get_hex_box_info): Add a
comment about using cairo_scaled_font_text_extents instead of
cairo_text_extents.
Diffstat (limited to 'pango/pangocairo-font.c')
-rw-r--r-- | pango/pangocairo-font.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/pango/pangocairo-font.c b/pango/pangocairo-font.c index 37c7834f..a727e053 100644 --- a/pango/pangocairo-font.c +++ b/pango/pangocairo-font.c @@ -171,7 +171,12 @@ _pango_cairo_get_hex_box_info (PangoCairoFont *cfont) cairo_text_extents_t extents; c[0] = hexdigits[i]; - cairo_text_extents (cr, c, &extents); + /* The following call is being added into cairo. That's preferred way + * to get the extents here. When turning that on, we can get rid of + * the dummy surface and cairo context created above. + */ + /* cairo_scaled_font_text_extents (scaled_mini_font, c, &extents); */ + cairo_text_extents (cr, c, &extents); width = MAX (width, extents.width); height = MAX (height, extents.height); } |