Anyone is welcome to work on the SVG backend. I didn't realize that
John thought I was hard at work on improving it, when actually I've been
happily using it. Sorry for not communicating that... I'm not going to
have any time to work on it in the near future, so go nuts. I'm an
amateur, so there are plenty of bugs!
There is an SVG backend already in matplotlib. It hasn't been
announced because it is in development by Jared Wahlstrand. Perhaps
Jared can give a status report on what needs to be done, and you might
want to help out. He might have a more recent copy in his development
tree than I do.
Here are the issues as I understand them:
* image support
This is waiting on a save_image function in the Agg backend, so that we
can link to an external PNG file.
* font support (freetype vs afm), use of font families /
Is this the issue of 'helvetica' versus 'sans serif'?
I don't know where to begin here, but the implementation is going to
look a lot like the PS backend. It would be cool to embed MathML, but
good luck finding a viewer capable of reading it...
* some oddness when the user calls savefig with a high dpi?
Shouldn't SVG ignore the dpi setting? That's what I did in
You're right, it shouldn't need to know the dpi. This is an artifact
from when I ported everything from the PS backend.
* There also appears to be some problem in centering the figure?
I haven't experienced this.
I've been using it to export to inkscape to make figures for papers and
conference talks and haven't had any major problems. The code in 0.60
is the same as I've been using, with the exception of adding another
case to print_figure() to switch to the SVG backend when the filename
has a .svg extension.
It's not complicated code, so it should be easy to understand, but let
me know if you have any questions.
On Thu, 2004-07-08 at 16:16, John Hunter wrote: