summaryrefslogtreecommitdiff
path: root/sw/qa/extras/ooxmlexport
diff options
context:
space:
mode:
authorLászló Németh <nemeth@numbertext.org>2022-05-03 11:06:59 +0200
committerAndras Timar <andras.timar@collabora.com>2022-05-13 16:41:08 +0200
commitcd6f1440c576352b7d8cb67679aed779aa357412 (patch)
treec29d11a9ca56afd1182394cb7704246043f33370 /sw/qa/extras/ooxmlexport
parentf0ddc64c27a352117e5a7d1e2141a554caff36dc (diff)
tdf#146346 DOCX import: fix table margins in footnotes
Paragraph of the anchoring point of the floating table needs zero top and bottom margins, if the table was a not floating table in the footnote originally, otherwise docDefault (Standard) margins could result bigger vertical spaces around the table. Quasi regression from commit c46950fee11f5207fb8324947280cd565ae483e7 "tdf#143583 DOCX import: fix lost empty paragraphs of footnotes" (before this commit, empty paragraphs at the end of the footnotes were removed by accident, which hid the real problem fixed now). See also commit e11c51eefe8c3210cef2b5850f401ba67a401d01 "tdf#95806 tdf#125877 tdf#141172 DOCX: fix tables in footnotes" (Note: before this commit, only a single table was shown instead of the eight tables of the eight footnotes.) Change-Id: I4180a6f7d7c49faf0842637b23aa1c8c5680a76c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133752 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org> (cherry picked from commit d1ac8df139a2a65db45d1970ccc0b80e17d827f6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/133728
Diffstat (limited to 'sw/qa/extras/ooxmlexport')
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf146346.docxbin0 -> 20285 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport14.cxx9
2 files changed, 9 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf146346.docx b/sw/qa/extras/ooxmlexport/data/tdf146346.docx
new file mode 100644
index 000000000000..846a33e9ae56
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/tdf146346.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
index a8e416951a8c..ffa1968648ef 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport14.cxx
@@ -1245,6 +1245,15 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf143583)
assertXPath(pXml, "/w:footnotes/w:footnote[6]/w:p", 3);
}
+// skip test for macOS (missing fonts?)
+#if !defined(MACOSX)
+DECLARE_OOXMLEXPORT_TEST(testTdf146346, "tdf146346.docx")
+{
+ // This was 2 (by bad docDefault vertical margins around tables in footnotes)
+ CPPUNIT_ASSERT_EQUAL(1, getPages());
+}
+#endif
+
DECLARE_OOXMLEXPORT_TEST(testContSectBreakHeaderFooter, "cont-sect-break-header-footer.docx")
{
// Load a document with a continuous section break on page 2.