diff options
author | Vasily Melenchuk <vasily.melenchuk@cib.de> | 2018-11-01 17:37:21 +0100 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2019-01-17 13:39:58 +0100 |
commit | 6da534c3bd944509d0666e8c6a94c3c707fbc006 (patch) | |
tree | 8d7e109be2f826c1cf927424cfcd2cd65c9f4f44 /chart2 | |
parent | 69b2edd7cb1f9c6ee767f618b671e46794922dc7 (diff) |
tdf#121205: Convert <a:br> to newline chars in chart title
Reviewed-on: https://gerrit.libreoffice.org/62752
Tested-by: Jenkins
Reviewed-by: Katarina Behrens <Katarina.Behrens@cib.de>
(cherry picked from commit 57d4cd80dcaf01fe4897d79d89e906d355410243)
Reviewed-on: https://gerrit.libreoffice.org/62990
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
(cherry picked from commit a1ea94fde40b82d0ec7ec842bf44cdeeea676aca)
Change-Id: I43d14025c48878c5bc035d492623f4fc52426e5e
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/qa/extras/chart2import.cxx | 16 | ||||
-rw-r--r-- | chart2/qa/extras/data/pptx/tdf121205.pptx | bin | 0 -> 42922 bytes |
2 files changed, 16 insertions, 0 deletions
diff --git a/chart2/qa/extras/chart2import.cxx b/chart2/qa/extras/chart2import.cxx index 1f73eea90977..428f3f801a53 100644 --- a/chart2/qa/extras/chart2import.cxx +++ b/chart2/qa/extras/chart2import.cxx @@ -109,6 +109,7 @@ public: void testTdf115107(); // import complex data point labels void testTdf115107_2(); // import complex data point labels in cobo charts with multiple data series + void testTdf121205(); CPPUNIT_TEST_SUITE(Chart2ImportTest); CPPUNIT_TEST(Fdo60083); @@ -172,6 +173,7 @@ public: CPPUNIT_TEST(testTdf115107); CPPUNIT_TEST(testTdf115107_2); + CPPUNIT_TEST(testTdf121205); CPPUNIT_TEST_SUITE_END(); @@ -1567,6 +1569,20 @@ void Chart2ImportTest::testTdf115107_2() CPPUNIT_ASSERT_EQUAL(OUString("Line"), aFields[2]->getString()); } +void Chart2ImportTest::testTdf121205() +{ + load("/chart2/qa/extras/data/pptx/", "tdf121205.pptx"); + Reference<chart2::XChartDocument> xChartDoc(getChartDocFromDrawImpress(0, 0), uno::UNO_QUERY); + + uno::Reference<chart2::XTitled> xTitled(xChartDoc, uno::UNO_QUERY_THROW); + CPPUNIT_ASSERT_MESSAGE("chart doc does not have title", xTitled.is()); + OUString aTitle = getTitleString(xTitled); + + // We expect title splitted in 3 lines + CPPUNIT_ASSERT_EQUAL(OUString("Firstline\nSecondline\nThirdline"), aTitle); +} + + CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ImportTest); CPPUNIT_PLUGIN_IMPLEMENT(); diff --git a/chart2/qa/extras/data/pptx/tdf121205.pptx b/chart2/qa/extras/data/pptx/tdf121205.pptx Binary files differnew file mode 100644 index 000000000000..e60849ec02e0 --- /dev/null +++ b/chart2/qa/extras/data/pptx/tdf121205.pptx |