You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-dev@xmlgraphics.apache.org by "Gregor Berg (JIRA)" <ji...@apache.org> on 2015/02/20 13:20:11 UTC
[jira] [Created] (FOP-2451) [PATCH] removal of invalid row-span
attribute values in table-cells
Gregor Berg created FOP-2451:
--------------------------------
Summary: [PATCH] removal of invalid row-span attribute values in table-cells
Key: FOP-2451
URL: https://issues.apache.org/jira/browse/FOP-2451
Project: Fop
Issue Type: Bug
Components: fo/unqualified
Affects Versions: 1.1
Environment: tested on Win7 and Mac OS 10.9
Reporter: Gregor Berg
Fix For: 1.1
Since I have to deal with tables edited in HTML editors which produce invalid row-span/col-span attributes, I had to work around the row-span validation error. Thus, this patch tries to recover from the validation error related to a table-cell trying to span over more rows than its parent provides.
Affected testcases: all four IllegalRowSpanTestCase (no error is thrown, instead the table is created and can be checked for, e.g., number of rows)
This is a first draft. If the efforts are deemed worthwhile, I would try to port it to the trunk version.
Recovery process in detail:
As soon as the error condition is encountered, any remaining rows are checked for PrimaryGridUnits (PGU) - if there are none, it can be assumed that only empty GridUnits are present (created as fillers to handle the row-span of an above PGU). Such rows are removed, the corresponding PGUs cope with this removal by adjusting their pgu.rows and by decreasing the row-span of their pgu.cell.
Finally, the last valid row encountered resets its borders corresponding to its modified rowgroup (since this row may now be the last row of a table, its borders are updated accordingly).
This
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)