Savannah » Python PostScript Generator

Python PostScript Generator

Psg is a Python module that lets you create PostScript files by embedding EPS files, bitmaps (through PIL), fonts and arbitrary subsections from DSC complient input files. This could be used to re-write the psutils package in Python. A rudimentary layout engine to create connected text boxes is in place and will be extended in the future. I envision a subset of XML/CSS. The text functons support Type1 fonts and dynamically re-encodes them based on unicode(!) input. All input/output operation goes through regular Python file objects. Though PostScript files are generally constructed in memory, all import operations are 'lazy', that is, input files are analyzed but their content is only copied over to the output file in the last step of composition to reduce memory usage. Psg contains classes to model a PostScript run time environments. It will contain functionality to use Ghostscript to create PDF files and bitmap previews (my own use is largely www applications), but also to import PDF and those PostScript files that make use of all the DSC's liberties. There is not much documentation, yet, but the source code is richly and (I hope) usefully documented and there are a number of examples.

About
A brief introduction to the ideas behind psg including a small example program.
Download
Documentation
Community
This is Diedrich's S p a m T r a p! dst@tux4web.de