I've recently put together an SVG renderer for Prawn.
http://rubygems.org/gems/prawn-svg
http://github.com/mogest/prawn-svg
It's very much a work-in-progress, but I've got it to the stage where
it acceptably renders most of the examples from the SVG spec. Check
out the README on github for a list of features it supports.
I wrote it mainly to get Scruffy graphs into a PDF as vector graphics,
and it's doing that great.
Happy for any and all feedback. I've got a bit more free time over
the next week where I'll be adding more features and tidying things up
a bit. Let me know if you have a particular request.
Cheers,
Roger
On Mar 26, 3:55 pm, Roger Nesbitt <ro...@seriousorange.com> wrote:
> Hello,
>
> I've recently put together an SVG renderer for Prawn.
>
> http://rubygems.org/gems/prawn-svghttp://github.com/mogest/prawn-svg
>
> It's very much a work-in-progress, but I've got it to the stage where
> it acceptably renders most of the examples from the SVG spec. Check
> out the README on github for a list of features it supports.
Whoa, this is excellent news. Really bad timing on my end, with a
wedding coming up this weekend. But SVG is at the top of my wishlist
for Prawn, so I'll try to review soon!
-greg
Ah, just at a glance, it might be a good idea to use
Prawn::Document.extensions rather than re-opening the Prawn::Document
class. We'll be moving towards this internally where it makes sense,
and it'll help you future proof things a bit:
http://github.com/sandal/prawn/blob/master/lib/prawn/document.rb#L85
Just back from holiday and seen your post - thanks. I've changed the
code to use the extensions framework.
Running the specs and then looking in the spec/sample_output directory
is probably the quickest way to get a handle on what it's doing at the
moment. More than happy to keep working on it; it's still at a basic
stage.
Cheers
Roger