summaryrefslogtreecommitdiffstats
path: root/chart2/source/model/template/ChartTypeTemplate.cxx
diff options
context:
space:
mode:
authorBalazs Varga <balazs.varga991@gmail.com>2019-11-13 16:14:31 +0100
committerLászló Németh <nemeth@numbertext.org>2019-11-18 15:03:29 +0100
commit071007d83d9d29fa7879b71b0e7b396da70963a5 (patch)
treea2270dedea80f200cad5678c29afd387dd8f429b /chart2/source/model/template/ChartTypeTemplate.cxx
parentcid#1399260 Uncaught exception (diff)
downloadcore-071007d83d9d29fa7879b71b0e7b396da70963a5.tar.gz
core-071007d83d9d29fa7879b71b0e7b396da70963a5.zip
tdf#127777 fix "CrossBetween" for not imported combined chart
Set the ShiftedCategoryPosition for true in case of combined chart. See also commit 111c260ab2883b7906f1a66e222dbf4dc3c58c4f 'tdf#127777 OOXML chart export: fix "CrossBetween" for not imported charts Change-Id: I52fdcdc52e75ac15c85e04c2982b25cc180d7815 Reviewed-on: https://gerrit.libreoffice.org/82617 Tested-by: Jenkins Reviewed-by: László Németh <nemeth@numbertext.org> Tested-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'chart2/source/model/template/ChartTypeTemplate.cxx')
-rw-r--r--chart2/source/model/template/ChartTypeTemplate.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/chart2/source/model/template/ChartTypeTemplate.cxx b/chart2/source/model/template/ChartTypeTemplate.cxx
index c18851796ada..afd9eb0f048a 100644
--- a/chart2/source/model/template/ChartTypeTemplate.cxx
+++ b/chart2/source/model/template/ChartTypeTemplate.cxx
@@ -626,7 +626,10 @@ void ChartTypeTemplate::adaptScales(
Reference< XChartType > xChartType(getChartTypeForNewSeries(Sequence< Reference< XChartType > >()));
if( aData.AxisType == AxisType::CATEGORY )
{
- aData.ShiftedCategoryPosition = ::chart::ChartTypeHelper::shiftCategoryPosAtXAxisPerDefault(xChartType);
+ if( !m_aServiceName.endsWith("ColumnWithLine") )
+ aData.ShiftedCategoryPosition = ::chart::ChartTypeHelper::shiftCategoryPosAtXAxisPerDefault(xChartType);
+ else
+ aData.ShiftedCategoryPosition = true;
}
bool bSupportsDates = ::chart::ChartTypeHelper::isSupportingDateAxis( xChartType, nDimensionX );
if( aData.AxisType != AxisType::CATEGORY && ( aData.AxisType != AxisType::DATE || !bSupportsDates) )