Bug 93936 - Creating a formula using Ctrl can incorrectly append a comma at the beginning of the function argument
Summary: Creating a formula using Ctrl can incorrectly append a comma at the beginning...
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.0.1.2 release
Hardware: All All
: low minor
Assignee: Not Assigned
URL:
Whiteboard: target:5.2.0
Keywords:
Depends on:
Blocks: Cell-Formula
  Show dependency treegraph
 
Reported: 2015-09-05 04:27 UTC by Óvári
Modified: 2017-10-26 09:58 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Óvári 2015-09-05 04:27:23 UTC
Version: 5.0.1.2 (x64)
Build ID: 81898c9f5c0d43f3473ba111d7b351050be20261

1. In cell A1 type: =SUM(
2. Press and hold the Ctrl key.
3. Press (i.e. click) and hold the left mouse button on cell F10.
   a) Cell A1 incorrectly has: =SUM(,F10
   b) Cell A1 should have: =SUM(F10
4. Move the mouse to cell D4.
   a) Cell A1 incorrectly has: =sum(,D4:F10
   b) Cell A1 should have: =sum(D4:F10
5. Release the left mouse button.
6. Press enter.
7. Dialog box stating LibreOffice has found an error.
   This dialog box would not show if the comma had not been appended to the beginning of the formula argument.

Thank you
Comment 1 Jean-Baptiste Faure 2015-09-06 11:07:15 UTC
The correct procedure is to click and hold down the left mouse button first, then hit and hold the ctrl key to extend the selection with the mouse.

Closing as WorksForMe. Please feel free to reopen and argue if you disagree.

Best regards. JBF
Comment 2 Óvári 2015-09-06 14:03:52 UTC
1. Increases usability and reduces the number of small annoyances (even though this corner case may occur rarely in the casual/home users segment; however, this may occurs more frequently in the enterprise/government).
2. Why not extend the procedure to work if you press Ctrl first? eg. Instructions that say Ctrl+Shift+F also work for Shift+Ctrl+F.
3. MS XL caters for this bug.
4. This would increase "Calc's blend of performance and features makes it an enterprise-ready, heavy duty spreadsheet application capable of handling all kinds of workload for an impressive range of use cases."
https://www.libreoffice.org/discover/new-features/

Thank you
Comment 3 Jean-Baptiste Faure 2015-09-06 15:39:57 UTC
Why not learn how LibreOffice works instead using MSO manual and asking that LibreOffice follows that manual?
CTRL key is useful only to add a new cell range; for the first one you do not need to hit ctrl key.

Closing as WorksForMe again.

Best regards. JBF
Comment 4 Óvári 2015-10-22 05:58:16 UTC
Bug 93936 is a corner cases on how office productivity software works. Microsoft Excel (as stated previously) and Google Sheets (tested today) both correctly allow users to press Ctrl first and select multiple ranges, one range or one cell, with no comma appended at the beginning of the function argument.

Hence the following numbered points should be added to comment 2:
5. Google Sheets caters for this bug.
6. Exemplar office productivity software caters for this bug.

Hence, setting to UNCONFIRMED.
Comment 5 Joel Madero 2015-10-23 14:58:21 UTC
I tend to agree that I can't imagine a scenario where you'd want that comma at the beginning. But, I also agree with JBF that learning the software is on the user and not on the developers.

Confirmed:
LibreOffice 5.0.4 (master)
Ubuntu 15.04 x64

Marking as:
NEW:
Minor - will not prevent high quality work, user needs to know how to use the software and there is a very easy workaround (not even a workaround...just the "right" way to do it)
Low - given that it's always worked like this and no other user has ever complained about the problem, it seems like a very corner case issue that most people quickly learn how to do it.
Comment 6 Óvári 2015-10-23 20:17:29 UTC
Thank you
Comment 7 Óvári 2016-01-14 22:52:40 UTC
Dennis Francis kindly implemented a patch of bug 96523.

Calc now works if Ctrl is pressed and held before or immediately after the first selection, if the first selection is a column or row.
Comment 8 Óvári 2016-01-20 21:25:55 UTC
Change
  Status: NEW → Assigned
because of field
  Assigned To: Kumar Thangavel(ldcs.co.in)

If the status change in incorrect, please correct. Thank you
Comment 9 Kumar Thangavel 2016-01-22 05:40:56 UTC
Patch has been submitted for this bug.
https://gerrit.libreoffice.org/#/c/21667/
Comment 10 Commit Notification 2016-02-03 15:30:17 UTC
kumar committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=94aff0c21989e8be46b1676cef4d2a1db61752d3

tdf#93936:while creating formula comma appends incorrectly using Ctrl key

It will be available in 5.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 11 Óvári 2016-02-04 04:10:13 UTC
(In reply to Commit Notification from comment #10)
> Affected users are encouraged to test the fix and report feedback.

Please see bug 97548. Thank you

Added Kumar Thangavel(ldcs.co.in) to CC.
Comment 12 Óvári 2016-04-01 11:14:59 UTC
(In reply to Commit Notification from comment #10)
> kumar committed a patch related to this issue.

Is a unit test going to be added to this patch?

Thank you
Comment 13 Xisco Faulí 2016-09-15 22:31:36 UTC
Hello,
Is this bug fixed?
If so, could you please close it as RESOLVED FIXED?
Comment 14 Óvári 2016-09-16 05:53:50 UTC
(In reply to Xisco Faulí from comment #13)
The bug was not correctly resolved. Perhaps bug 97548 comments should have been written in this bug report. Thank you
Comment 15 Xisco Faulí 2017-10-23 09:09:15 UTC
Dear Kumar Thangavel,
This bug has been in ASSIGNED status for more than 3 months without any activity. Resetting it to NEW.
Please assigned it back to yourself if you're still working on this.
Comment 16 Óvári 2017-10-26 09:58:15 UTC
Thank you kumar, now works for me in LibreOffice Version: 5.4.3.1
Build ID: 32c8895c6cae21571f364dbb059f419a743ee44d