[cairo] Problems with cairo PDF generation and Mac OS X PDF rendering

Malcolm Tredinnick malcolm at pointy-stick.com
Fri Jul 7 19:39:57 PDT 2006


On Fri, 2006-07-07 at 22:27 -0400, John Ellson wrote:
> Malcolm Tredinnick wrote:
> > One thing I noticed about the PDF you attached is that it does not
> > follow the recommendation at the end of section 3.4.1 of the PDF spec (I
> > am using version 1.6 as my reference). Namely, when a PDF contains
> > binary data, it is recommended that the header line ("%PDF-1.4") be
> > immediately followed by a comment containing at least four binary
> > characters (with character codes >= 128)
> 
> Thanks Malcolm and Dominic for identifying this cairo generator issue, 

By the way, I agree with Dominic that it shouldn't be the problem. But
there are buggy PDF viewers out there and that change will help some of
them.

>  
> but I'm
> wondering if I have a graphviz issue as well.   Can you suggest what it 
> is that I'm doing
> to get any binary data in the PDF output?   I'm just generating simple 
> line drawings.  Is it because
> I'm not generating exact pixel coordinates in the device space?

The PDF generation is doing it for you via compression: there is a font
file embedded in the document and it is compressed using deflate. This
generates non-ascii output. Not a problem, nothing to worry about at
all.

Regards,
Malcolm



More information about the cairo mailing list