summaryrefslogtreecommitdiff
path: root/chart2/source/tools/DataSeriesHelper.cxx
diff options
context:
space:
mode:
authorBalazs Varga <balazs.varga991@gmail.com>2020-09-02 15:09:01 +0200
committerLászló Németh <nemeth@numbertext.org>2020-09-24 09:29:52 +0200
commit0dce53516011f5d2d9408501714e2b1865517119 (patch)
tree4594ea7569839eda7606cbaca5540b15cefe0091 /chart2/source/tools/DataSeriesHelper.cxx
parent0f99330f33868594ad253656805918115823f59d (diff)
tdf#136402 Chart View: remove custom label text
Now Delete Data Labels and Insert Data Labels local menu options remove custom label text instead of keeping it. See with unit test document custom_data_label.xlsx of commit bcda268cde1f8408c2066ce985acedfce3e3bc2e (tdf#134977 Chart OOXML: fix import of custom data label). Change-Id: Ifc7afd0f2ece9da528e6206a6bd393b394b36f9e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/101929 Tested-by: László Németh <nemeth@numbertext.org> Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'chart2/source/tools/DataSeriesHelper.cxx')
-rw-r--r--chart2/source/tools/DataSeriesHelper.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/chart2/source/tools/DataSeriesHelper.cxx b/chart2/source/tools/DataSeriesHelper.cxx
index 809ba67a931e..c7dabaf1d4da 100644
--- a/chart2/source/tools/DataSeriesHelper.cxx
+++ b/chart2/source/tools/DataSeriesHelper.cxx
@@ -173,6 +173,7 @@ void lcl_insertOrDeleteDataLabelsToSeriesAndAllPoints( const Reference< chart2::
aLabel.ShowCustomLabel = false;
}
xPointProp->setPropertyValue(CHART_UNONAME_LABEL, uno::Any(aLabel));
+ xPointProp->setPropertyValue(CHART_UNONAME_CUSTOM_LABEL_FIELDS, uno::Any());
}
}
}
@@ -837,6 +838,7 @@ void deleteDataLabelsFromPoint( const Reference< beans::XPropertySet >& xPointPr
aLabel.ShowCategoryName = false;
aLabel.ShowCustomLabel = false;
xPointProp->setPropertyValue(CHART_UNONAME_LABEL, uno::Any(aLabel));
+ xPointProp->setPropertyValue(CHART_UNONAME_CUSTOM_LABEL_FIELDS, uno::Any());
}
}
catch(const uno::Exception &)