diff options
-rw-r--r-- | sw/qa/extras/ooxmltok/data/n693238.docx | bin | 0 -> 9933 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmltok/ooxmltok.cxx | 17 |
2 files changed, 17 insertions, 0 deletions
diff --git a/sw/qa/extras/ooxmltok/data/n693238.docx b/sw/qa/extras/ooxmltok/data/n693238.docx Binary files differnew file mode 100644 index 000000000000..5bcda0fff6f7 --- /dev/null +++ b/sw/qa/extras/ooxmltok/data/n693238.docx diff --git a/sw/qa/extras/ooxmltok/ooxmltok.cxx b/sw/qa/extras/ooxmltok/ooxmltok.cxx index ce4a91176301..790194d7b55b 100644 --- a/sw/qa/extras/ooxmltok/ooxmltok.cxx +++ b/sw/qa/extras/ooxmltok/ooxmltok.cxx @@ -75,6 +75,7 @@ public: void testN758883(); void testN766481(); void testN766487(); + void testN693238(); CPPUNIT_TEST_SUITE(Test); #if !defined(MACOSX) && !defined(WNT) @@ -98,6 +99,7 @@ public: CPPUNIT_TEST(testN758883); CPPUNIT_TEST(testN766481); CPPUNIT_TEST(testN766487); + CPPUNIT_TEST(testN693238); #endif CPPUNIT_TEST_SUITE_END(); @@ -661,6 +663,21 @@ void Test::testN766487() CPPUNIT_ASSERT_EQUAL(sal_Int32(TWIP_TO_MM100(-360)), nValue); } +void Test::testN693238() +{ + /* + * + * The problem was that a continous section break at the end of the doc caused the margins to be ignored. + * + * xray ThisComponent.StyleFamilies.PageStyles.Default.LeftMargin ' was 2000, should be 635 + */ + load("n693238.docx"); + uno::Reference<beans::XPropertySet> xPropertySet(getStyles("PageStyles")->getByName("Default"), uno::UNO_QUERY); + sal_Int32 nValue = 0; + xPropertySet->getPropertyValue("LeftMargin") >>= nValue; + CPPUNIT_ASSERT_EQUAL(sal_Int32(635), nValue); +} + CPPUNIT_TEST_SUITE_REGISTRATION(Test); CPPUNIT_PLUGIN_IMPLEMENT(); |