[cairo-bugs] [Bug 50688] Freetype (TTF) font string truncated

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Fri Jun 8 01:51:29 PDT 2012


https://bugs.freedesktop.org/show_bug.cgi?id=50688

Chris Wilson <chris at chris-wilson.co.uk> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |NOTOURBUG

--- Comment #5 from Chris Wilson <chris at chris-wilson.co.uk> 2012-06-08 01:51:29 PDT ---
The fundamental bug is still that your font is reporting invalid metrics. Can
you please do:

diff --git a/src/cairo-scaled-font.c b/src/cairo-scaled-font.c
index 7ea3a21..42a2e9d 100644
--- a/src/cairo-scaled-font.c
+++ b/src/cairo-scaled-font.c
@@ -2261,6 +2261,12 @@ _cairo_scaled_font_glyph_approximate_extents
(cairo_scale
     double x0, x1, y0, y1, pad;
     int i;

+    fprintf("%s: max_x_advance=%f, height=%f, max_scale=%f\n",
+           __FUNCTION,
+           scaled_font->fs_extents.max_x_advance,
+           scaled_font->fs_extents.height,
+           scaled_font->max_scale)
+
     /* If any of the factors are suspect (i.e. the font is broken), bail */
     if (scaled_font->fs_extents.max_x_advance == 0 ||
        scaled_font->fs_extents.height == 0 ||

to convince yourself that you have compiled and installed the library
correctly. Note that on many distributions now the canonical location is not
/usr/lib/, so check with ldd `which gnome-font-viewer` to make sure it is
picking up yours.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA Contact for the bug.


More information about the cairo-bugs mailing list