Generate report containing pdf or ps figures?

infidel saint.infidel at gmail.com
Mon Apr 23 15:26:52 EDT 2007


On Apr 23, 9:30 am, Grant Edwards <gra... at visi.com> wrote:
> I need to be able to generate a PDF report which consists
> mostly of vector images (which I can generate as encapsulated
> Postscript, PDF, or SVG).  What I need is a way to combine
> these figures into a single PDF document.  Right now the
> reports consist entire of these figures, so I just write the
> figures out to temp files and then use os.system() to run
> ghostscript with appropriate options to combine them into a
> single PDF file.
>
> I'd like to be able to add some text and/or place the figures
> in a manner other than one per page in the output document.
>
> I've looked at ReportLab's documentation, but although it
> appears to be able to use bitmap images (e.g jpeg) it doesn't
> appear to be able to use vector images (EPS/PDF/SVG).
>
> Is there a PDF generation library that can place EPS or
> PDF figures on a page?

I've had great success using Apache's FOP utility (http://
xmlgraphics.apache.org/fop) to generate PDFs out of XSL-FO, which can
contain SVG graphics (at least the 0.20.5 version can, the newer
rewrite version doesn't yet).  FOP is a java library but has a
suitable command line interface.




More information about the Python-list mailing list