diff options
author | Ingrid Halama <iha@openoffice.org> | 2004-01-06 18:42:30 +0000 |
---|---|---|
committer | Ingrid Halama <iha@openoffice.org> | 2004-01-06 18:42:30 +0000 |
commit | eeec3a207b7b0a6e36831b9455563a5858a74c45 (patch) | |
tree | da45ea907670ac821ce28571af01a0c148777ff2 /chart2 | |
parent | 40f0e9899459c3eed07f4c2f7a6c58b5ba4867f3 (diff) |
enable 3D data labels
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/view/charttypes/VSeriesPlotter.cxx | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/chart2/source/view/charttypes/VSeriesPlotter.cxx b/chart2/source/view/charttypes/VSeriesPlotter.cxx index 6cc21bd130ad..b728bfb3b1ef 100644 --- a/chart2/source/view/charttypes/VSeriesPlotter.cxx +++ b/chart2/source/view/charttypes/VSeriesPlotter.cxx @@ -271,19 +271,20 @@ uno::Reference< drawing::XShapes > VSeriesPlotter::getSeriesGroupShapeBackChild( } uno::Reference< drawing::XShapes > VSeriesPlotter::getLabelsGroupShape( VDataSeries& rDataSeries - , const uno::Reference< drawing::XShapes >& xTarget ) + , const uno::Reference< drawing::XShapes >& xTextTarget ) { + //xTextTarget needs to be a 2D shape container always! + if(rDataSeries.m_xLabelsShape.is()) return uno::Reference<drawing::XShapes>( rDataSeries.m_xLabelsShape, uno::UNO_QUERY ); - //create a group shape for this series and add to logic target: + //create a 2D group shape for texts of this series and add to text target: uno::Reference< drawing::XShapes > xShapes( - this->createGroupShape( xTarget,rDataSeries.getLabelsCID() )); + m_pShapeFactory->createGroup2D( xTextTarget, rDataSeries.getLabelsCID() )); uno::Reference<drawing::XShape> xShape = uno::Reference<drawing::XShape>( xShapes, uno::UNO_QUERY ); rDataSeries.m_xLabelsShape.set(xShape); return xShapes; - } uno::Reference< drawing::XShapes > VSeriesPlotter::getErrorBarsGroupShape( VDataSeries& rDataSeries @@ -310,15 +311,12 @@ void VSeriesPlotter::createDataLabel( const uno::Reference< drawing::XShapes >& , const awt::Point& rScreenPosition2D , LabelAlignment eAlignment ) { - if(m_nDimension!=2) - return; uno::Reference< drawing::XShapes > xTarget_( this->getLabelsGroupShape(rDataSeries, xTarget) ); //check wether the label needs to be created and how: - DataPointLabel* pLabel = rDataSeries.getDataPointLabel( nPointIndex ); + DataPointLabel* pLabel = rDataSeries.getDataPointLabelIfLabel( nPointIndex ); - if( !pLabel || (!pLabel->ShowNumber && !pLabel->ShowNumberInPercent - && !pLabel->ShowCategoryName && !pLabel->ShowLegendSymbol ) ) + if( !pLabel ) return; //------------------------------------------------ |