Draw images with canvas and use SimpleDocTemplate

后端 未结 3 1585
礼貌的吻别
礼貌的吻别 2021-01-12 12:15

I\'m writing pdfs with reportlab inside a django view, they are very simple, the header, the contents and the footer.

I\'m using SimpleDocTemplate wich fits very wel

3条回答
  •  [愿得一人]
    2021-01-12 12:20

    Your best option is to create a subclass of SimpleDocTemplate or BaseDocTemplate. In the build method you will have access to the canvas. If you want to tap into everything that SimpleDocTemplate does, you might try copying it directly from site-packages/reportlab/platypus/doctemplate.py.

提交回复
热议问题