[ 
https://issues.apache.org/jira/browse/FOP-1099?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Vincent Hennebert updated FOP-1099:
-----------------------------------

    Attachment: footnote_repeated-table-heading.patch

I had another go at this problem and came up with the attached patch. It 
leverages the patch from Matthias and adds support for repeated table 
headers/footers.

For the first header/last footer, footnotes are treated the usual way. That 
means that if the table is not broken over pages then footnotes coming from its 
header/footer will be handled just like any other footnote.

For repeated headers/footers, I added a mechanism that registers footnotes 
separately and inserts them at the right place at area creation time. That is, 
footnotes from repeated headers first, then other footnotes, then footnotes 
from repeated footers.

The size of the footnote is accounted for in the penalty that represents the 
header/footer. As a consequence, the footnote will always be on the same page 
as the header/footer and will never be deferred to later pages. The regular 
footnote-handling mechanism is essentially by-passed here.

This works well except in the case of nested tables, when the outer table has a 
repeated table-footer. Gaps will be visible between that footer and the inner 
table, and the outer footer may even be mixed with the footnotes.

I guess we’ll have to leave with this limitation. Footnotes in repeated table 
headers/footers already is a degenerate case IMO, so I would say footnotes in 
repeated headers/footers in nested tables is pushing too far...

If people could try out this patch and give feedback, that would be great. I’ll 
leave a few days for peer review and then, if nobody has objected, I'll commit 
it to trunk.

> [PATCH] footnotes within tables and lists get lost
> --------------------------------------------------
>
>                 Key: FOP-1099
>                 URL: https://issues.apache.org/jira/browse/FOP-1099
>             Project: Fop
>          Issue Type: Bug
>          Components: layout/unqualified
>    Affects Versions: trunk
>         Environment: Operating System: other
> Platform: Other
>            Reporter: gerhard oettl
>         Attachments: 1044-tab-header-footnote-no-repeat.patch, 
> 1044-tab-header-footnote-no-repeat.xml, b37579.diff, b37579.diff, 
> b37579_2.patch, bugzilla37579.patch, dorfchronik.fo, dorfchronik.fo.list3, 
> dorfchronik.fo.table3, duplicated-footnote.fo, duplicated-footnote.pdf, 
> footnote-end-page-sequence.fo, footnote-end-page-sequence.pdf, 
> footnote-missing_page2.fo, footnote-missing_page2.pdf, footnote.fo, 
> footnote_repeated-table-heading.patch, footnoteintable.patch, 
> footnotes.080502.diff, footnotespatch, fussnote.fo, inverted-footnotes.fo, 
> inverted-footnotes.pdf, table_list_footnotes.diff, vtest.fo
>
>
> Footnote outside of tables works, inside table-cell not.
> The compliance page only speaks about restrictions within multicolumn 
> documents.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to