Bug 108059 - FILESAVE Pie and Donut charts appear mirrored in OOXML formats
Summary: FILESAVE Pie and Donut charts appear mirrored in OOXML formats
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Chart (show other bugs)
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
Whiteboard: target:7.1.0
Keywords: filter:ooxml
Depends on:
Blocks: OOXML-Chart
  Show dependency treegraph
Reported: 2017-05-24 14:18 UTC by Gabor Kelemen (allotropia)
Modified: 2020-09-28 07:41 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:

Example file from LO 5.3 (15.95 KB, application/vnd.oasis.opendocument.text)
2017-05-24 14:18 UTC, Gabor Kelemen (allotropia)
Example file saved from LO 5.3 (14.70 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2017-05-24 14:23 UTC, Gabor Kelemen (allotropia)
Docx in Word 2013 and odt in LO 5.3 side by side (156.39 KB, image/png)
2017-05-24 14:24 UTC, Gabor Kelemen (allotropia)
Sample pie chart in ODS (13.38 KB, application/vnd.oasis.opendocument.spreadsheet)
2019-02-28 22:42 UTC, Aron Budea
One chart with chart:reverse-direction false, the other with true (19.15 KB, application/vnd.oasis.opendocument.spreadsheet)
2019-11-12 22:30 UTC, Regina Henschel

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2017-05-24 14:18:26 UTC
Created attachment 133518 [details]
Example file from LO 5.3

The Pie and Donut charts appear vertically mirrored when saved in LibreOffice Writer as DOCX and opened in Microsoft Word 2013.

Steps to reproduce:
1. Create an empty text document in LibreOffice Writer
2. Insert a Chart
3. Change chart type to any Pie chart (normal, exploded, donut, exploded donut)
4. Save the file as DOCX
5. Reopen the file in Microsoft Word 2013

Actual results:
The chart appears vertically mirrored

Expected results:
The chart should look like in LibreOffice Writer
Comment 1 Gabor Kelemen (allotropia) 2017-05-24 14:23:52 UTC
Created attachment 133519 [details]
Example file saved from LO 5.3
Comment 2 Gabor Kelemen (allotropia) 2017-05-24 14:24:47 UTC
Created attachment 133520 [details]
Docx in Word 2013 and odt in LO 5.3 side by side
Comment 3 Jacques Guilleron 2017-05-25 07:14:35 UTC

I reproduce with
LO Build ID: 0e6297932252403883a6057feee488e4ee2bc360
CPU threads: 2; OS: Windows 6.1; UI render: default; 
TinderBox: Win-x86@39, Branch:master, Time: 2017-05-23_00:14:17
Locale: fr-FR (fr_FR); Calc: CL
also with
LO Build ID: f4ca7b35f580827ad2c69ea6d29f7c9b48ebbac7
& Windows 7 Home.
Comment 4 QA Administrators 2018-05-26 02:42:15 UTC Comment hidden (obsolete)
Comment 5 Jacques Guilleron 2018-05-27 11:29:12 UTC
Still present in
Build ID: 23c5125148a8110d88385b29570bf0b7d4400458
CPU threads: 2; OS: Windows 6.1; UI render: default; 
TinderBox: Win-x86@42, Branch:master, Time: 2018-05-12_00:15:25
Locale: fr-FR (fr_FR); Calc: CL
Comment 6 Adam Kovacs 2018-08-22 09:10:40 UTC
In the ODF standard there is a "chart:reverse-direction" attribute, which is missing from the OOXML standard. By default in LibreOffice it is set to false (there is no problem with this in the case of odt, ods,... files), but when you save the file to docx, xlsx,... and reopen/reload it, the chart will behave as if this attribute would have been set to true.

So chart:reverse-direction="true" behave the same way like the docx charts/diagrams, but the default value in LibreOffice is false.
Maybe I can suggest that the default value should be set to true in LibreOffice or the false value should behave like the true value now.

Search for: "20.44 chart:reverse-direction" in this file:
And you can see there: "False is the default."
Other downloads of the ODF standard: https://www.oasis-open.org/standards
Comment 7 Aron Budea 2019-02-28 22:41:33 UTC
This isn't specific to DOCX and opening the result in MSO, the chart also shows mirrored when the saved file is reopened in LO.
Comment 8 Aron Budea 2019-02-28 22:42:50 UTC
Created attachment 149668 [details]
Sample pie chart in ODS

Here's an ODS that behaves the same way.
Comment 9 Regina Henschel 2019-11-12 22:30:42 UTC
Created attachment 155762 [details]
One chart with chart:reverse-direction false, the other with true


ODF 1.2 has the attribute chsrt:revers-direction, which can be used to carry the direction information, and LibreOffice renders it already correctly. Only that there is no UI for it.
Comment 10 Commit Notification 2020-09-28 07:18:59 UTC
Kelemen Gábor committed a patch related to this issue.
It has been pushed to "master":


tdf#108059 Introduce compatibility key for pie chart orientation

It will be available in 7.1.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:

Affected users are encouraged to test the fix and report feedback.