[reportlab-users] Patch to support tables with oversize cells

Lennart Regebro lregebro at shoobx.com
Wed Jun 1 07:33:30 EDT 2022


Yes, two small bugs in height alignments that didn't show up in any
previous test. Good find.



On Wed, Jun 1, 2022 at 10:55 AM Robin Becker <robin at reportlab.com> wrote:

> On 30/05/2022 15:59, Lennart Regebro wrote:
> > OK, that seems to have been the only case of me setting attributes on
> > T/self.
> >
> > However, I also added a matrixCopy() function and used it the cases
> where I
> > modify _cellvalues and _cellStyles, to make sure the original table
> doesn't
> > get modified that way.
> >
> ........
>
> Hi Lennart,
>
> thanks for v8. I tested and find no problems for splitInrow=0. I see that
> your examples seem OK as well.
>
> However, I made a slightly more extreme case with two overlapping split
> rows not starting at the same row. I see that
> some splits do work, but there are some glitches.
>
> For your convenience I put the code (extended from before) here
>
> https://www.reportlab.com/ftp/lennart/lennart-example.py
>
>
> I tested by using the statement
> for W in 30 40 50 60; do
>      python tmp/lennart-example.py --useData=3 --split=$W --splitInRow=1
> --splitByRow=0 --pdfn=tmp/ssir-$W.pdf
> done
>
> the results are here
>
> https://www.reportlab.com/ftp/lennart/ssir-30.pdf #no split possible
> https://www.reportlab.com/ftp/lennart/ssir-40.pdf #splits but first
> column is positioned wrongly
> https://www.reportlab.com/ftp/lennart/ssir-50.pdf #ditto
> https://www.reportlab.com/ftp/lennart/ssir-40.pdf #splits but text is
> mis-positioned in col5
>
> Not exactly sure what's wrong, but it doesn't look right in these cases.
> --
> Robin Becker
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20220601/ea88d3c7/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: splitInRow-v9.diff
Type: text/x-patch
Size: 55821 bytes
Desc: not available
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20220601/ea88d3c7/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test_table_inrowsplit.pdf
Type: application/pdf
Size: 13996 bytes
Desc: not available
URL: <https://pairlist2.pair.net/pipermail/reportlab-users/attachments/20220601/ea88d3c7/attachment-0001.pdf>


More information about the reportlab-users mailing list