diff options
author | Balazs Varga <balazs.varga991@gmail.com> | 2018-10-08 19:31:38 +0200 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2018-10-09 09:27:56 +0200 |
commit | a1d4c2419097169cb2d51f7c11d90073766f6d9d (patch) | |
tree | db09dff1fa5c17f137245e53efbb345ba7da13ad /oox | |
parent | 5da57ff00b23fd9969a2bfcf4e6e1e8245dfc1a3 (diff) |
tdf#120341 OOXML export: fix export of Pie Chart Wall Borderline
Export LineStyle_NONE instead of default linestyle of PlotArea border,
because LibreOffice make invisible the Wall shape properties in case of
PIE/NET/FILLED_NET charts. Or other solution in the future is set the
default LineStyle of these charts to LineStyle_NONE.
Change-Id: I59e6f18058713f4a0d4c77da8760a319f9c25152
Reviewed-on: https://gerrit.libreoffice.org/61547
Tested-by: Jenkins
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/export/chartexport.cxx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/oox/source/export/chartexport.cxx b/oox/source/export/chartexport.cxx index 63958cdb3f7a..ded91c2b47d1 100644 --- a/oox/source/export/chartexport.cxx +++ b/oox/source/export/chartexport.cxx @@ -75,6 +75,7 @@ #include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/drawing/XShape.hpp> #include <com/sun/star/drawing/FillStyle.hpp> +#include <com/sun/star/drawing/LineStyle.hpp> #include <com/sun/star/drawing/BitmapMode.hpp> #include <com/sun/star/awt/XBitmap.hpp> #include <com/sun/star/lang/XMultiServiceFactory.hpp> @@ -1178,6 +1179,16 @@ void ChartExport::exportPlotArea( const Reference< css::chart::XChartDocument >& Reference< beans::XPropertySet > xWallPropSet( xWallFloorSupplier->getWall(), uno::UNO_QUERY ); if( xWallPropSet.is() ) { + uno::Any aAny = xWallPropSet->getPropertyValue("LineStyle"); + sal_Int32 eChartType = getChartType( ); + // Export LineStyle_NONE instead of default linestyle of PlotArea border, because LibreOffice + // make invisible the Wall shape properties, in case of these charts. Or in the future set + // the default LineStyle of these charts to LineStyle_NONE. + bool noSupportWallProp = ( (eChartType == chart::TYPEID_PIE) || (eChartType == chart::TYPEID_RADARLINE) || (eChartType == chart::TYPEID_RADARAREA) ); + if ( noSupportWallProp && (aAny != drawing::LineStyle_NONE) ) + { + xWallPropSet->setPropertyValue( "LineStyle", uno::Any(drawing::LineStyle_NONE) ); + } exportShapeProps( xWallPropSet ); } } |