summaryrefslogtreecommitdiff
path: root/sw/qa/extras/ooxmlexport
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2019-03-04 21:24:58 +0100
committerMiklos Vajna <vmiklos@collabora.com>2019-03-05 08:35:02 +0100
commitfa10258d723a0c50941166ba13274308fb0cfcbe (patch)
treeb001418666ee1c7fbf0c38468dd0f6ac03dcd84d /sw/qa/extras/ooxmlexport
parent25d176ada67ada550bd4d0d08177c232cf7eeb37 (diff)
tdf#123243 DOCX import: make increased anchored obj spacing cond more strict
Regression from commit 8b73bafbc18acb4dd8911d2f2de8158d98eb6144 (tdf#115719 DOCX import: increase paragraph spacing for anchored objects, 2018-02-14), which is an import-time workaround for a Word layout bug. Re-checking the original document from that bug, this only happens with more anchored shapes (to the same paragraph), so make the workaround condition more strict, fixing the layout of this bugdoc. (Which means tdf115719.docx and tdf115719b.docx are modified to be more close to the original bugdoc.) Just checked, sadly Word's layout bug is still there in MSO 2019, so can't revert our emulation of it (not yet). Change-Id: I26f74a497b7718f8f3a2eadac481c8722e85e680 Reviewed-on: https://gerrit.libreoffice.org/68708 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Diffstat (limited to 'sw/qa/extras/ooxmlexport')
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf115719.docxbin11905 -> 18335 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/data/tdf123243.docxbin0 -> 11905 bytes
-rw-r--r--sw/qa/extras/ooxmlexport/ooxmlexport11.cxx7
3 files changed, 7 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf115719.docx b/sw/qa/extras/ooxmlexport/data/tdf115719.docx
index 9519a2a14524..f98f8b4a05dc 100644
--- a/sw/qa/extras/ooxmlexport/data/tdf115719.docx
+++ b/sw/qa/extras/ooxmlexport/data/tdf115719.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/data/tdf123243.docx b/sw/qa/extras/ooxmlexport/data/tdf123243.docx
new file mode 100644
index 000000000000..9519a2a14524
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/tdf123243.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
index c277b9efc4dd..9b1dd0627cb0 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport11.cxx
@@ -292,6 +292,13 @@ DECLARE_OOXMLEXPORT_TEST(testTdf115719, "tdf115719.docx")
CPPUNIT_ASSERT_EQUAL(2, getPages());
}
+DECLARE_OOXMLEXPORT_TEST(testTdf123243, "tdf123243.docx")
+{
+ // Without the accompanying fix in place, this test would have failed with 'Expected: 1; Actual:
+ // 2'; i.e. unexpected paragraph margin created 2 pages.
+ CPPUNIT_ASSERT_EQUAL(1, getPages());
+}
+
DECLARE_OOXMLEXPORT_TEST(testTdf116410, "tdf116410.docx")
{
// Opposite of the above, was 2 pages, should be 1 page.