From c451207b08edc36fa5c2f1af5556a8d211e023ed Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Tue, 12 Jan 2021 09:49:10 -0800 Subject: Docx writer: handle table header using styles. Instead of hard-coding the border and header cell vertical alignment, we now let this be determined by the Table style, making use of Word's "conditional formatting" for the table's first row. For headerless tables, we use the tblLook element to tell Word not to apply conditional first-row formatting. Closes #7008. --- test/docx/golden/block_quotes.docx | Bin 10001 -> 10092 bytes test/docx/golden/codeblock.docx | Bin 9853 -> 9944 bytes test/docx/golden/comments.docx | Bin 10188 -> 10279 bytes test/docx/golden/custom_style_no_reference.docx | Bin 9952 -> 10042 bytes test/docx/golden/custom_style_preserve.docx | Bin 10578 -> 10666 bytes test/docx/golden/definition_list.docx | Bin 9850 -> 9941 bytes .../docx/golden/document-properties-short-desc.docx | Bin 9856 -> 9947 bytes test/docx/golden/document-properties.docx | Bin 10332 -> 10423 bytes test/docx/golden/headers.docx | Bin 9989 -> 10080 bytes test/docx/golden/image.docx | Bin 26667 -> 26758 bytes test/docx/golden/inline_code.docx | Bin 9789 -> 9880 bytes test/docx/golden/inline_formatting.docx | Bin 9969 -> 10060 bytes test/docx/golden/inline_images.docx | Bin 26725 -> 26816 bytes test/docx/golden/link_in_notes.docx | Bin 10010 -> 10101 bytes test/docx/golden/links.docx | Bin 10185 -> 10276 bytes test/docx/golden/lists.docx | Bin 10261 -> 10352 bytes test/docx/golden/lists_continuing.docx | Bin 10052 -> 10143 bytes test/docx/golden/lists_multiple_initial.docx | Bin 10141 -> 10232 bytes test/docx/golden/lists_restarting.docx | Bin 10053 -> 10144 bytes test/docx/golden/nested_anchors_in_header.docx | Bin 10148 -> 10239 bytes test/docx/golden/notes.docx | Bin 9955 -> 10046 bytes test/docx/golden/raw-blocks.docx | Bin 9888 -> 9980 bytes test/docx/golden/raw-bookmarks.docx | Bin 10023 -> 10115 bytes test/docx/golden/table_one_row.docx | Bin 9834 -> 9932 bytes test/docx/golden/table_with_list_cell.docx | Bin 10199 -> 10249 bytes test/docx/golden/tables.docx | Bin 10225 -> 10266 bytes test/docx/golden/track_changes_deletion.docx | Bin 9833 -> 9924 bytes test/docx/golden/track_changes_insertion.docx | Bin 9816 -> 9907 bytes test/docx/golden/track_changes_move.docx | Bin 9850 -> 9941 bytes .../golden/track_changes_scrubbed_metadata.docx | Bin 9962 -> 10053 bytes test/docx/golden/unicode.docx | Bin 9774 -> 9865 bytes test/docx/golden/verbatim_subsuper.docx | Bin 9822 -> 9913 bytes 32 files changed, 0 insertions(+), 0 deletions(-) (limited to 'test/docx') diff --git a/test/docx/golden/block_quotes.docx b/test/docx/golden/block_quotes.docx index bbc8d8de9..3e1bf16e7 100644 Binary files a/test/docx/golden/block_quotes.docx and b/test/docx/golden/block_quotes.docx differ diff --git a/test/docx/golden/codeblock.docx b/test/docx/golden/codeblock.docx index e20efcab4..66f055063 100644 Binary files a/test/docx/golden/codeblock.docx and b/test/docx/golden/codeblock.docx differ diff --git a/test/docx/golden/comments.docx b/test/docx/golden/comments.docx index f1185da98..fb3a02a0a 100644 Binary files a/test/docx/golden/comments.docx and b/test/docx/golden/comments.docx differ diff --git a/test/docx/golden/custom_style_no_reference.docx b/test/docx/golden/custom_style_no_reference.docx index 83243ab8c..bc6c2702a 100644 Binary files a/test/docx/golden/custom_style_no_reference.docx and b/test/docx/golden/custom_style_no_reference.docx differ diff --git a/test/docx/golden/custom_style_preserve.docx b/test/docx/golden/custom_style_preserve.docx index 17804bb81..8c555a5bd 100644 Binary files a/test/docx/golden/custom_style_preserve.docx and b/test/docx/golden/custom_style_preserve.docx differ diff --git a/test/docx/golden/definition_list.docx b/test/docx/golden/definition_list.docx index 21629e208..c21b3a5b3 100644 Binary files a/test/docx/golden/definition_list.docx and b/test/docx/golden/definition_list.docx differ diff --git a/test/docx/golden/document-properties-short-desc.docx b/test/docx/golden/document-properties-short-desc.docx index 5cf8db0b0..92ce144e9 100644 Binary files a/test/docx/golden/document-properties-short-desc.docx and b/test/docx/golden/document-properties-short-desc.docx differ diff --git a/test/docx/golden/document-properties.docx b/test/docx/golden/document-properties.docx index 14bfab6d4..d21b67309 100644 Binary files a/test/docx/golden/document-properties.docx and b/test/docx/golden/document-properties.docx differ diff --git a/test/docx/golden/headers.docx b/test/docx/golden/headers.docx index 416743aa1..3558a47bf 100644 Binary files a/test/docx/golden/headers.docx and b/test/docx/golden/headers.docx differ diff --git a/test/docx/golden/image.docx b/test/docx/golden/image.docx index ef2940f89..606df92a3 100644 Binary files a/test/docx/golden/image.docx and b/test/docx/golden/image.docx differ diff --git a/test/docx/golden/inline_code.docx b/test/docx/golden/inline_code.docx index 479ea65ec..759269cac 100644 Binary files a/test/docx/golden/inline_code.docx and b/test/docx/golden/inline_code.docx differ diff --git a/test/docx/golden/inline_formatting.docx b/test/docx/golden/inline_formatting.docx index e12e3b38d..c37777080 100644 Binary files a/test/docx/golden/inline_formatting.docx and b/test/docx/golden/inline_formatting.docx differ diff --git a/test/docx/golden/inline_images.docx b/test/docx/golden/inline_images.docx index 8bd57bb8c..9450b1a73 100644 Binary files a/test/docx/golden/inline_images.docx and b/test/docx/golden/inline_images.docx differ diff --git a/test/docx/golden/link_in_notes.docx b/test/docx/golden/link_in_notes.docx index 2c6a638fc..6f0b830e6 100644 Binary files a/test/docx/golden/link_in_notes.docx and b/test/docx/golden/link_in_notes.docx differ diff --git a/test/docx/golden/links.docx b/test/docx/golden/links.docx index 11e52c4b1..e53889cfb 100644 Binary files a/test/docx/golden/links.docx and b/test/docx/golden/links.docx differ diff --git a/test/docx/golden/lists.docx b/test/docx/golden/lists.docx index 7667990c4..5dbe298b7 100644 Binary files a/test/docx/golden/lists.docx and b/test/docx/golden/lists.docx differ diff --git a/test/docx/golden/lists_continuing.docx b/test/docx/golden/lists_continuing.docx index 3e8c6d2b2..194181288 100644 Binary files a/test/docx/golden/lists_continuing.docx and b/test/docx/golden/lists_continuing.docx differ diff --git a/test/docx/golden/lists_multiple_initial.docx b/test/docx/golden/lists_multiple_initial.docx index 05a7cf060..6e0b634f7 100644 Binary files a/test/docx/golden/lists_multiple_initial.docx and b/test/docx/golden/lists_multiple_initial.docx differ diff --git a/test/docx/golden/lists_restarting.docx b/test/docx/golden/lists_restarting.docx index f5ae4a384..477178e77 100644 Binary files a/test/docx/golden/lists_restarting.docx and b/test/docx/golden/lists_restarting.docx differ diff --git a/test/docx/golden/nested_anchors_in_header.docx b/test/docx/golden/nested_anchors_in_header.docx index d02c77271..51110356e 100644 Binary files a/test/docx/golden/nested_anchors_in_header.docx and b/test/docx/golden/nested_anchors_in_header.docx differ diff --git a/test/docx/golden/notes.docx b/test/docx/golden/notes.docx index f7fdcbe11..b6206cdf5 100644 Binary files a/test/docx/golden/notes.docx and b/test/docx/golden/notes.docx differ diff --git a/test/docx/golden/raw-blocks.docx b/test/docx/golden/raw-blocks.docx index ae7f8f1f0..07b576080 100644 Binary files a/test/docx/golden/raw-blocks.docx and b/test/docx/golden/raw-blocks.docx differ diff --git a/test/docx/golden/raw-bookmarks.docx b/test/docx/golden/raw-bookmarks.docx index 5e433b736..d46095eb7 100644 Binary files a/test/docx/golden/raw-bookmarks.docx and b/test/docx/golden/raw-bookmarks.docx differ diff --git a/test/docx/golden/table_one_row.docx b/test/docx/golden/table_one_row.docx index d404878c6..7caba4e93 100644 Binary files a/test/docx/golden/table_one_row.docx and b/test/docx/golden/table_one_row.docx differ diff --git a/test/docx/golden/table_with_list_cell.docx b/test/docx/golden/table_with_list_cell.docx index 79c395262..6aaa6da61 100644 Binary files a/test/docx/golden/table_with_list_cell.docx and b/test/docx/golden/table_with_list_cell.docx differ diff --git a/test/docx/golden/tables.docx b/test/docx/golden/tables.docx index df9680773..5746c5ad0 100644 Binary files a/test/docx/golden/tables.docx and b/test/docx/golden/tables.docx differ diff --git a/test/docx/golden/track_changes_deletion.docx b/test/docx/golden/track_changes_deletion.docx index bb73b82f6..5f22dccc6 100644 Binary files a/test/docx/golden/track_changes_deletion.docx and b/test/docx/golden/track_changes_deletion.docx differ diff --git a/test/docx/golden/track_changes_insertion.docx b/test/docx/golden/track_changes_insertion.docx index 7df484aaa..ab5c4f56d 100644 Binary files a/test/docx/golden/track_changes_insertion.docx and b/test/docx/golden/track_changes_insertion.docx differ diff --git a/test/docx/golden/track_changes_move.docx b/test/docx/golden/track_changes_move.docx index d717b93ab..085f33162 100644 Binary files a/test/docx/golden/track_changes_move.docx and b/test/docx/golden/track_changes_move.docx differ diff --git a/test/docx/golden/track_changes_scrubbed_metadata.docx b/test/docx/golden/track_changes_scrubbed_metadata.docx index 791182db2..1ac86d5c8 100644 Binary files a/test/docx/golden/track_changes_scrubbed_metadata.docx and b/test/docx/golden/track_changes_scrubbed_metadata.docx differ diff --git a/test/docx/golden/unicode.docx b/test/docx/golden/unicode.docx index b64a7b58e..c2c443b19 100644 Binary files a/test/docx/golden/unicode.docx and b/test/docx/golden/unicode.docx differ diff --git a/test/docx/golden/verbatim_subsuper.docx b/test/docx/golden/verbatim_subsuper.docx index b5116d1a8..5ea18d32e 100644 Binary files a/test/docx/golden/verbatim_subsuper.docx and b/test/docx/golden/verbatim_subsuper.docx differ -- cgit v1.2.3