[reportlab-users] Embedding Platypus Story in Canvas

Tim Roberts timr at probo.com
Tue Nov 6 13:59:53 EST 2007


Rich Shepard wrote:

> On Tue, 6 Nov 2007, Tim Roberts wrote:

>

>>

>> Maybe that's the issue. Are you fetching the canvas from the doc

>> template? It creates its own canvas. You can't use your own.

>

> This looks like the problem source. I define 'doc' as

> SimpleDocTemplate()

> which does not allow me to pass the defined canvas. Not before

> instantiating

> PageTemplate(), I need to look for an example to follow.


You have two choices.

1. You can let Platypus create the canvas, and then use the one it
creates (doc.canv)
2. You can derive your own class from SimpleDocTemplate, and override
_startBuild to use the canvas you pass in.

--
Tim Roberts, timr at probo.com
Providenza & Boekelheide, Inc.



More information about the reportlab-users mailing list