Closed DyalogRichard closed 6 years ago
These are two very different systems. The backtick's autocomplete is an input method, i.e. it doesn't insert a continuation of what you typed, but rather substitutes it with something else. In fact, it probably shouldn't even be called autocomplete, but rather auto-substitute. This system is purely a RIDE feature. The ] autocomplete originates from the user command system, by way of the interpreter, and only serves to automate the continuation of what you wrote, just like all other autocompletes provided by the interpreter itself.
Right - but I still think it's odd they behave differently.
Subtext - without being able to try it to confirm, I think I'd prefer the backtick mechanism if it behaved more like the ] autocomplete.
I can see backtick allowing correction (2), but it really does need to look everywhere (1) because of cases like implication
which is only listed as logicalimplication
. However, I do agree that pd
finding expand
is a bit over the top.
Matching non-contiguously does seem a bit OTT.
To address your concern, "implication" could be included in its own right. There's not much benefit of being able to match with "alim" or even "plica", for example.
It might well be too well established to change now, but I raised it so we at least give it thought as it seemed to be an obvious inconsistency. The fact that one is done in the interpreter and one in RIDE will be of no interest to the average user.
Autocomplete with Monaco is somewhat complicated.
As early testers (and myself included) didn't like the relaxed filtering of Monaco, I implemented point 2 above to get the effect desired. I haven't found a way to configure Monaco to just do it that way itself.
The prefix complete feature introduced by Nick has been wedged in with Monaco's completion provider system. As @abrudz points out, it is desirable to have a fuzzy search in these cases, but I haven't done anything yet about making it stricter. At the moment it just relies on Monaco's filtering system.
You will note that I also implemented a shell like autocomplete mode as per @JohnScholes suggestion #347. In short, there are inconsistencies in how autocomplete works, but happy to hear your views on how it is best implemented.
Thanks, Gil. I've also spoken with Jay this morning and we agree that this is probably no longer usefully managed as a bug report - there are a mixture of different issues all muddled up here. So, I'll close this issue and we can less formally handle it as part of "Jay's list of feedback he's received".
FYI - the 17.0 IME also supports ` now. It behaves differently again!
Describe the issue you are having
The way different autocompletes work is inconsistent
Did you connect to an already running interpreter or start the interpreter from RIDE?
Connect
How do you reproduce the issue?
In the session type ]a The autocomplete options are ]adoc, ]align and ]array Backspace to erase the a and type b so that ]b is shown. The autocomplete options are ]box and ]boxing
Now type (backtick) (backtick) a There are a load of suggestions Backspace to erase the a and type b so that (backtick) (backtick)b is shown. No autocomplete options are shown
The differences appear to be:
] autocomplete (1) shows names that can complete what has already been typed (i.e. that start with the given sequence); (2) can be corrected
(backtick) (backtick) autocomplete (1) shows all names that contain what has already been typed (anywhere, not just at the start); (2) cannot be corrected
Should they not be consistent?
I find the (backtick) (backtick) autocomplete style less useful - especially not being able to correct, 'cos I make a lot of typing wrrors.
Paste the contents of Help → About (Shift+F1)