Bug 37407

Summary: Calc XY (scatter) chart Sort by x values has wrong x,y in tooltip
Product: LibreOffice Reporter: Christopher M. Penalver <christopher.m.penalver>
Component: ChartAssignee: Not Assigned <libreoffice-bugs>
Status: NEW --- QA Contact:
Severity: normal    
Priority: medium CC: erack, ign_christian, libreoffice, markus.mohrhard, serval2412
Version: 3.3.2 release   
Hardware: x86 (IA32)   
OS: All   
See Also: https://launchpad.net/bugs/258705
http://openoffice.org/bugzilla/show_bug.cgi?id=95508
Whiteboard:
i915 platform: i915 features:
Attachments: xyscatterbug.ods

Description Christopher M. Penalver 2011-05-20 07:44:26 UTC
Created attachment 46954 [details]
xyscatterbug.ods

Downstream bug may be found at:
https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/258705

OOo bug may be found at:
http://openoffice.org/bugzilla/show_bug.cgi?id=95508

1) lsb_release -rd
Description: Ubuntu 11.04
Release: 11.04

2) LibreOffice:
apt-cache policy libreoffice-calc
libreoffice-calc:
  Installed: 1:3.3.2-1ubuntu5
  Candidate: 1:3.3.2-1ubuntu5
  Version table:
 *** 1:3.3.2-1ubuntu5 0
        500 http://us.archive.ubuntu.com/ubuntu/ natty-updates/main i386 Packages
        500 http://us.archive.ubuntu.com/ubuntu/ natty-proposed/main i386 Packages
        100 /var/lib/dpkg/status
     1:3.3.2-1ubuntu4 0
        500 http://us.archive.ubuntu.com/ubuntu/ natty/main i386 Packages

3) What is expected to happen in Calc via the Terminal:

cd ~/Desktop && wget https://bugs.launchpad.net/ubuntu/+source/openoffice.org/+bug/258705/+attachment/403067/+files/xyscatterbug.ods && localc -nologo xyscatterbug.ods

double click the XY (Scatter), sorted by X values chart and hover the mouse icon over a data point, the pop up notes the correct X,Y value.

4) What happens instead is it does not. The pop-up is using the data values top to bottom, to display the data point values from left to right.
Comment 1 Björn Michaelsen 2011-12-23 12:02:48 UTC
[This is an automated message.]
This bug was filed before the changes to Bugzilla on 2011-10-16. Thus it
started right out as NEW without ever being explicitly confirmed. The bug is
changed to state NEEDINFO for this reason. To move this bug from NEEDINFO back
to NEW please check if the bug still persists with the 3.5.0 beta1 or beta2 prereleases.
Details on how to test the 3.5.0 beta1 can be found at:
http://wiki.documentfoundation.org/QA/BugHunting_Session_3.5.0.-1

more detail on this bulk operation: http://nabble.documentfoundation.org/RFC-Operation-Spamzilla-tp3607474p3607474.html
Comment 2 Christopher M. Penalver 2012-01-04 00:52:03 UTC
Reproducible in:
LOdev 3.5.0beta2 
Build ID: 8589e48-760cc4d-f39cf3d-1b2857e-60db978
Microsoft Windows Vista Business 6.0.6002 Service Pack 2 Build 6002
Comment 3 ign_christian 2013-05-23 15:32:59 UTC
Hi Christopher

I can confirm that using your explanation I can reproducible that problem. But if I build XY chart from scratch using your data it's not happen.

Could you confirm using LO 4.0.3.3 whether tooltips still show wrong info?
Comment 4 Christopher M. Penalver 2013-05-25 12:53:19 UTC
ign_christian, thank you for your comments. Using the attachment noted in the Description https://bugs.freedesktop.org/attachment.cgi?id=46954 one may open Microsoft Office Professional Plus 2010 Excel Version 14.0.6023.1000 (32-bit), hover over the noted data point, and it displays the correct tooltip information. For future triaging, let the focus be on the noted attachment.

Problem in Description reproducible in:
Microsoft Windows Vista Business x86 6.0.6002 Service Pack 2 Build 6002
Version: 4.2.0.0.alpha0+
Build ID: 979def88090633bfee0e0445b19999a1dac71ed
Comment 5 ign_christian 2013-06-13 08:17:31 UTC
I was using that attachment. Just wondering why creating new XY chart on that attachment generates correct result?
Comment 6 Julien Nabet 2014-08-24 07:26:37 UTC
On pc Debian x86-64 with master sources updated yesterday, I could reproduce this.

If I create from the file attached a new graphic, I could reproduce too the problem.
(ign_christian: had you checked "Sort by X Values"?)
Comment 7 ign_christian 2014-08-24 08:25:51 UTC
You're right Julien, reproducible with "Sort by X values" checked with LO 4.3.1.1. Looks like I forgot checked that in previous testing :)

Anyway I don't understand the purpose of "Sort by X values" in XY chart. It doesn't make any difference in chart.
Comment 8 Julien Nabet 2014-08-24 08:46:30 UTC
Thank you ign_christian for your feedback. Great (in a way) you could reproduce it too :)

Just some notes.
Searching "Sort by X Values" with keyId language gives this:
https://translations.documentfoundation.org/fr/translate/#search=CFYgL&sfields=source,target,notes
=> tp_ChartType.ui

http://opengrok.libreoffice.org/search?q=tp_ChartType.ui&project=core&defs=&refs=&path=&hist= gives:
- chart2/source/controller/dialogs/tp_PointGeometry.cxx
- chart2/source/controller/dialogs/tp_ChartType.cxx
From the second one, searching "sort" keyword gives mpCB_XValueSorting, itself linked to "bSortByXValues" member of ChartTypeParameter, see http://opengrok.libreoffice.org/xref/core/chart2/source/controller/dialogs/ChartTypeDialogController.hxx#81
Comment 9 Julien Nabet 2014-08-24 21:04:11 UTC
bSortByXValues brings there:
http://opengrok.libreoffice.org/xref/core/chart2/source/view/main/ChartView.cxx#784

Searching about how is defined data point gives this:
STR_TIP_DATAPOINT which leads there:
http://opengrok.libreoffice.org/xref/core/chart2/source/controller/dialogs/ObjectNameProvider.cxx#498

But then, I'm a bit stuck.

Kohei/Markus/Eike: any idea here?

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.