Bug 141948 - FILEOPEN DOCX chart's date axis format changed
Summary: FILEOPEN DOCX chart's date axis format changed
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Chart (show other bugs)
Version:
(earliest affected)
7.2.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
Depends on:
Blocks: OOXML-Chart
  Show dependency treegraph
 
Reported: 2021-04-28 12:28 UTC by NISZ LibreOffice Team
Modified: 2023-07-24 11:57 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Demo-Hayden-Management-3Dbarchart.docx (587.07 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2021-04-28 12:28 UTC, NISZ LibreOffice Team
Details
Screenshot of the original document side by side in Word and Writer (92.36 KB, image/png)
2021-04-28 12:28 UTC, NISZ LibreOffice Team
Details
Sample DOCX with simple chart (19.23 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2021-07-18 21:53 UTC, Aron Budea
Details
Original XLSX with the same chart (12.93 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-07-18 21:54 UTC, Aron Budea
Details

Note You need to log in before you can comment on or make changes to this bug.
Description NISZ LibreOffice Team 2021-04-28 12:28:26 UTC
Created attachment 171476 [details]
Demo-Hayden-Management-3Dbarchart.docx

This is minimized from bug #67339 example file.
The 3D bar charts date axis format changed recently from years to something else.

Steps to reproduce:
    1. Open attached file

Actual results:
Bar charts axis label format is not years.

Expected results:
Axis unit is years.

LibreOffice details:
Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: eeb2854e085fdd9f7a38d6e952a8aedf43e90323
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: hu-HU
Calc: CL

Not yet in
Version: 7.1.3.0.0+ (x64) / LibreOffice Community
Build ID: 296c1b3b7e2fca6d54e3e61684d70d12f7989624
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL

Additional Information: 

Bibisected using bibisect-win64-7.2 to:
URL: https://cgit.freedesktop.org/libreoffice/core/commit/?id=4b92707c19ef47cdb9474224e83e5153c54b661d 

author	Andras Timar <andras.timar@collabora.com>	2021-02-09 12:00:45 +0100
committer	Andras Timar <andras.timar@collabora.com>	2021-02-10 10:03:10 +0100
Fix chart label import, use the locale as MS Office does

Adding CC to: Andras Timar
Comment 1 NISZ LibreOffice Team 2021-04-28 12:28:55 UTC
Created attachment 171477 [details]
Screenshot of the original document side by side in Word and Writer
Comment 2 Xisco Faulí 2021-05-05 09:25:28 UTC
I can't reproduce it in

Version: 7.2.0.0.alpha0+ / LibreOffice Community
Build ID: 1a99b4e44190e182d56a04678850d62635d74c65
CPU threads: 4; OS: Linux 5.7; UI render: default; VCL: x11
Locale: en-US (en_US.UTF-8); UI: en-US
Calc: threaded

Axis units are years...
Comment 3 Xisco Faulí 2021-05-05 09:26:51 UTC
Win only ?
Comment 4 NISZ LibreOffice Team 2021-06-08 10:37:03 UTC
(In reply to Xisco Faulí from comment #3)
> Win only ?

Somewhat... it looks locale-independently bad on Win10 (at least on my Hungarian one), but locale-dependently on Linux:

Good with 
Version: 7.2.0.0.alpha1+ / LibreOffice Community
Build ID: e8578423e9390a07419066d6c350c34fa254095d
CPU threads: 4; OS: Linux 5.8; UI render: default; VCL: gtk3
Locale: en-US (hu_HU.UTF-8); UI: en-US
Calc: threaded

(custom build from a few weeks ago)

But not with

Version: 7.2.0.0.alpha1+ / LibreOffice Community
Build ID: e8578423e9390a07419066d6c350c34fa254095d
CPU threads: 4; OS: Linux 5.8; UI render: default; VCL: gtk3
Locale: hu-HU (hu_HU.UTF-8); UI: en-US
Calc: threaded
Comment 5 NISZ LibreOffice Team 2021-06-08 11:24:35 UTC
It is locale-dependent on Windows as well:

Good on nightly:
Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 3b57ebb445df8a2bc3d916ea79f8af45e20e4e62
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win
Locale: en-US (hu_HU); UI: hu-HU
Calc: CL

Bad on the same with Hungarian locale:
Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 3b57ebb445df8a2bc3d916ea79f8af45e20e4e62
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: hu-HU
Calc: CL
Comment 6 Andras Timar 2021-06-08 12:02:48 UTC
Sorry for the regression. I made the fix for a Turkish chart, where the labels contained month names, and the reference rendering showed Turkish month names, while LibreOffice displayed English month names. 

In this bug with the Hungarian locale we get weird date format. FWIW I tried a few other locales. E.g. Slovenian was bad, German and Italian were good.

The string "i. sz." is coming from i18npool/source/localedata/data/hu_HU.xml, it is the Era "AD" -- Anno Domini a.k.a after Christ.

The real question, I think, is that why this date format is picked up instead of the obvious YYYY.
Comment 7 Aron Budea 2021-07-18 21:53:18 UTC
Created attachment 173659 [details]
Sample DOCX with simple chart

It's fairly simple to create a document with a chart that shows buggy axis labels, I created a minimal chart in Excel, copy-pasted it to Word, and saved it as DOCX. 

What's interesting is that the chart in the XLSX is fine in Calc, only the chart in the DOCX has this bug.
Comment 8 Aron Budea 2021-07-18 21:54:07 UTC
Created attachment 173660 [details]
Original XLSX with the same chart
Comment 9 QA Administrators 2023-07-19 03:15:30 UTC Comment hidden (obsolete)
Comment 10 Gabor Kelemen (allotropia) 2023-07-24 11:57:27 UTC
This seems to be fixed in 7.3 (the example files look good even after a roundtrip, both in Writer and Word) since:

https://git.libreoffice.org/core/+/f547cf17a179ebd7de5c2b4dd2d00d0027a25429

author	Dennis Francis <dennisfrancis.in@gmail.com>	Thu Sep 02 14:33:55 2021 +0530
committer	Miklos Vajna <vmiklos@collabora.com>	Mon Sep 06 08:47:50 2021 +0200

[API CHANGE] oox: fix import of chart date categories

Thanks for fixing this :)