Yeah -- the print_* format methods should probably be made private. They don't properly save/restore state -- that is all done in one place in the higher-level function "print_figure".
I would suggest: canvas.print_figure(string_io, format='svg') I'll go ahead and make these functions private to avoid confusion -- probably on the trunk only, though, to avoid breaking things for cases where it's currently working "by accident" (i.e. in a non-interactive setting). Mike On 10/14/2010 02:43 PM, Fernando Perez wrote: > from cStringIO import StringIO > plot(rand(100)) > canvas = gcf().canvas > string_io = StringIO() > canvas.print_svg(string_io) > -- Michael Droettboom Science Software Branch Space Telescope Science Institute Baltimore, Maryland, USA ------------------------------------------------------------------------------ Beautiful is writing same markup. Internet Explorer 9 supports standards for HTML5, CSS3, SVG 1.1, ECMAScript5, and DOM L2 & L3. Spend less time writing and rewriting code and more time creating great experiences on the web. Be a part of the beta today. http://p.sf.net/sfu/beautyoftheweb _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel