jorisschellekens / borb

borb is a library for reading, creating and manipulating PDF files in python.
https://borbpdf.com/
Other
3.4k stars 147 forks source link

BUG I can't disable/remove lines in the table #206

Closed manuscriptum closed 4 months ago

manuscriptum commented 4 months ago

I can't disable/remove lines in the table Hello everyone! I'm facing a problem. I can't disable/remove lines in the table. But at the same time the lines in the table are displayed. Can you tell me what I'm doing wrong?

To Reproduce To achieve this, I add a table to the layout in this way.

    layout.add(
        FlexibleColumnWidthTable(number_of_columns=1, number_of_rows=3, border_top=False, border_right=False, border_bottom=False, border_left=False)
        .add(Paragraph("First line"))
        .add(Paragraph("Second line"))
        .add(Paragraph("Third line"))
    )

Expected behaviour A clear and concise description of what you expected to happen.

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Additional context Add any other context about the problem here.

jorisschellekens commented 4 months ago

Hi @manuscriptum,

Every LayoutElement has these (border) options in their constructor. They are responsible for drawing a border around the LayoutElement.

You are trying to use them to control borders inside the Table.

There are 2 options:

Finally, I would like to point out the issues section on github is not meant to serve as a replacement for Stackoverflow. Borb has its own tag there. By using Stackoverflow you are ensuring other people who face a similar issue will find help more quickly.

Kind regards, Joris Schellekens