Commit Graph
5 Commits
Author SHA1 Message Date
John MacFarlane 1d62883e14 HTML reader: require unanimity for RowHeadColumns.
Previously we used the max.  #8634 switched to the min, but this
had bad results.  This commit sets the RowHeadColumns to the consensus
value from all rows, or 0 if there is no consensus.

See #8984.
2023-08-05 11:48:29 -07:00
John MacFarlane acbc382ff4 Revert "Update #8764 command test for latest change to HTML table parser (#8634)."
This reverts commit 52d352a5ae.
2023-08-05 11:16:10 -07:00
John MacFarlane 52d352a5ae Update #8764 command test for latest change to HTML table parser (#8634). 2023-06-24 11:21:51 -07:00
Michael Stahl 737446f33d Writers.OpenDocument: handle row header column cells as header cells
The previous commit prevented header column cells from being dropped on
the floor, this one changes the paragraph style to "Table_20_Heading".

Note that for the test input, the result is not correct: the
AnnotatedTable type cannot represent the HTML input properly, as it only
has a concept of header rows and header columns, but HTML can have an
individual cell that is a header (not 100% sure but they way i read
https://html.spec.whatwg.org/#header-and-data-cell-semantics the <th>
cell here is both a row header cell and a column header cell while the
other cells in the row and column are not header cells), and header
cells may even appear "in the middle" of a table (see example in
https://html.spec.whatwg.org/#the-th-element).

So while this appears like it's the right thing to do for
Writer.OpenDocument, it's not clear if this is going to make things
better or worse overall.

Fixes: #8764
2023-05-01 20:55:37 -07:00
Michael Stahl 2881c12740 Writers.OpenDocument: handle row header column cells as ordinary cells
While ODF 1.3 part 3 does specify a 9.1.11 <table:table-header-columns>
element, in practice it's only implemented by spreadsheet applications,
not word processors.

So simply treat the row header columns as ordinary table columns, at
least they don't get lost then.

Fixes: #8764
2023-05-01 20:55:37 -07:00