1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include "oox/drawingml/chart/seriescontext.hxx"
22 #include "oox/drawingml/shapepropertiescontext.hxx"
23 #include "oox/drawingml/textbodycontext.hxx"
24 #include "oox/drawingml/chart/datasourcecontext.hxx"
25 #include "oox/drawingml/chart/seriesmodel.hxx"
26 #include "oox/drawingml/chart/titlecontext.hxx"
32 // ============================================================================
34 using ::oox::core::ContextHandler2
;
35 using ::oox::core::ContextHandler2Helper
;
36 using ::oox::core::ContextHandlerRef
;
38 // ============================================================================
42 ContextHandlerRef
lclDataLabelSharedCreateContext( ContextHandler2
& rContext
,
43 sal_Int32 nElement
, const AttributeList
& rAttribs
, DataLabelModelBase
& orModel
)
45 if( rContext
.isRootElement() ) switch( nElement
)
47 case C_TOKEN( delete ):
48 // default is 'false', not 'true' as specified
49 orModel
.mbDeleted
= rAttribs
.getBool( XML_val
, false );
51 case C_TOKEN( dLblPos
):
52 orModel
.monLabelPos
= rAttribs
.getToken( XML_val
, XML_TOKEN_INVALID
);
54 case C_TOKEN( numFmt
):
55 orModel
.maNumberFormat
.setAttributes( rAttribs
);
57 case C_TOKEN( showBubbleSize
):
58 orModel
.mobShowBubbleSize
= rAttribs
.getBool( XML_val
);
60 case C_TOKEN( showCatName
):
61 orModel
.mobShowCatName
= rAttribs
.getBool( XML_val
);
63 case C_TOKEN( showLegendKey
):
64 orModel
.mobShowLegendKey
= rAttribs
.getBool( XML_val
);
66 case C_TOKEN( showPercent
):
67 orModel
.mobShowPercent
= rAttribs
.getBool( XML_val
);
69 case C_TOKEN( showSerName
):
70 orModel
.mobShowSerName
= rAttribs
.getBool( XML_val
);
72 case C_TOKEN( showVal
):
73 orModel
.mobShowVal
= rAttribs
.getBool( XML_val
);
75 case C_TOKEN( separator
):
76 // collect separator text in onCharacters()
79 return new ShapePropertiesContext( rContext
, orModel
.mxShapeProp
.create() );
81 return new TextBodyContext( rContext
, orModel
.mxTextProp
.create() );
86 void lclDataLabelSharedCharacters( ContextHandler2
& rContext
, const OUString
& rChars
, DataLabelModelBase
& orModel
)
88 if( rContext
.isCurrentElement( C_TOKEN( separator
) ) )
89 orModel
.moaSeparator
= rChars
;
94 // ============================================================================
96 DataLabelContext::DataLabelContext( ContextHandler2Helper
& rParent
, DataLabelModel
& rModel
) :
97 ContextBase
< DataLabelModel
>( rParent
, rModel
)
101 DataLabelContext::~DataLabelContext()
105 ContextHandlerRef
DataLabelContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
107 if( isRootElement() ) switch( nElement
)
110 mrModel
.mnIndex
= rAttribs
.getInteger( XML_val
, -1 );
112 case C_TOKEN( layout
):
113 return new LayoutContext( *this, mrModel
.mxLayout
.create() );
115 return new TextContext( *this, mrModel
.mxText
.create() );
117 return lclDataLabelSharedCreateContext( *this, nElement
, rAttribs
, mrModel
);
120 void DataLabelContext::onCharacters( const OUString
& rChars
)
122 lclDataLabelSharedCharacters( *this, rChars
, mrModel
);
125 // ============================================================================
127 DataLabelsContext::DataLabelsContext( ContextHandler2Helper
& rParent
, DataLabelsModel
& rModel
) :
128 ContextBase
< DataLabelsModel
>( rParent
, rModel
)
132 DataLabelsContext::~DataLabelsContext()
136 ContextHandlerRef
DataLabelsContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
138 if( isRootElement() ) switch( nElement
)
140 case C_TOKEN( dLbl
):
141 return new DataLabelContext( *this, mrModel
.maPointLabels
.create() );
142 case C_TOKEN( leaderLines
):
143 return new ShapePrWrapperContext( *this, mrModel
.mxLeaderLines
.create() );
144 case C_TOKEN( showLeaderLines
):
145 // default is 'false', not 'true' as specified
146 mrModel
.mbShowLeaderLines
= rAttribs
.getBool( XML_val
, false );
149 return lclDataLabelSharedCreateContext( *this, nElement
, rAttribs
, mrModel
);
152 void DataLabelsContext::onCharacters( const OUString
& rChars
)
154 lclDataLabelSharedCharacters( *this, rChars
, mrModel
);
157 // ============================================================================
159 PictureOptionsContext::PictureOptionsContext( ContextHandler2Helper
& rParent
, PictureOptionsModel
& rModel
) :
160 ContextBase
< PictureOptionsModel
>( rParent
, rModel
)
164 PictureOptionsContext::~PictureOptionsContext()
168 ContextHandlerRef
PictureOptionsContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
170 if( isRootElement() ) switch( nElement
)
172 case C_TOKEN( applyToEnd
):
173 // default is 'false', not 'true' as specified
174 mrModel
.mbApplyToEnd
= rAttribs
.getBool( XML_val
, false );
176 case C_TOKEN( applyToFront
):
177 // default is 'false', not 'true' as specified
178 mrModel
.mbApplyToFront
= rAttribs
.getBool( XML_val
, false );
180 case C_TOKEN( applyToSides
):
181 // default is 'false', not 'true' as specified
182 mrModel
.mbApplyToSides
= rAttribs
.getBool( XML_val
, false );
184 case C_TOKEN( pictureFormat
):
185 mrModel
.mnPictureFormat
= rAttribs
.getToken( XML_val
, XML_stretch
);
187 case C_TOKEN( pictureStackUnit
):
188 mrModel
.mfStackUnit
= rAttribs
.getDouble( XML_val
, 1.0 );
194 // ============================================================================
196 ErrorBarContext::ErrorBarContext( ContextHandler2Helper
& rParent
, ErrorBarModel
& rModel
) :
197 ContextBase
< ErrorBarModel
>( rParent
, rModel
)
201 ErrorBarContext::~ErrorBarContext()
205 ContextHandlerRef
ErrorBarContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
207 if( isRootElement() ) switch( nElement
)
209 case C_TOKEN( errBarType
):
210 mrModel
.mnTypeId
= rAttribs
.getToken( XML_val
, XML_both
);
212 case C_TOKEN( errDir
):
213 mrModel
.mnDirection
= rAttribs
.getToken( XML_val
, XML_TOKEN_INVALID
);
215 case C_TOKEN( errValType
):
216 mrModel
.mnValueType
= rAttribs
.getToken( XML_val
, XML_fixedVal
);
218 case C_TOKEN( minus
):
219 return new DataSourceContext( *this, mrModel
.maSources
.create( ErrorBarModel::MINUS
) );
220 case C_TOKEN( noEndCap
):
221 // default is 'false', not 'true' as specified
222 mrModel
.mbNoEndCap
= rAttribs
.getBool( XML_val
, false );
224 case C_TOKEN( plus
):
225 return new DataSourceContext( *this, mrModel
.maSources
.create( ErrorBarModel::PLUS
) );
226 case C_TOKEN( spPr
):
227 return new ShapePropertiesContext( *this, mrModel
.mxShapeProp
.create() );
229 mrModel
.mfValue
= rAttribs
.getDouble( XML_val
, 0.0 );
235 // ============================================================================
237 TrendlineLabelContext::TrendlineLabelContext( ContextHandler2Helper
& rParent
, TrendlineLabelModel
& rModel
) :
238 ContextBase
< TrendlineLabelModel
>( rParent
, rModel
)
242 TrendlineLabelContext::~TrendlineLabelContext()
246 ContextHandlerRef
TrendlineLabelContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
248 if( isRootElement() ) switch( nElement
)
250 case C_TOKEN( layout
):
251 return new LayoutContext( *this, mrModel
.mxLayout
.create() );
252 case C_TOKEN( numFmt
):
253 mrModel
.maNumberFormat
.setAttributes( rAttribs
);
255 case C_TOKEN( spPr
):
256 return new ShapePropertiesContext( *this, mrModel
.mxShapeProp
.create() );
258 return new TextContext( *this, mrModel
.mxText
.create() );
259 case C_TOKEN( txPr
):
260 return new TextBodyContext( *this, mrModel
.mxTextProp
.create() );
265 // ============================================================================
267 TrendlineContext::TrendlineContext( ContextHandler2Helper
& rParent
, TrendlineModel
& rModel
) :
268 ContextBase
< TrendlineModel
>( rParent
, rModel
)
272 TrendlineContext::~TrendlineContext()
276 ContextHandlerRef
TrendlineContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
278 if( isRootElement() ) switch( nElement
)
280 case C_TOKEN( backward
):
281 mrModel
.mfBackward
= rAttribs
.getDouble( XML_val
, 0.0 );
283 case C_TOKEN( dispEq
):
284 // default is 'false', not 'true' as specified
285 mrModel
.mbDispEquation
= rAttribs
.getBool( XML_val
, false );
287 case C_TOKEN( dispRSqr
):
288 // default is 'false', not 'true' as specified
289 mrModel
.mbDispRSquared
= rAttribs
.getBool( XML_val
, false );
291 case C_TOKEN( forward
):
292 mrModel
.mfForward
= rAttribs
.getDouble( XML_val
, 0.0 );
294 case C_TOKEN( intercept
):
295 mrModel
.mfIntercept
= rAttribs
.getDouble( XML_val
, 0.0 );
297 case C_TOKEN( name
):
298 return this; // collect name in onCharacters()
299 case C_TOKEN( order
):
300 mrModel
.mnOrder
= rAttribs
.getInteger( XML_val
, 2 );
302 case C_TOKEN( period
):
303 mrModel
.mnPeriod
= rAttribs
.getInteger( XML_val
, 2 );
305 case C_TOKEN( spPr
):
306 return new ShapePropertiesContext( *this, mrModel
.mxShapeProp
.create() );
307 case C_TOKEN( trendlineLbl
):
308 return new TrendlineLabelContext( *this, mrModel
.mxLabel
.create() );
309 case C_TOKEN( trendlineType
):
310 mrModel
.mnTypeId
= rAttribs
.getToken( XML_val
, XML_linear
);
316 void TrendlineContext::onCharacters( const OUString
& rChars
)
318 if( isCurrentElement( C_TOKEN( name
) ) )
319 mrModel
.maName
= rChars
;
322 // ============================================================================
324 DataPointContext::DataPointContext( ContextHandler2Helper
& rParent
, DataPointModel
& rModel
) :
325 ContextBase
< DataPointModel
>( rParent
, rModel
)
329 DataPointContext::~DataPointContext()
333 ContextHandlerRef
DataPointContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
335 switch( getCurrentElement() )
340 case C_TOKEN( bubble3D
):
341 mrModel
.mobBubble3d
= rAttribs
.getBool( XML_val
);
343 case C_TOKEN( explosion
):
344 // if the 'val' attribute is missing, series explosion remains unchanged
345 mrModel
.monExplosion
= rAttribs
.getInteger( XML_val
);
348 mrModel
.mnIndex
= rAttribs
.getInteger( XML_val
, -1 );
350 case C_TOKEN( invertIfNegative
):
351 // default is 'false', not 'true' as specified (value not derived from series!)
352 mrModel
.mbInvertNeg
= rAttribs
.getBool( XML_val
, false );
354 case C_TOKEN( marker
):
356 case C_TOKEN( pictureOptions
):
357 return new PictureOptionsContext( *this, mrModel
.mxPicOptions
.create() );
358 case C_TOKEN( spPr
):
359 return new ShapePropertiesContext( *this, mrModel
.mxShapeProp
.create() );
363 case C_TOKEN( marker
):
366 case C_TOKEN( size
):
367 mrModel
.monMarkerSize
= rAttribs
.getInteger( XML_val
, 5 );
369 case C_TOKEN( spPr
):
370 return new ShapePropertiesContext( *this, mrModel
.mxMarkerProp
.create() );
371 case C_TOKEN( symbol
):
372 mrModel
.monMarkerSymbol
= rAttribs
.getToken( XML_val
, XML_none
);
380 // ============================================================================
382 SeriesContextBase::SeriesContextBase( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
383 ContextBase
< SeriesModel
>( rParent
, rModel
)
387 SeriesContextBase::~SeriesContextBase()
391 ContextHandlerRef
SeriesContextBase::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
393 switch( getCurrentElement() )
399 mrModel
.mnIndex
= rAttribs
.getInteger( XML_val
, -1 );
401 case C_TOKEN( order
):
402 mrModel
.mnOrder
= rAttribs
.getInteger( XML_val
, -1 );
404 case C_TOKEN( spPr
):
405 return new ShapePropertiesContext( *this, mrModel
.mxShapeProp
.create() );
407 return new TextContext( *this, mrModel
.mxText
.create() );
411 case C_TOKEN( marker
):
414 case C_TOKEN( size
):
415 mrModel
.mnMarkerSize
= rAttribs
.getInteger( XML_val
, 5 );
417 case C_TOKEN( spPr
):
418 return new ShapePropertiesContext( *this, mrModel
.mxMarkerProp
.create() );
419 case C_TOKEN( symbol
):
420 mrModel
.mnMarkerSymbol
= rAttribs
.getToken( XML_val
, XML_none
);
428 // ============================================================================
430 AreaSeriesContext::AreaSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
431 SeriesContextBase( rParent
, rModel
)
435 AreaSeriesContext::~AreaSeriesContext()
439 ContextHandlerRef
AreaSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
441 switch( getCurrentElement() )
447 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
448 case C_TOKEN( errBars
):
449 return new ErrorBarContext( *this, mrModel
.maErrorBars
.create() );
450 case C_TOKEN( dLbls
):
451 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
453 return new DataPointContext( *this, mrModel
.maPoints
.create() );
454 case C_TOKEN( trendline
):
455 return new TrendlineContext( *this, mrModel
.maTrendlines
.create() );
457 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
461 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
464 // ============================================================================
466 BarSeriesContext::BarSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
467 SeriesContextBase( rParent
, rModel
)
471 BarSeriesContext::~BarSeriesContext()
475 ContextHandlerRef
BarSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
477 switch( getCurrentElement() )
483 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
484 case C_TOKEN( dLbls
):
485 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
487 return new DataPointContext( *this, mrModel
.maPoints
.create() );
488 case C_TOKEN( errBars
):
489 return new ErrorBarContext( *this, mrModel
.maErrorBars
.create() );
490 case C_TOKEN( invertIfNegative
):
491 // default is 'false', not 'true' as specified
492 mrModel
.mbInvertNeg
= rAttribs
.getBool( XML_val
, false );
494 case C_TOKEN( pictureOptions
):
495 return new PictureOptionsContext( *this, mrModel
.mxPicOptions
.create() );
496 case C_TOKEN( shape
):
497 // missing attribute does not change shape type to 'box' as specified
498 mrModel
.monShape
= rAttribs
.getToken( XML_val
);
500 case C_TOKEN( trendline
):
501 return new TrendlineContext( *this, mrModel
.maTrendlines
.create() );
503 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
507 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
510 // ============================================================================
512 BubbleSeriesContext::BubbleSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
513 SeriesContextBase( rParent
, rModel
)
517 BubbleSeriesContext::~BubbleSeriesContext()
521 ContextHandlerRef
BubbleSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
523 switch( getCurrentElement() )
528 case C_TOKEN( bubble3D
):
529 // default is 'false', not 'true' as specified
530 mrModel
.mbBubble3d
= rAttribs
.getBool( XML_val
, false );
532 case C_TOKEN( bubbleSize
):
533 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::POINTS
) );
534 case C_TOKEN( dLbls
):
535 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
537 return new DataPointContext( *this, mrModel
.maPoints
.create() );
538 case C_TOKEN( errBars
):
539 return new ErrorBarContext( *this, mrModel
.maErrorBars
.create() );
540 case C_TOKEN( invertIfNegative
):
541 // default is 'false', not 'true' as specified
542 mrModel
.mbInvertNeg
= rAttribs
.getBool( XML_val
, false );
544 case C_TOKEN( trendline
):
545 return new TrendlineContext( *this, mrModel
.maTrendlines
.create() );
546 case C_TOKEN( xVal
):
547 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
548 case C_TOKEN( yVal
):
549 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
553 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
556 // ============================================================================
558 LineSeriesContext::LineSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
559 SeriesContextBase( rParent
, rModel
)
563 LineSeriesContext::~LineSeriesContext()
567 ContextHandlerRef
LineSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
569 switch( getCurrentElement() )
575 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
576 case C_TOKEN( dLbls
):
577 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
579 return new DataPointContext( *this, mrModel
.maPoints
.create() );
580 case C_TOKEN( errBars
):
581 return new ErrorBarContext( *this, mrModel
.maErrorBars
.create() );
582 case C_TOKEN( marker
):
584 case C_TOKEN( smooth
):
585 // default is 'false', not 'true' as specified
586 mrModel
.mbSmooth
= rAttribs
.getBool( XML_val
, false );
588 case C_TOKEN( trendline
):
589 return new TrendlineContext( *this, mrModel
.maTrendlines
.create() );
591 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
595 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
598 // ============================================================================
600 PieSeriesContext::PieSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
601 SeriesContextBase( rParent
, rModel
)
605 PieSeriesContext::~PieSeriesContext()
609 ContextHandlerRef
PieSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
611 switch( getCurrentElement() )
617 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
618 case C_TOKEN( dLbls
):
619 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
621 return new DataPointContext( *this, mrModel
.maPoints
.create() );
622 case C_TOKEN( explosion
):
623 mrModel
.mnExplosion
= rAttribs
.getInteger( XML_val
, 0 );
626 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
630 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
633 // ============================================================================
635 RadarSeriesContext::RadarSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
636 SeriesContextBase( rParent
, rModel
)
640 RadarSeriesContext::~RadarSeriesContext()
644 ContextHandlerRef
RadarSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
646 switch( getCurrentElement() )
652 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
653 case C_TOKEN( dLbls
):
654 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
656 return new DataPointContext( *this, mrModel
.maPoints
.create() );
657 case C_TOKEN( marker
):
659 case C_TOKEN( smooth
):
660 // default is 'false', not 'true' as specified
661 mrModel
.mbSmooth
= rAttribs
.getBool( XML_val
, false );
664 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
668 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
671 // ============================================================================
673 ScatterSeriesContext::ScatterSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
674 SeriesContextBase( rParent
, rModel
)
678 ScatterSeriesContext::~ScatterSeriesContext()
682 ContextHandlerRef
ScatterSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
684 switch( getCurrentElement() )
689 case C_TOKEN( dLbls
):
690 return new DataLabelsContext( *this, mrModel
.mxLabels
.create() );
692 return new DataPointContext( *this, mrModel
.maPoints
.create() );
693 case C_TOKEN( errBars
):
694 return new ErrorBarContext( *this, mrModel
.maErrorBars
.create() );
695 case C_TOKEN( marker
):
697 case C_TOKEN( smooth
):
698 // default is 'false', not 'true' as specified
699 mrModel
.mbSmooth
= rAttribs
.getBool( XML_val
, false );
701 case C_TOKEN( trendline
):
702 return new TrendlineContext( *this, mrModel
.maTrendlines
.create() );
703 case C_TOKEN( xVal
):
704 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
705 case C_TOKEN( yVal
):
706 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
710 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
713 // ============================================================================
715 SurfaceSeriesContext::SurfaceSeriesContext( ContextHandler2Helper
& rParent
, SeriesModel
& rModel
) :
716 SeriesContextBase( rParent
, rModel
)
720 SurfaceSeriesContext::~SurfaceSeriesContext()
724 ContextHandlerRef
SurfaceSeriesContext::onCreateContext( sal_Int32 nElement
, const AttributeList
& rAttribs
)
726 switch( getCurrentElement() )
732 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::CATEGORIES
) );
734 return new DataSourceContext( *this, mrModel
.maSources
.create( SeriesModel::VALUES
) );
738 return SeriesContextBase::onCreateContext( nElement
, rAttribs
);
741 // ============================================================================
744 } // namespace drawingml
747 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */