PDF: Table cells duplicated before and after a page break
Posted: Wed Dec 04, 2024 1:09 am
Hello everyone,
I'm seeing a weird and inconsistent issue outputting DITA content to PDF. Sometimes, if a table crosses a page break, one or more rows of the table will be printed twice: before and after the page break. The attached example is a <choicetable>, but the same thing happened with a standard <table> before I shrank its cell padding. Note that the header row is printed an additional time before the page break as well. It seems to be related to the particular placement of the table relative to the page break. I tried exporting an example ditamap with only the offending topic and its parent. The spacing of the topic on the page came out slightly differently, and the table split across the page break correctly, with the header row repeated at the top of the second page.
My custom CSS normally includes the lines:
Has anyone encountered something like this before?
I'm seeing a weird and inconsistent issue outputting DITA content to PDF. Sometimes, if a table crosses a page break, one or more rows of the table will be printed twice: before and after the page break. The attached example is a <choicetable>, but the same thing happened with a standard <table> before I shrank its cell padding. Note that the header row is printed an additional time before the page break as well. It seems to be related to the particular placement of the table relative to the page break. I tried exporting an example ditamap with only the offending topic and its parent. The spacing of the topic on the page came out slightly differently, and the table split across the page break correctly, with the header row repeated at the top of the second page.
My custom CSS normally includes the lines:
When I tried commenting this out, I got a different version of the same issue (see second attachment). I'm using DITA 2.0. To attempt to rule out a publishing incompatibility with 2.0, I've tried creating test files to try switching between 1.3 and 2.0, but I have been unable to reproduce the issue with a smaller ditamap in either version.tr,
th,
td {
page-break-inside: avoid;
}
Has anyone encountered something like this before?