How do I continue a content to a next page in Reportlabs - Python

最后都变了- 提交于 2019-12-01 15:48:50
sk1p

I'd advice using the more high-level primitives of reportlab, that is, document templates, frames and flowables. That way, you get splitting for "free". An example from the related questions

Use table.split():

from reportlab.lib.pagesizes import A4 # im using A4

width, height = A4
table_pieces = table.split(width, height)

for table_piece in table_pieces:
    table_piece.drawOn(the_canvas, *coordinates)
    the_canvas.show_page()
the_canvas.save()

Tell me if it helped :)

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!