| Summary: | FILEOPEN DOCX Chart has different legend entry text | ||
|---|---|---|---|
| Product: | LibreOffice | Reporter: | NISZ LibreOffice Team <libreoffice> |
| Component: | Chart | Assignee: | Justin L <jluth> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | jluth, kelemeng, nemeth, xiscofauli |
| Priority: | medium | Keywords: | bibisected, bisected |
| Version: | 4.3 all versions | ||
| Hardware: | All | ||
| OS: | All | ||
| See Also: | https://bugs.documentfoundation.org/show_bug.cgi?id=127586 | ||
| Whiteboard: | target:7.4.0 | ||
| Crash report or crash signature: | Regression By: | ||
| Bug Depends on: | |||
| Bug Blocks: | 142046 | ||
| Attachments: |
Screenshot of the document in Writer 4.2
Screenshot of the document in Writer 4.3 Screenshot of the document in current Writer master |
||
|
Description
NISZ LibreOffice Team
2019-11-12 13:50:36 UTC
Created attachment 155746 [details]
Screenshot of the document in Writer 4.2
Created attachment 155747 [details]
Screenshot of the document in Writer 4.3
Created attachment 155748 [details]
Screenshot of the document in current Writer master
Additional Information: Bibisected using bibisect-win32-4.3 to: URL: https://cgit.freedesktop.org/libreoffice/core/commit/?id=6e31feb0f09f2dc9a9cd10e77ef884e000e1b32b author Kohei Yoshida <kohei.yoshida@collabora.com> 2014-06-12 11:24:30 -0400 committer Kohei Yoshida <kohei.yoshida@collabora.com> 2014-06-12 11:32:17 -0400 summary: fdo#77506: More reliable way to determine label strings. Additional Information: Bibisected using bibisect-win32-4.3 to: URL: https://cgit.freedesktop.org/libreoffice/core/commit/?id=6e31feb0f09f2dc9a9cd10e77ef884e000e1b32b author Kohei Yoshida <kohei.yoshida@collabora.com> 2014-06-12 11:24:30 -0400 committer Kohei Yoshida <kohei.yoshida@collabora.com> 2014-06-12 11:32:17 -0400 summary: fdo#77506: More reliable way to determine label strings. Reproduced in Version: 6.5.0.0.alpha0+ Build ID: 3a6f270edfffb97763927b2732feacedbdac1e80 CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US Calc: threaded removing "regression" because before this half of the labels were missing, so if one thing happened to be in the right place, it likely was simply miraculous. Plus, the code that was being replaced was horrendous and hacky beyond belief. I think the problem is related to column C and D being empty. There is only the string Reference for those columns. The problematic column is the first in read-order in the file, followed by the two empty ones. It is picking up the strRef of the last empty column. I think the identified commit is a complete red herring. As far as I can see, the entire chart passed to this file already only has 4 columns (instead of 6), and the desired label string is not included in any of these four columns. So I expect the code to be in a completely different place. Another dead end appears to be oox/source/drawingml/chart/seriesconverter.cxx
Reference< XDataSeries > SeriesConverter::createDataSeries()'s
if (!nDataPointCount)
// No values present. Don't create a data series.
return Reference<XDataSeries>();
which happens twice after label "If oversubscription relative to allowance increases at the same average rate B15-B17"
Unrelated (connected to Axis Title and Chart Title) are two
"warn:legacy.osl:oox/source/drawingml/chart/titleconverter.cxx:173: TitleConverter::convertFromModel - multiple text properties"
The read-order is definitely at play here somehow. If I swap around the empty "Likely funding required" and "Oversubscription rate" around in chart1.xml, then the label changes.
After 3 days of looking, I finally found the spot
in chart2/source/tools/InternalDataProvider.cxx:
else if (rRole == u"label")
{
// Data series label. There should be only one element. This always
// goes to the last data column.
sal_Int32 nColSize = m_aInternalData.getColumnCount();
if (!aRawElems.empty() && nColSize)
{
std::vector<uno::Any> aLabels(1, uno::Any(aRawElems[0]));
m_aInternalData.setComplexColumnLabel(nColSize-1, std::move(aLabels));
proposed fix at https://gerrit.libreoffice.org/c/core/+/130946 Justin Luth committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/cfd82e7a2cc2b45b738eb0efa0827196d2de61a4 tdf#128747 chart2: don't overwrite labels It will be available in 7.4.0. The patch should be included in the daily builds available at https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: https://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback. |