|
From: Jerzy K. <jer...@un...> - 2012-02-16 20:29:51
|
William Hoburg: > Is there a way to import a svg-image into a plot? > I know that there are some possibilities to import png (http://matplotlib.sourceforge.net/examples/pylab_examples/demo_annotation_box.html) or eps (which is then rastered). > But till now I didn't find any way to import/embed a real vector graphic which is still a vector when I save the figure again as pdf or svg. SVG is a text file, a quite complicated XML. In order to put it into a canvas you have to parse it, and to transform all the DEFs, the primitives and attributes into plotting commands. Such package as matplotlib lives in anther galaxy. It took a lot of time to implement SVG in Mozilla or Chrome... Jerzy Karczmarczuk |