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

The "ctrl+right" shortcut accepts suggestions in places that don't make sense. #1501

Open
PoignardAzur opened this issue Jun 19, 2024 · 0 comments

Comments

@PoignardAzur
Copy link

PoignardAzur commented Jun 19, 2024

A shortcut was recently added where "ctrl/cmd+right" accepts the next word of an inline completion. When that completion follows the cursor, that shortcut makes sense.

But in some situations, the suggestion is only "in the vicinity" or the cursor:

image

In these situations, ctrl+right should have its default behavior of "go to next word".

The current behavior is especially obtrusive because inline completions can appear while you're in the middle of navigating your file. Sometimes I'm moving around, repeatedly pressing ctrl+right to move word by word, when suddenly the cursor stops moving and words get added to my code that I didn't want to add.

Desired behavior

  • Ctrl+Right should only be interpreted as "accept next word" if the cursor is right before part of an inline suggestion. Ctrl+Right should never insert stuff before your cursor, except for paren matching.
  • Ctrl+Right should only work for "insertions" suggestions, not for "replace stuff with other stuff" suggestions. (Wish you guys had documented names for those.)
  • "Insertions" suggestions should not appear after arrow navigation, to avoid the "your cursor is ambushed with new insertions" effect. They should only appear after non-arrow navigation (clicks, "cursor prediction", go-to-symbol, etc) or text insertions. "Replace" suggestions could still appear after arrow navigation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant