From a05ad6dd36f73647cdf0839d2c18dbc1d399c792 Mon Sep 17 00:00:00 2001 From: Rohit Deshmukh Date: Thu, 6 Feb 2014 17:34:20 +0530 Subject: fdo#74137: Fix for courruption of Pie chart after roundtrip. Problem: - Pie chart with data labels files gets corrupt because of label position is bestFit in original file. - But after round trip, data labels position gets changes to top, left and right. For some data labels postion value is missing. Implementaion: - In LO, while converting data label from model, the position gets changed. So we are ignoring this hack for Pie chart. Conflicts: chart2/qa/extras/chart2export.cxx Change-Id: Ic51845cd6f39bc905439eea8971e878607d25dac --- oox/source/drawingml/chart/seriesconverter.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'oox/source/drawingml') diff --git a/oox/source/drawingml/chart/seriesconverter.cxx b/oox/source/drawingml/chart/seriesconverter.cxx index 5c85d99f46e7..668847ca1e59 100644 --- a/oox/source/drawingml/chart/seriesconverter.cxx +++ b/oox/source/drawingml/chart/seriesconverter.cxx @@ -185,8 +185,9 @@ void DataLabelConverter::convertFromModel( const Reference< XDataSeries >& rxDat { PropertySet aPropSet( rxDataSeries->getDataPointByIndex( mrModel.mnIndex ) ); lclConvertLabelFormatting( aPropSet, getFormatter(), mrModel, rTypeGroup, false ); - - if( mrModel.mxLayout && !mrModel.mxLayout->mbAutoLayout ) + const TypeGroupInfo& rTypeInfo = rTypeGroup.getTypeInfo(); + bool bIsPie = rTypeInfo.meTypeCategory == TYPECATEGORY_PIE; + if( mrModel.mxLayout && !mrModel.mxLayout->mbAutoLayout && !bIsPie ) { // bnc#694340 - nasty hack - chart2 cannot individually // place data labels, let's try to find a useful -- cgit