summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Mohrhard <markus.mohrhard@collabora.co.uk>2014-04-06 01:38:13 +0200
committerMarkus Mohrhard <markus.mohrhard@googlemail.com>2014-04-06 01:45:31 +0200
commit3f50246f6af1d26353377ff5cb2cc5a381c7d426 (patch)
tree89a0a3d0173864480931489f29b3857515d07d10
parent08906623da9f8c0749f12276832c95d229d9436c (diff)
import data point symbol color
Change-Id: I27ebd67a535f8617a6f535414ee8426fae6614b9
-rw-r--r--include/oox/drawingml/chart/seriesmodel.hxx20
-rw-r--r--include/oox/drawingml/chart/typegroupconverter.hxx3
-rw-r--r--oox/source/drawingml/chart/seriesconverter.cxx5
-rw-r--r--oox/source/drawingml/chart/typegroupconverter.cxx6
4 files changed, 10 insertions, 24 deletions
diff --git a/include/oox/drawingml/chart/seriesmodel.hxx b/include/oox/drawingml/chart/seriesmodel.hxx
index e6e8a01639a5..b9c2c3c3ff17 100644
--- a/include/oox/drawingml/chart/seriesmodel.hxx
+++ b/include/oox/drawingml/chart/seriesmodel.hxx
@@ -27,8 +27,6 @@ namespace oox {
namespace drawingml {
namespace chart {
-
-
struct DataLabelModelBase
{
typedef ModelRef< Shape > ShapeRef;
@@ -51,8 +49,6 @@ struct DataLabelModelBase
~DataLabelModelBase();
};
-
-
struct DataLabelModel : public DataLabelModelBase
{
typedef ModelRef< LayoutModel > LayoutRef;
@@ -66,8 +62,6 @@ struct DataLabelModel : public DataLabelModelBase
~DataLabelModel();
};
-
-
struct DataLabelsModel : public DataLabelModelBase
{
typedef ModelVector< DataLabelModel > DataLabelVector;
@@ -81,8 +75,6 @@ struct DataLabelsModel : public DataLabelModelBase
~DataLabelsModel();
};
-
-
struct PictureOptionsModel
{
double mfStackUnit; /// Bitmap stacking unit.
@@ -95,8 +87,6 @@ struct PictureOptionsModel
~PictureOptionsModel();
};
-
-
struct ErrorBarModel
{
enum SourceType
@@ -120,8 +110,6 @@ struct ErrorBarModel
~ErrorBarModel();
};
-
-
struct TrendlineLabelModel
{
typedef ModelRef< Shape > ShapeRef;
@@ -139,8 +127,6 @@ struct TrendlineLabelModel
~TrendlineLabelModel();
};
-
-
struct TrendlineModel
{
typedef ModelRef< Shape > ShapeRef;
@@ -162,8 +148,6 @@ struct TrendlineModel
~TrendlineModel();
};
-
-
struct DataPointModel
{
typedef ModelRef< Shape > ShapeRef;
@@ -183,8 +167,6 @@ struct DataPointModel
~DataPointModel();
};
-
-
struct SeriesModel
{
enum SourceType
@@ -226,8 +208,6 @@ struct SeriesModel
~SeriesModel();
};
-
-
} // namespace chart
} // namespace drawingml
} // namespace oox
diff --git a/include/oox/drawingml/chart/typegroupconverter.hxx b/include/oox/drawingml/chart/typegroupconverter.hxx
index e61f81fdcf0a..16c8271677a0 100644
--- a/include/oox/drawingml/chart/typegroupconverter.hxx
+++ b/include/oox/drawingml/chart/typegroupconverter.hxx
@@ -153,7 +153,8 @@ public:
sal_Int32 nAxesSetIdx, bool bSupportsVaryColorsByPoint );
/** Sets the passed OOXML marker style at the passed property set. */
- void convertMarker( PropertySet& rPropSet, sal_Int32 nOoxSymbol, sal_Int32 nOoxSize ) const;
+ void convertMarker( PropertySet& rPropSet, sal_Int32 nOoxSymbol, sal_Int32 nOoxSize,
+ ModelRef< Shape > xShapeProps ) const;
/** Sets the passed OOXML line smoothing at the passed property set. */
void convertLineSmooth( PropertySet& rPropSet, bool bOoxSmooth ) const;
/** Sets the passed OOXML bar 3D geometry at the passed property set. */
diff --git a/oox/source/drawingml/chart/seriesconverter.cxx b/oox/source/drawingml/chart/seriesconverter.cxx
index b33aabe9e86a..0b2b20aa47d6 100644
--- a/oox/source/drawingml/chart/seriesconverter.cxx
+++ b/oox/source/drawingml/chart/seriesconverter.cxx
@@ -481,7 +481,8 @@ void DataPointConverter::convertFromModel( const Reference< XDataSeries >& rxDat
// data point marker
if( mrModel.monMarkerSymbol.differsFrom( rSeries.mnMarkerSymbol ) || mrModel.monMarkerSize.differsFrom( rSeries.mnMarkerSize ) )
- rTypeGroup.convertMarker( aPropSet, mrModel.monMarkerSymbol.get( rSeries.mnMarkerSymbol ), mrModel.monMarkerSize.get( rSeries.mnMarkerSize ) );
+ rTypeGroup.convertMarker( aPropSet, mrModel.monMarkerSymbol.get( rSeries.mnMarkerSymbol ),
+ mrModel.monMarkerSize.get( rSeries.mnMarkerSize ), mrModel.mxMarkerProp );
// data point pie explosion
if( mrModel.monExplosion.differsFrom( rSeries.mnExplosion ) )
@@ -578,7 +579,7 @@ Reference< XDataSeries > SeriesConverter::createDataSeries( const TypeGroupConve
}
// data point markers
- rTypeGroup.convertMarker( aSeriesProp, mrModel.mnMarkerSymbol, mrModel.mnMarkerSize );
+ rTypeGroup.convertMarker( aSeriesProp, mrModel.mnMarkerSymbol, mrModel.mnMarkerSize, mrModel.mxMarkerProp );
#if OOX_CHART_SMOOTHED_PER_SERIES
// #i66858# smoothed series lines
rTypeGroup.convertLineSmooth( aSeriesProp, mrModel.mbSmooth );
diff --git a/oox/source/drawingml/chart/typegroupconverter.cxx b/oox/source/drawingml/chart/typegroupconverter.cxx
index 78046507d24f..a57c2188c648 100644
--- a/oox/source/drawingml/chart/typegroupconverter.cxx
+++ b/oox/source/drawingml/chart/typegroupconverter.cxx
@@ -452,7 +452,8 @@ void TypeGroupConverter::convertFromModel( const Reference< XDiagram >& rxDiagra
}
}
-void TypeGroupConverter::convertMarker( PropertySet& rPropSet, sal_Int32 nOoxSymbol, sal_Int32 nOoxSize ) const
+void TypeGroupConverter::convertMarker( PropertySet& rPropSet, sal_Int32 nOoxSymbol, sal_Int32 nOoxSize,
+ ModelRef< Shape > xShapeProps ) const
{
if( !isSeriesFrameFormat() )
{
@@ -480,6 +481,9 @@ void TypeGroupConverter::convertMarker( PropertySet& rPropSet, sal_Int32 nOoxSym
sal_Int32 nSize = static_cast< sal_Int32 >( nOoxSize * (2540.0 / 72.0) + 0.5 );
aSymbol.Size.Width = aSymbol.Size.Height = nSize;
+ Color aFillColor = xShapeProps->getFillProperties().maFillColor;
+ aSymbol.FillColor = aFillColor.getColor(getFilter().getGraphicHelper());
+
// set the property
rPropSet.setProperty( PROP_Symbol, aSymbol );
}