Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vim command mode autocompletion selection state is sticky between typing bursts #3751

Open
Samonitari opened this issue Jul 8, 2021 · 1 comment
Labels
A-quickmenu Area: Quickmenu-related, i.e. QuickOpen, WIldmenu, Command Palette menus bug Something isn't working

Comments

@Samonitari
Copy link

I report a vim command mode autocompletion issue again 💌

Issue title says it mostly. Selecting an autocompletion suggestion causes some misbehaviour - I think.
User can't consistently select the first suggestion with one key!

Here are two real life scenarios that have confusingly - or dare I say frustratingly - different results:

Scenario 1:

  • type :chdir ~/Do -> suggestions kick in, with the current user's "Documents" as the first option (assuming English OS setup)
    no suggestion is selected now
  • press Tab or Down -> command gets completed with the first suggestion

Scenario 2:

  • type :chd
  • press Tab or Down -> autocompletion filled to "chdir" command
  • type ~/Do -> suggestions kick in, with first suggestion selected
  • press Tab or Down -> command gets completed with the second suggestion

Scenario 2 can be reproduces by multiple 'tabbing' in only the path also - you don't need the first tab in the command of course.
Thanks to @CrossR for the help in Discord, he found the offending lines here

@CrossR
Copy link
Member

CrossR commented Jul 8, 2021

My assumption here is that (at least for the vim command line), we don't want the behaviour in the linked code, as persisting the currently focused item doesn't mean anything here, since its basically a fully new set of items.

I'm guessing that code is useful for cases where data is streaming in?

So perhaps it needs an additional parameter or some way of distinguishing between "yes this is an update" and this which is less of an update and more of a full new set of items. Perhaps a new action then, that sets the full set of items as you could argue this isn't really "UpdateFilterProgress" and actually something else.

@CrossR CrossR added A-quickmenu Area: Quickmenu-related, i.e. QuickOpen, WIldmenu, Command Palette menus bug Something isn't working labels Jul 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-quickmenu Area: Quickmenu-related, i.e. QuickOpen, WIldmenu, Command Palette menus bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants