diff options
author | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2018-12-05 03:45:17 +0100 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2018-12-05 15:43:28 +0100 |
commit | c32a4c2fac32b766a05473d037d73cbcd972dadd (patch) | |
tree | 79a30a34b8b91307a49cd32bb1db3f7908277d9d /sc/source/filter/excel/xichart.cxx | |
parent | 7e7b9a90adc5186d48febce5ee0c0afb09aedaee (diff) |
tdf#51671, implement feature to disable legend entry for series
No UI and no ODF or OOXML support yet.
Change-Id: I839c195e9c42f074838ff6592331f7cdd13b6cd2
Reviewed-on: https://gerrit.libreoffice.org/64583
Tested-by: Jenkins
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'sc/source/filter/excel/xichart.cxx')
-rw-r--r-- | sc/source/filter/excel/xichart.cxx | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/sc/source/filter/excel/xichart.cxx b/sc/source/filter/excel/xichart.cxx index 6ff977f9d7a6..b8d32f81a4d7 100644 --- a/sc/source/filter/excel/xichart.cxx +++ b/sc/source/filter/excel/xichart.cxx @@ -1778,7 +1778,8 @@ XclImpChSeries::XclImpChSeries( const XclImpChRoot& rRoot, sal_uInt16 nSeriesIdx XclImpChRoot( rRoot ), mnGroupIdx( EXC_CHSERGROUP_NONE ), mnSeriesIdx( nSeriesIdx ), - mnParentIdx( EXC_CHSERIES_INVALID ) + mnParentIdx( EXC_CHSERIES_INVALID ), + mbLabelDeleted( false ) { } @@ -1817,6 +1818,9 @@ void XclImpChSeries::ReadSubRecord( XclImpStream& rStrm ) case EXC_ID_CHSERERRORBAR: ReadChSerErrorBar( rStrm ); break; + case EXC_ID_CHLEGENDEXCEPTION: + ReadChLegendException( rStrm ); + break; } } @@ -2054,6 +2058,9 @@ Reference< XDataSeries > XclImpChSeries::CreateDataSeries() const if( mxSeriesFmt ) mxSeriesFmt->Convert( aSeriesProp, rTypeInfo ); + if (mbLabelDeleted) + aSeriesProp.SetProperty(EXC_CHPROP_SHOWLEGENDENTRY, false); + // trend lines ConvertTrendLines( xDataSeries ); @@ -2185,6 +2192,13 @@ Reference< XPropertySet > XclImpChSeries::CreateErrorBar( sal_uInt8 nPosBarId, s return XclImpChSerErrorBar::CreateErrorBar(itrPosBar->second.get(), itrNegBar->second.get()); } +void XclImpChSeries::ReadChLegendException(XclImpStream& rStrm) +{ + rStrm.Ignore(2); + sal_uInt16 nFlags = rStrm.ReaduInt16(); + mbLabelDeleted = (nFlags & EXC_CHLEGENDEXCEPTION_DELETED); +} + // Chart type groups ========================================================== XclImpChType::XclImpChType( const XclImpChRoot& rRoot ) : |