[cairo] svg2pdf doesn't create the same pdf as rsvg-convert
Dominic Lachowicz
domlachowicz at gmail.com
Mon Oct 29 07:59:43 PDT 2007
That's really odd, considering that svg2pdf uses librsvg to render the
SVG to a PDF. rsvg-convert just has a little more "fluff" and calls
cairo_pdf_surface_create_for_stream() instead of
cairo_pdf_surface_create(). But they really should be equivalent.
http://cgit.freedesktop.org/~cworth/svg2pdf/tree/svg2pdf.c
vs.
http://svn.gnome.org/viewvc/librsvg/trunk/rsvg-convert.c?revision=1120&view=markup
On 10/27/07, Andrew Mason <slackmase2 at gmail.com> wrote:
> Hi guys
> I have an SVG which i'm generating dynamically with XSLT, which I then
> use to generate a pdf invoice. I have run into an odd difference in
> the resulting pdf between rsvg-convert and svg2pdf
>
> running the attached svg through rsvg-convert and svg2pdf (as done below):
>
> rsvg-convert -o incorrect.pdf -f pdf order1.svg
> svg2pdf order1.svg correct.pdf
>
>
> results in two slightly different looking pdfs.
>
> The one created by svg2pdf is correct and looks exactly the same as
> the svg.Notice the Miniature World Maker logo has a gradient.
>
> rsvg-convert however is missing the gradient in the logo.
>
> For a single page PDF this isn't a problem as I can use svg2pdf,
> however should people order more than 1 page worth of products then i
> need to make multiple page PDF's.
>
> Since , iirc, neither svg2pdf nor rsvg-convert, has <pageSet> <page>
> support (svg 1.2 ), then I have to use rsvg-convert so that i can pass
> it 2 svg's .
>
> rsvg-convert -o order.pdf -f pdf order1.svg order2.svg
>
> Can anyone offer some advice as to how I can get my gradient back
> using rsvg-convert ?
> I was under the impression svg2pdf used librsvg, so theoretically
> there shouldn't be a difference ? Is my rsvg version just too old ?
>
> rsvg-convert version 2.16.1
> svg2pdf -V = 0.1.3
> cairo 1.4.10
>
> Thanks in advance
>
> _______________________________________________
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo
>
>
--
Counting bodies like sheep to the rhythm of the war drums.
More information about the cairo
mailing list