diff options
author | Balazs Varga <balazs.varga991@gmail.com> | 2019-12-10 12:53:08 +0100 |
---|---|---|
committer | László Németh <nemeth@numbertext.org> | 2019-12-16 08:58:25 +0100 |
commit | e57d90cd4e51a1353eafc87bb29cfe6076704a7c (patch) | |
tree | bdadf54a91203dcd32bd02a30d2187160c278d79 /sw | |
parent | c5f593d68b7f6d8a2f2adc75d5bcb795822efeac (diff) |
tdf#129173 tdf#129175 Fix number format of data labels
Show the real value (cell value) of datapoints instead
of the recalculated value in case of Percent Stacked Area
chart.
Also fix: tdf#95425
Do not reset number format of data labels when open dialog
of 'Format data series' and close dialog.
Note: Inherits the data series/point label format from the
cell format and not the axis format, if we set the 'link to source data'
option to true.
Change-Id: I04e9968034a67c6bc6b92941df61d945b4292d79
Reviewed-on: https://gerrit.libreoffice.org/84819
Tested-by: Jenkins
Reviewed-by: László Németh <nemeth@numbertext.org>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/qa/extras/layout/data/testAreaChartNumberFormat.docx | bin | 0 -> 26115 bytes | |||
-rw-r--r-- | sw/qa/extras/layout/layout.cxx | 16 |
2 files changed, 16 insertions, 0 deletions
diff --git a/sw/qa/extras/layout/data/testAreaChartNumberFormat.docx b/sw/qa/extras/layout/data/testAreaChartNumberFormat.docx Binary files differnew file mode 100644 index 000000000000..33e1c58788a5 --- /dev/null +++ b/sw/qa/extras/layout/data/testAreaChartNumberFormat.docx diff --git a/sw/qa/extras/layout/layout.cxx b/sw/qa/extras/layout/layout.cxx index eac0b40ddcd0..5274bef2b8a0 100644 --- a/sw/qa/extras/layout/layout.cxx +++ b/sw/qa/extras/layout/layout.cxx @@ -2474,6 +2474,22 @@ CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testTdf129054) CPPUNIT_ASSERT_EQUAL(sal_Int32(4810), nYTop - nYBottom); } +CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testTdf129173) +{ + SwDoc* pDoc = createDoc("testAreaChartNumberFormat.docx"); + SwDocShell* pShell = pDoc->GetDocShell(); + + // Dump the rendering of the first page as an XML file. + std::shared_ptr<GDIMetaFile> xMetaFile = pShell->GetPreviewMetaFile(); + MetafileXmlDump dumper; + xmlDocPtr pXmlDoc = dumpAndParse(dumper, *xMetaFile); + CPPUNIT_ASSERT(pXmlDoc); + + // Check the first data label of area chart. + assertXPathContent( + pXmlDoc, "/metafile/push[1]/push[1]/push[1]/push[4]/push[1]/textarray[22]/text", "56"); +} + CPPUNIT_TEST_FIXTURE(SwLayoutWriter, testTdf116925) { SwDoc* pDoc = createDoc("tdf116925.docx"); |