[reportlab-users] merge 2 canvas
Thomas Kremmel
thomasspin at gmail.com
Fri Aug 27 13:32:59 EDT 2010
Hi,
I want to merge 2 canvas and found this article dealing with this topic.
http://two.pairlist.net/pipermail/reportlab-users/2006-May/004940.html
If I understand it right it is possible, using the pycanvas class.
http://www.java2s.com/Open-Source/Python/PDF/ReportLab/ReportLab_2_4/src/reportlab/pdfgen/pycanvas.py.htm
I tried doing it like described in the message, but the following does not
work.
p = pycanvas.Canvas(buffer,pagesize=PAGESIZE)
#init your canvas
source_code_equiv = str(p)
#for testing - double the canvas
source_code_equiv += source_code_equiv
p = source_code_equiv.doIt(buffer)
p.showPage()
p.save()
This obviously can not work since I'm calling doIt on a string, but I have
no clue how to do it.
Maybe someone an idea!?
br
Tom
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://two.pairlist.net/pipermail/reportlab-users/attachments/20100827/e5c181db/attachment.htm>
More information about the reportlab-users
mailing list