summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2019-08-23 09:41:51 +0200
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2019-08-23 10:43:02 +0200
commit66576edf4e7ed26f09788fac348ea6b556ae1c47 (patch)
tree1ba305c48472a47f23411604e42860fae7b8d88a /sw
parent5e01bae7f4a6f81ff70f328d0289dae37fab01eb (diff)
tdf#103345 Import decimalEnclosedCircle correctly
Change-Id: I227d149d07ea0f7b2569e5df5a5589834374fac9 Reviewed-on: https://gerrit.libreoffice.org/77992 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/ooxmlimport/data/numbering-circle.docxbin0 -> 4952 bytes
-rw-r--r--sw/qa/extras/ooxmlimport/ooxmlimport2.cxx20
2 files changed, 20 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmlimport/data/numbering-circle.docx b/sw/qa/extras/ooxmlimport/data/numbering-circle.docx
new file mode 100644
index 000000000000..b8c1da3d6f87
--- /dev/null
+++ b/sw/qa/extras/ooxmlimport/data/numbering-circle.docx
Binary files differ
diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
index d664d78e6d33..e2d930b9f4bf 100644
--- a/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
+++ b/sw/qa/extras/ooxmlimport/ooxmlimport2.cxx
@@ -414,6 +414,26 @@ DECLARE_OOXMLIMPORT_TEST(testTdf126114, "tdf126114.docx")
CPPUNIT_ASSERT_EQUAL(7, getLength());
}
+DECLARE_OOXMLIMPORT_TEST(testTdf103345, "numbering-circle.docx")
+{
+ uno::Reference<beans::XPropertySet> xPropertySet(
+ getStyles("NumberingStyles")->getByName("WWNum1"), uno::UNO_QUERY);
+ uno::Reference<container::XIndexAccess> xLevels(
+ xPropertySet->getPropertyValue("NumberingRules"), uno::UNO_QUERY);
+ uno::Sequence<beans::PropertyValue> aProps;
+ xLevels->getByIndex(0) >>= aProps; // 1st level
+
+ for (int i = 0; i < aProps.getLength(); ++i)
+ {
+ if (aProps[i].Name == "NumberingType")
+ {
+ CPPUNIT_ASSERT_EQUAL(style::NumberingType::CIRCLE_NUMBER,
+ aProps[i].Value.get<sal_Int16>());
+ return;
+ }
+ }
+}
+
// tests should only be added to ooxmlIMPORT *if* they fail round-tripping in ooxmlEXPORT
CPPUNIT_PLUGIN_IMPLEMENT();