how to group objects in reportlab, so that they stay together across new pages

后端 未结 3 1669
不知归路
不知归路 2021-02-13 13:37

I\'m generating some pdf files using reportlab. I have a certain section that is repeated. It contains of a header and a table:

            Story.append(Paragrap         


        
3条回答
  •  清酒与你
    2021-02-13 14:30

    this is the solution that I found going through the reportlab source code:

    paragraph = Paragraph(header_string, styleH)
    paragraph.keepWithNext = True
    Story.append(paragraph)
    Story.append(table)
    

提交回复
热议问题