Bug 130031

Summary: FILEOPEN XLSX Area chart data label positioning imported incorrectly
Product: LibreOffice Reporter: NISZ LibreOffice Team <libreoffice>
Component: ChartAssignee: Tünde Tóth <tundeth>
Status: RESOLVED FIXED    
Severity: normal CC: kelemeng, nemeth, xiscofauli
Priority: medium    
Version: 4.1 all versions   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=130242
https://bugs.documentfoundation.org/show_bug.cgi?id=130380
Whiteboard: target:6.5.0
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 75057    
Attachments: Example file from Calc
Screenshot of the original document side by side in Excel and Calc
subtypes of area chart (work in progress)

Description NISZ LibreOffice Team 2020-01-16 09:51:22 UTC
Description:
Default data label positioning of area charts in Excel is vertically centered between the X axis and the data point.
Opening this in Calc the data labels positioning is above the data point.

Steps to Reproduce:
1. Create a simple area chart in Excel
2. Enable data labels, save the file and open it in Calc

Actual Results:
The data labels appear above the data points.

Expected Results:
The data labels should appear vertically centered between the X axis and the data point.


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 NISZ LibreOffice Team 2020-01-16 09:53:09 UTC
Created attachment 157178 [details]
Example file from Calc
Comment 2 NISZ LibreOffice Team 2020-01-16 09:53:42 UTC
Created attachment 157179 [details]
Screenshot of the original document side by side in Excel and Calc
Comment 3 Xisco Faulí 2020-01-21 09:27:50 UTC
Also reproduced in

Version: 4.3.0.0.alpha1+
Build ID: c15927f20d4727c3b8de68497b6949e72f9e6e9e

Version 4.1.0.0.alpha0+ (Build ID: efca6f15609322f62a35619619a6d5fe5c9bd5a)
Comment 4 László Németh 2020-01-22 15:01:04 UTC
Created attachment 157330 [details]
subtypes of area chart (work in progress)
Comment 5 László Németh 2020-01-22 15:05:41 UTC
It seems, MSO uses the default (and only) center labelling of area charts for better stacked area charts.

@Tünde: Unfortunately, the work-in-progress patch results regressions here, see the differences. 3D charts don't use exact center positioning. The stacked charts use center positioning inside of the area of the single data sets, not center of the data point-Y axis section.
Comment 6 Commit Notification 2020-01-28 08:51:54 UTC
Tünde Tóth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/f8966bb398cf0623be841c618b123866801a063c

tdf#130031 Chart OOXML import: fix area chart data label position

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