[reportlab-users] Easier export of graphics formats
Andy Robinson
reportlab-users@reportlab.com
Tue, 18 Mar 2003 01:00:35 -0000
Drawing objects already had a save(...) method which
takes a number of arguments and saves to disk, loading up
the individual renderers as needed. I have just added
a method "Drawing.asString(format)" which allows homogeneous
export 'in memory' and will probably be useful e.g.
stuff = myDrawing.asString('gif')
The argument is the format e.g. gif, png, pdf.
As before, if you ask for 'eps' then it attempts to import
our proprietary EPS filter (which does lots of high-end
printing-oriented stuff) in 'rlextra.graphics.renderPS_SEP',
which most people won't have. If you don't ask for 'eps'
format, this won't happen so don't worry. In due course we
will try to have a smarter 'filter registration scheme' so the
Open Source package does not need to have this stuff in it.
Best Regards,
Andy Robinson