cairo_text_extents() takes about seven times as long as cairo_show_text(). sysprof shows that cairo_text_extents spends its time in _cairo_font_create and then _cairo_ft_font_create then in libfontconfig. Owen Taylor suggested that there is caching that should be happening here and asked me to file this bug!
Created attachment 3231 [details] [review] xrandr-deadlock-fix.patch
Created attachment 3232 [details] [review] Proposed patch
Oops! Please ignore previous two attachments. They belong to bug #2675 . Sorry.
Created attachment 2922 [details] Source code illustrating one case of FPE in cairo.
Move bugs against "cvs" version to "0.9.3" so we can remove the "cvs" version.
During 1.1.1 Keith committed a fix that adds a cache of user-space metrics: 2005-08-31 Keith Packard <keithp@keithp.com> Reviewed by: otaylor, cworth * src/cairo-ft-font.c: (_get_bitmap_surface), (_render_glyph_outline), (_render_glyph_bitmap), (_transform_glyph_bitmap), (_get_pattern_ft_options), (_cairo_ft_scaled_font_create), (_cairo_ft_scaled_font_create_toy), (_decompose_glyph_outline), (_cairo_ft_scaled_glyph_init), (_cairo_ft_ucs4_to_index), (_cairo_ft_show_glyphs), (_cairo_ft_font_face_scaled_font_create), (_cairo_ft_font_face_create), (cairo_ft_font_face_create_for_pattern), (cairo_ft_font_face_create_for_ft_face): Store glyphs in new per-scaled font caches which hold user-space metrics and device space bounding boxes Ian mentioned to me that this fix helped his application a great deal, so I'm closing this as fixed.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.