Kaydet (Commit) f65a9efc authored tarafından Markus Mohrhard's avatar Markus Mohrhard Kaydeden (comit) Tomaž Vajngerl

fix element order in OOXML export

üst 94182ac7
...@@ -1521,7 +1521,6 @@ void ChartExport::exportSeries( Reference< chart2::XChartType > xChartType, sal_ ...@@ -1521,7 +1521,6 @@ void ChartExport::exportSeries( Reference< chart2::XChartType > xChartType, sal_
case chart::TYPEID_SCATTER: case chart::TYPEID_SCATTER:
{ {
exportMarker( ); exportMarker( );
exportTrendlines( aSeriesSeq[nSeriesIdx] );
exportSmooth( ); exportSmooth( );
break; break;
} }
...@@ -1541,6 +1540,9 @@ void ChartExport::exportSeries( Reference< chart2::XChartType > xChartType, sal_ ...@@ -1541,6 +1540,9 @@ void ChartExport::exportSeries( Reference< chart2::XChartType > xChartType, sal_
if( eChartType != chart::TYPEID_SCATTER && eChartType != chart::TYPEID_BAR ) if( eChartType != chart::TYPEID_SCATTER && eChartType != chart::TYPEID_BAR )
exportDataLabels( uno::Reference< beans::XPropertySet >( aSeriesSeq[nSeriesIdx], uno::UNO_QUERY ), nSeriesLength ); exportDataLabels( uno::Reference< beans::XPropertySet >( aSeriesSeq[nSeriesIdx], uno::UNO_QUERY ), nSeriesLength );
if( eChartType == chart::TYPEID_SCATTER )
exportTrendlines( aSeriesSeq[nSeriesIdx] );
//export error bars here //export error bars here
Reference< XPropertySet > xSeriesPropSet( xSource, uno::UNO_QUERY ); Reference< XPropertySet > xSeriesPropSet( xSource, uno::UNO_QUERY );
Reference< XPropertySet > xErrorBarYProps; Reference< XPropertySet > xErrorBarYProps;
...@@ -2491,6 +2493,8 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries ) ...@@ -2491,6 +2493,8 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries )
Reference< XPropertySet > xProperties( xRegCurve , uno::UNO_QUERY ); Reference< XPropertySet > xProperties( xRegCurve , uno::UNO_QUERY );
exportShapeProps( xProperties );
OUString aService; OUString aService;
Reference< lang::XServiceName > xServiceName( xProperties, UNO_QUERY ); Reference< lang::XServiceName > xServiceName( xProperties, UNO_QUERY );
...@@ -2566,8 +2570,6 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries ) ...@@ -2566,8 +2570,6 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries )
XML_val, OString::number(aExtrapolateBackward).getStr(), XML_val, OString::number(aExtrapolateBackward).getStr(),
FSEND ); FSEND );
exportShapeProps( xProperties );
// Equation properties // Equation properties
Reference< XPropertySet > xEquationProperties( xRegCurve->getEquationProperties() ); Reference< XPropertySet > xEquationProperties( xRegCurve->getEquationProperties() );
...@@ -2575,10 +2577,6 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries ) ...@@ -2575,10 +2577,6 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries )
sal_Bool aShowEquation = false; sal_Bool aShowEquation = false;
xEquationProperties->getPropertyValue( "ShowEquation" ) >>= aShowEquation; xEquationProperties->getPropertyValue( "ShowEquation" ) >>= aShowEquation;
pFS->singleElement( FSNS( XML_c, XML_dispEq ),
XML_val, aShowEquation ? "1" : "0",
FSEND );
// Show R^2 // Show R^2
sal_Bool aShowCorrelationCoefficient = false; sal_Bool aShowCorrelationCoefficient = false;
xEquationProperties->getPropertyValue( "ShowCorrelationCoefficient" ) >>= aShowCorrelationCoefficient; xEquationProperties->getPropertyValue( "ShowCorrelationCoefficient" ) >>= aShowCorrelationCoefficient;
...@@ -2587,6 +2585,10 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries ) ...@@ -2587,6 +2585,10 @@ void ChartExport::exportTrendlines( Reference< chart2::XDataSeries > xSeries )
XML_val, aShowCorrelationCoefficient ? "1" : "0", XML_val, aShowCorrelationCoefficient ? "1" : "0",
FSEND ); FSEND );
pFS->singleElement( FSNS( XML_c, XML_dispEq ),
XML_val, aShowEquation ? "1" : "0",
FSEND );
pFS->endElement( FSNS( XML_c, XML_trendline ) ); pFS->endElement( FSNS( XML_c, XML_trendline ) );
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment