summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorBalazs Varga <balazs.varga991@gmail.com>2020-01-15 16:31:35 +0100
committerLászló Németh <nemeth@numbertext.org>2020-01-30 10:43:02 +0100
commit4223ff2be69f03e571464b0b09ad0d278918631b (patch)
tree7205f05cf9773f53f0ad4433703055794eb3f997 /sd
parente265037d6c655675416116b19882c3c29bb7bf40 (diff)
tdf#48436 Chart: add CustomLabelPosition UNO API property
and CUSTOM DataLabelPlacement to support custom data label positions, and its initial implementation: only UI support with OOXML import (tdf#130030), yet. Change-Id: I01d986071d78ae3e2a5f43d5711e9f60b8410c21 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86859 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sd')
-rw-r--r--sd/qa/unit/import-tests.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index 61c74879a6db..9eff839c2865 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -2614,24 +2614,25 @@ void SdImportTest::testTdf114821()
uno::Sequence< uno::Reference< chart2::XDataSeries > > aSeriesSeq( xDSCnt->getDataSeries() );
CPPUNIT_ASSERT_EQUAL_MESSAGE( "Invalid Series count", static_cast<sal_Int32>( 1 ), aSeriesSeq.getLength() );
+ // These Labels have custom position, so the exported LabelPlacement (reference point) by MSO is OUTSIDE/OUTEND
// Check the first label
const css::uno::Reference< css::beans::XPropertySet >& rPropSet0( aSeriesSeq[0]->getDataPointByIndex( 0 ) );
CPPUNIT_ASSERT( rPropSet0.is() );
sal_Int32 aPlacement;
rPropSet0->getPropertyValue( "LabelPlacement" ) >>= aPlacement;
- CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::TOP, aPlacement );
+ CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::OUTSIDE, aPlacement );
// Check the second label
const css::uno::Reference< css::beans::XPropertySet >& rPropSet1( aSeriesSeq[0]->getDataPointByIndex( 1 ) );
CPPUNIT_ASSERT( rPropSet1.is() );
rPropSet1->getPropertyValue( "LabelPlacement" ) >>= aPlacement;
- CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::CENTER, aPlacement );
+ CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::OUTSIDE, aPlacement );
// Check the third label
const css::uno::Reference< css::beans::XPropertySet >& rPropSet2( aSeriesSeq[0]->getDataPointByIndex( 2 ) );
CPPUNIT_ASSERT( rPropSet2.is() );
rPropSet2->getPropertyValue( "LabelPlacement") >>= aPlacement;
- CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::TOP, aPlacement );
+ CPPUNIT_ASSERT_EQUAL( css::chart::DataLabelPlacement::OUTSIDE, aPlacement );
xDocShRef->DoClose();
}