Today I deprecated the old 'rsvg' command-line tool in favor of the new hotness, rsvg-convert. rsvg is now just a small python wrapper around rsvg-convert. rsvg-convert has a bunch of useful improvements over its predecessor:
- It's faster and lighter on RAM, since we no longer go through the intermediate step of converting the SVG to a GdkPixbuf, and then the GdkPixbuf to a PNG
- It can accept input from stdin [default behavior]
- It can emit output to stdout [default behavior]
- It can preserve the image's aspect ratio when you scale it
- It can set the image's base uri, so you can download a SVG from the web but not resources (PNGs, JPEGs, etc.) relative to it, and it will all "just work"
- It can emit things in the PDF, PS, and SVGPrint (!!) formats, thanks to Cairo hotness
- It can merge multiple SVGs specified on the command-line into a single PDF/PS/SVGPrint document (caveat: due to Cairo API limitations, all pages are constrained to the size of the first image)
That last point was made possible in large part due to Emmanuel Pacaud's nice work on an exprimental Cairo SVG backend. Today, I did my part and modified his SVG backend to be a SVGPrint backend so we can get multi-page output. Not that any renderers I'm aware of support more than the first page of output. But that's probably a chicken-vs.-egg kind of problem.