summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@collabora.co.uk>2015-02-18 21:19:08 +0100
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2015-02-18 21:52:52 +0100
commit32fe0c6adcff25a0df536127ca980413e1cabefd (patch)
treeea6db5a4e08504f0cd6fd08fe559a9dd64c9f644 /oox
parenta51300bc9223b28fc5da6059e4fe1d2af62fb323 (diff)
better way to set default for chart area fill style, related tdf#89451
Change-Id: Iee7fea0f55cf54d43a349b6cc0ffa25995069e40
Diffstat (limited to 'oox')
-rw-r--r--oox/source/drawingml/chart/objectformatter.cxx6
-rw-r--r--oox/source/helper/graphichelper.cxx4
-rw-r--r--oox/source/ppt/pptimport.cxx6
3 files changed, 11 insertions, 5 deletions
diff --git a/oox/source/drawingml/chart/objectformatter.cxx b/oox/source/drawingml/chart/objectformatter.cxx
index f5f02fd2cc59..d66726d6c37d 100644
--- a/oox/source/drawingml/chart/objectformatter.cxx
+++ b/oox/source/drawingml/chart/objectformatter.cxx
@@ -34,6 +34,7 @@
#include "oox/drawingml/theme.hxx"
#include "drawingml/chart/chartspacemodel.hxx"
#include "oox/helper/modelobjecthelper.hxx"
+#include <oox/helper/graphichelper.hxx>
namespace oox {
namespace drawingml {
@@ -877,6 +878,11 @@ FillFormatter::FillFormatter( ObjectFormatterData& rData, const AutoFormatEntry*
if( const Theme* pTheme = mrData.mrFilter.getCurrentTheme() )
if( const FillProperties* pFillProps = pTheme->getFillStyle( pAutoFormatEntry->mnThemedIdx ) )
*mxAutoFill = *pFillProps;
+
+ if (eObjType == OBJECTTYPE_CHARTSPACE)
+ {
+ mxAutoFill->moFillType = rData.mrFilter.getGraphicHelper().getDefaultChartAreaFillStyle();
+ }
}
}
diff --git a/oox/source/helper/graphichelper.cxx b/oox/source/helper/graphichelper.cxx
index 2714cf5d25f2..743412595f39 100644
--- a/oox/source/helper/graphichelper.cxx
+++ b/oox/source/helper/graphichelper.cxx
@@ -157,9 +157,9 @@ sal_Int32 GraphicHelper::getPaletteColor( sal_Int32 /*nPaletteIdx*/ ) const
return API_RGB_TRANSPARENT;
}
-drawing::FillStyle GraphicHelper::getDefaultChartAreaFillStyle() const
+sal_Int32 GraphicHelper::getDefaultChartAreaFillStyle() const
{
- return drawing::FillStyle_SOLID;
+ return XML_solidFill;
}
// Device info and device dependent unit conversion ---------------------------
diff --git a/oox/source/ppt/pptimport.cxx b/oox/source/ppt/pptimport.cxx
index 328d16a2f47e..fc29c1ce277b 100644
--- a/oox/source/ppt/pptimport.cxx
+++ b/oox/source/ppt/pptimport.cxx
@@ -193,7 +193,7 @@ class PptGraphicHelper : public GraphicHelper
public:
explicit PptGraphicHelper( const PowerPointImport& rFilter );
virtual sal_Int32 getSchemeColor( sal_Int32 nToken ) const SAL_OVERRIDE;
- virtual drawing::FillStyle getDefaultChartAreaFillStyle() const SAL_OVERRIDE;
+ virtual sal_Int32 getDefaultChartAreaFillStyle() const SAL_OVERRIDE;
private:
const PowerPointImport& mrFilter;
};
@@ -209,9 +209,9 @@ sal_Int32 PptGraphicHelper::getSchemeColor( sal_Int32 nToken ) const
return mrFilter.getSchemeColor( nToken );
}
-drawing::FillStyle PptGraphicHelper::getDefaultChartAreaFillStyle() const
+sal_Int32 PptGraphicHelper::getDefaultChartAreaFillStyle() const
{
- return drawing::FillStyle_NONE;
+ return XML_noFill;
}
} // namespace