[cairo] Re: SVG Backend rewrite (drop libxml2)

Kristian Høgsberg krh at bitplanet.net
Wed Jun 14 12:29:40 PDT 2006


> By the way, given you had to touch almost all of cairo-svg-surface.c,
> don't hesitate to tell me if you've seen some weird things in this
> code...

It all looks good to me.  I did consider rewriting some of the
paginaged surface handling, since create_similar creates a meta
surface, which is then replayed against a paginated surface.  This is
a bit pointless since the paginated surface just records it into
another meta surface.  So either create_similar should create
paginated surfaces, or the paginated surface code should have have an
entry point so you could pass it a meta surface and skip the recording
step.

Also, now that the SVG backend uses cairo output streams, it should be
easy to convert some of those to temporary file streams if memory
usage becomes an issue.

Oh, and I was tempted to split out the base64 stream into it's own
file and redo it as a cairo_output_stream_t sub-class, but nothing
else uses base64 encoding and the png write method doesn't take a
cairo_output_stream_t anyway, so I didn't do that bit.  It might still
be a worthwile cleanup, though.

cheers,
Kristian


More information about the cairo mailing list