diff options
author | Szabolcs Toth <szabolcs450@gmail.com> | 2020-03-17 11:39:33 +0100 |
---|---|---|
committer | Balazs Varga <balazs.varga991@gmail.com> | 2020-03-31 10:09:13 +0200 |
commit | cb441c4d0adf698e6af9073c6c3285a66b76871e (patch) | |
tree | 27031285c8443ea52f41c3a466d584b6c5a97683 /sw/qa | |
parent | 41dbdc1499f4512941a38e5972d03d26a2397a89 (diff) |
tdf#100751 DOCX VML shape import: fix arrow direction
Flips along both the y- and x-axis weren't imported,
resulting wrong direction of arrow and other shapes.
Co-Author: Balázs Regényi
Change-Id: Iac222ac2a6a6110289969c32b40828b83da0aefd
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90646
Tested-by: Jenkins
Reviewed-by: Balazs Varga <balazs.varga991@gmail.com>
Diffstat (limited to 'sw/qa')
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/tdf100751_arrowBothFlip.docx | bin | 0 -> 15546 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport3.cxx | 12 |
2 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/tdf100751_arrowBothFlip.docx b/sw/qa/extras/ooxmlexport/data/tdf100751_arrowBothFlip.docx Binary files differnew file mode 100644 index 000000000000..8a57f69eaef0 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/tdf100751_arrowBothFlip.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx index 4a7219a90a86..498cf8a95772 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx @@ -1103,6 +1103,18 @@ DECLARE_OOXMLEXPORT_TEST(testVerticalBorders, "calendar3.docx") assertXPathChildren(pXmlDocument, "/w:document/w:body/w:tbl/w:tr[3]/w:tc[3]/w:tcPr/w:tcBorders", 2); } +DECLARE_OOXMLEXPORT_TEST(testArrowFlipXY, "tdf100751_arrowBothFlip.docx") +{ + // tdf#100751: Both x and y flip should happen. + + xmlDocPtr pXmlDocument = parseExport("word/document.xml"); + if (!pXmlDocument) + return; + + OUString arrowStyle = getXPath(pXmlDocument, "/w:document/w:body/w:p/w:r/mc:AlternateContent/mc:Fallback/w:pict/v:group/v:shape[2]", "style"); + CPPUNIT_ASSERT(arrowStyle.indexOf(u"flip:xy") != sal_Int32(-1)); +} + CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |