[reportlab-users] Vector graphic embedding

Eric Johnson eggsy at gmx.net
Tue Nov 13 12:55:10 EST 2007




>> So, if I'm interpreting what I have found correctly, if I wish to

>> embed an already created vector graphic (say, in PS or PDF form) into

>> my PDF document, there is no easy way to do this beyond purchasing a

>> £15,000 software license and using PageCatcher? It seems absurd that

>> Reportlab supports all the PDF functions to draw all the pieces of my

>> vector graphic but cannot actually draw it in my document. Any help

>> would be appreciated.

>

> I guess you're right, but unfortunately this is the ReportLab policy!

> If SVG is an option, you might want to try a package I wrote a few

> years ago, which is not really well supported right now and which you

> might have to tweak a bit. You can find it on my old Starship pages:

>

> http://python.net/~gherman/svglib.html

>

If your vector graphic is just a collection of PostScript moveTo,
lineTo, curveTo and stroke type commands then it is pretty simple to
convert this to reportlab PDFPathObject methods
I have done this a couple of times when I wanted to embed a company logo
and they provided me with it in PostScript format.


Eric



More information about the reportlab-users mailing list