diff options
author | Tünde Tóth <tundeth@gmail.com> | 2020-03-17 15:25:56 +0100 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2020-03-30 12:45:57 +0200 |
commit | ab40a7843a66d1fe276224db16ddaecd538df234 (patch) | |
tree | 9651bd37bc32f184de0eca75d2aa83658f612c9c /chart2 | |
parent | 55c8ab7294e9e1651b94215d4ff14c7afcb7d733 (diff) |
tdf#131370 chart: implement OOXML import/export of legend overlay feature
Follow-up of the following commits related to the new UNO property
Overlay for legends:
commit 9fab1ba8ddc59924c633aa17c65f7330a4762726
(tdf#75330 add a new overlay/no-overlay feature for the legend)
commit 65123d41f62597053bc3893ee4fb46868a6b1f2d
(tdf#75330 chart: implement ODF import/export of legend overlay feature)
Change-Id: Ie3eff9b8a4f99980a7ae28add909a27eb0e9d14b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90655
Tested-by: Jenkins
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/qa/extras/chart2export.cxx | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/chart2/qa/extras/chart2export.cxx b/chart2/qa/extras/chart2export.cxx index 323a026594d8..0570ca4697c6 100644 --- a/chart2/qa/extras/chart2export.cxx +++ b/chart2/qa/extras/chart2export.cxx @@ -2597,16 +2597,27 @@ void Chart2ExportTest::testTdf126076() void Chart2ExportTest::testTdf75330() { - mbSkipValidation = true; load("/chart2/qa/extras/data/ods/", "legend_overlay.ods"); reload("calc8"); - uno::Reference< chart2::XChartDocument > xChart2Doc = getChartDocFromSheet(0, mxComponent); - uno::Reference< chart::XChartDocument > xChartDoc (xChart2Doc, uno::UNO_QUERY); - uno::Reference<drawing::XShape> xLegend = xChartDoc->getLegend(); - Reference<beans::XPropertySet> xPropertySet(xLegend, uno::UNO_QUERY_THROW); - bool bOverlay = false; - CPPUNIT_ASSERT(xPropertySet->getPropertyValue("Overlay") >>= bOverlay); - CPPUNIT_ASSERT(bOverlay); + { + uno::Reference<chart2::XChartDocument> xChart2Doc = getChartDocFromSheet(0, mxComponent); + uno::Reference<chart::XChartDocument> xChartDoc(xChart2Doc, uno::UNO_QUERY); + uno::Reference<drawing::XShape> xLegend = xChartDoc->getLegend(); + Reference<beans::XPropertySet> xPropertySet(xLegend, uno::UNO_QUERY_THROW); + bool bOverlay = false; + CPPUNIT_ASSERT(xPropertySet->getPropertyValue("Overlay") >>= bOverlay); + CPPUNIT_ASSERT(bOverlay); + } + reload("Calc Office Open XML"); + { + uno::Reference<chart2::XChartDocument> xChart2Doc = getChartDocFromSheet(0, mxComponent); + uno::Reference<chart::XChartDocument> xChartDoc(xChart2Doc, uno::UNO_QUERY); + uno::Reference<drawing::XShape> xLegend = xChartDoc->getLegend(); + Reference<beans::XPropertySet> xPropertySet(xLegend, uno::UNO_QUERY_THROW); + bool bOverlay = false; + CPPUNIT_ASSERT(xPropertySet->getPropertyValue("Overlay") >>= bOverlay); + CPPUNIT_ASSERT(bOverlay); + } } CPPUNIT_TEST_SUITE_REGISTRATION(Chart2ExportTest); |