Bug 145198 - Bash like autocompletion for Calc's autoinput
Summary: Bash like autocompletion for Calc's autoinput
Status: CLOSED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.3.0.0 alpha0+
Hardware: All All
: medium enhancement
Assignee: Not Assigned
URL:
Whiteboard: target:7.3.0 inReleaseNotes
Keywords:
Depends on:
Blocks: AutoCorrect-Complete
  Show dependency treegraph
 
Reported: 2021-10-18 09:16 UTC by Dennis Francis
Modified: 2023-11-27 22:07 UTC (History)
2 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 Dennis Francis 2021-10-18 09:16:56 UTC
Description:
Make Calc's autoinput behave like autocompletion in Bash.

Refer the section "Calc auto-complete behavior changes" in https://lists.freedesktop.org/archives/libreoffice/2021-October/087911.html for context.


Steps to Reproduce:
Consider an example of the following data in a column:
    
ABCD123xyz
ABCD345qwel
ABCD123pqr
ABCD123xyz
PQR

Currently on master, if the user types A in an empty cell in the same column it does not show any suggestion and the only way to enter the text "ABCD123pqr" using autocomplete is to type "ABCD123p".

Actual Results:
Currently on master, if the user types A in an empty cell in the same column it does not show any suggestion and the only way to enter the text "ABCD123pqr" using autocomplete is to type "ABCD123p".

Expected Results:
If the user types A it should show the partial completion BCD (common prefix). If the user accepts that types 1 it should show the next partial suggestion 23. If the user accepts again and types p it should show the final completion of qr.




Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 7.3.0.0.alpha0+ / LibreOffice Community
Build ID: ebd45a80a8024c1f4fd435cedc74d60ccdec6d87
CPU threads: 8; OS: Linux 5.11; UI render: default; VCL: gtk3
Locale: en-IN (en_IN); UI: en-US
Calc: threaded
Comment 1 Commit Notification 2021-10-18 11:21:20 UTC
Dennis Francis committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/4cfa840ecaa5a094a32a60a60b295858980109df

tdf#145198: Bash like autocompletion for Calc autoinput

It will be available in 7.3.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.
Comment 2 Felicia Medina 2021-11-15 05:53:53 UTC Comment hidden (spam)
Comment 3 Stéphane Guillou (stragu) 2022-01-01 11:38:35 UTC
Reviewing 7.3 release notes.

Verified in:

Version: 7.3.0.1 / LibreOffice Community
Build ID: 840fe2f57ae5ad80d62bfa6e25550cb10ddabd1d
CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded
Comment 4 bugzilla2 2022-07-01 17:33:51 UTC
Is it possible to switch between old and new auto-completion behaviour? Because this new behaviour is worse for me.
Comment 5 galvindai 2022-09-08 08:41:38 UTC Comment hidden (spam)
Comment 6 Jax 2023-09-03 10:26:34 UTC
Praise the Lords of Codes!

Thanks so much!
Comment 7 foubug 2023-11-26 11:21:30 UTC
After migrating to Linux Mint 21.2 I found myself stuck with LO 7.3.7(.2?). I found this bug and bug 142214 today. Just now, I added the LO PPA and updated to 7.6.3.2, but to me it seems the auto-complete behaviour hasn't changed. Example: 

    A
1   Ox
2   Office

