summaryrefslogtreecommitdiff
path: root/pango/pangocairo-font.c
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@gnome.org>2006-01-20 06:04:42 +0000
committerBehdad Esfahbod <behdad@src.gnome.org>2006-01-20 06:04:42 +0000
commit4a1860a37c7dc01771cc0234fba3ffcea069e114 (patch)
treedb4416aebf2173ee5c43e6f179f5b8a500ad04d1 /pango/pangocairo-font.c
parentfdf1de1313bb5830f23610c90c18aa9277325ee1 (diff)
downloadpango-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.c7
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);
}