[cairo-commit] src/cairo-pdf-surface.c

Behdad Esfahbod behdad at kemper.freedesktop.org
Wed Jan 24 12:51:02 PST 2007


 src/cairo-pdf-surface.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

New commits:
diff-tree 50136a78063137ebca16bcb839bec33e2917824e (from bb02b4e5ec40ac37462f487f2ad74b0123814277)
Author: Eugeniy Meshcheryakov <eugen at debian.org>
Date:   Wed Jan 24 15:51:00 2007 -0500

    [PDF-CFF] Fix bad /LastChar value for CFF fonts in PDF backend
    
    PDF backend sets /LastChar value in Type1C font dictionary incorrectly.
    acroread then complains about incorrect /Widths in font.
    The last char is numchars - 1, since it's zero-based.

diff --git a/src/cairo-pdf-surface.c b/src/cairo-pdf-surface.c
index 7223726..bdfef00 100644
--- a/src/cairo-pdf-surface.c
+++ b/src/cairo-pdf-surface.c
@@ -1709,7 +1709,7 @@ _cairo_pdf_surface_emit_cff_font_subset 
 				 "   /Widths [",
 				 subset_resource.id,
 				 subset.base_font,
-				 font_subset->num_glyphs,
+				 font_subset->num_glyphs - 1,
 				 descriptor.id);
 
     for (i = 0; i < font_subset->num_glyphs; i++)


More information about the cairo-commit mailing list