When I type O in A3 nothing happens. Shouldn’t there be something appearing, or am I understanding this thread and that of bug 142214 wrong? I would expect Calc to auto-complete to Office. Looks like the bug is back.
Comment 8 ady 2023-11-26 14:55:36 UTC
(In reply to foubug from comment #7)
> Shouldn’t there be something appearing,
> or am I understanding this thread and that of bug 142214 wrong? I would
> expect Calc to auto-complete to Office. Looks like the bug is back.

You are misunderstanding the (inefficient) modification imposed by Dennis. Indeed, as many other users noticed, the behavior since LO 7.3 is less efficient and does not immediately auto-complete; users need additional steps (in comparison to the older behavior) in order to trigger the auto-complete suggestion.
Comment 9 foubug 2023-11-26 16:17:16 UTC
Doesn’t his commit state otherwise?
https://git.libreoffice.org/core/commit/4cfa840ecaa5a094a32a60a60b295858980109df
Comment 10 ady 2023-11-26 19:42:52 UTC
(In reply to foubug from comment #9)
> Doesn’t his commit state otherwise?
> https://git.libreoffice.org/core/commit/4cfa840ecaa5a094a32a60a60b295858980109df

No. Taking your example:

    A
1   Ox
2   Office

In cell A3, type-in "O" (without quotation marks) and (with the newer bash-like auto-complete) you will find _no_ suggestion (yet). Now add one more letter, "Of" (without quotation marks), and you will get the first suggestion.

IOW, to be able to get some auto-complete suggestion, the typed-in characters must offer some kind of uniqueness while they must match a prior entry in the same (data) column. If the already typed-in characters are equal to one unique (prior) value (in the column), then the full-cell content suggestion is offered to the user for auto-complete. Using "bash-like" methods, you could have part-cell content suggestions.

As many users mentioned before, the new algorithm is not better. But since this report is closed now and the bash-like behavior has been implemented for several versions by now, there is no point on continuing adding comments here.

If you need assistance with this behavior, or alternative methods for introducing (repeating) values/data, I would suggest first carefully reading the related reports (such as bug 142214 and others "see also" reports), and then you might want to open a new topic on <https://ask.libreoffice.org>. If all that is not enough, you might want to open a new enhancement request report.
Comment 11 foubug 2023-11-27 20:18:09 UTC
(In reply to ady from comment #10)
> No. Taking your example:
> 
>     A
> 1   Ox
> 2   Office
> 
> In cell A3, type-in "O" (without quotation marks) and (with the newer
> bash-like auto-complete) you will find _no_ suggestion (yet). Now add one
> more letter, "Of" (without quotation marks), and you will get the first
> suggestion.

Ok, so it’s a bug, because:

»1. When user types A, it will show the partial suggestion BCD.«

> If you need assistance with this behavior, or alternative methods for
> introducing (repeating) values/data, I would suggest first carefully reading
> the related reports (such as bug 142214 and others "see also" reports), and
> then you might want to open a new topic on <https://ask.libreoffice.org>. If
> all that is not enough, you might want to open a new enhancement request
> report.

Sorry, no time for endless discussions. I’ll have to live with the fact that, once more, one of the best software options has deteriorated somewhat in quality.
Comment 12 ady 2023-11-27 22:07:04 UTC
In order to avoid misleading other readers, I am compelled to reply, unfortunately.

(In reply to foubug from comment #11)
> Ok, so it’s a bug, because:
> 
> »1. When user types A, it will show the partial suggestion BCD.«

You are misunderstanding, again.

That quote is relevant for the following data set:

ABCD123xyz
ABCD345qwel
ABCD123pqr
ABCD123xyz
PQR

...in which _all_ the values that start with the same initial characters that were introduced ("A" in this case), continue with the same set of characters ("BCD" in this case). The first character that differentiates the values (i.e. after the "ABCD" initial characters in this example) stops the auto-complete and so the user is required to type-in additional characters.


> > If you need assistance with this behavior, or alternative methods for
> > introducing (repeating) values/data, I would suggest first carefully reading
> > the related reports (such as bug 142214 and others "see also" reports), and
> > then you might want to open a new topic on <https://ask.libreoffice.org>. If
> > all that is not enough, you might want to open a new enhancement request
> > report.
> 
> Sorry, no time for endless discussions. I’ll have to live with the fact
> that, once more, one of the best software options has deteriorated somewhat
> in quality.


Then please avoid additional comments in this bug report, unless there is something relevant to it.