[cairo] PDF backend: PDF trailer not written?
Behdad Esfahbod
behdad at behdad.org
Fri Dec 5 13:46:09 PST 2008
Chris Wilson wrote:
> On Fri, 2008-12-05 at 19:00 +0100, Sascha Steinbiss wrote:
>> I have also attached a valgrind session with line numbers present, I
>> have also looked at the respective positions in the cairo code
>> (_cairo_pdf_operators_emit_glyph) but am not familiar enough with the
>> environment there to be of much help. I do not see how I could be
>> manipulating the cairo_glyph_t's there...
>
> That's nasty - so if the glyph is culled by the gstate, the backend will
> overrun the glyph array because it is driven by the text clusters, which
> was not updated to reflect the culling.
>
> Attached is a patch that addresses that issue, namely updating the text
> clusters to reflect the transformed and culled glyph array, but it is
> quite ugly and I need some sage advice whether a text cluster mapping n
> characters to 0 glyphs is permissible.
Ouch. Good catch Chris! Lets commit a quick fix to not cull glyphs if we
have clusters. We can decide later what we really want to do.
behdad
More information about the cairo
mailing list