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

[vi-mode] bug: cursor gets misplaced after delete #10394

Open
johnpyp opened this issue Mar 24, 2024 · 0 comments
Open

[vi-mode] bug: cursor gets misplaced after delete #10394

johnpyp opened this issue Mar 24, 2024 · 0 comments

Comments

@johnpyp
Copy link

johnpyp commented Mar 24, 2024

Fish: version 3.7.1-1593-g5b324f8ec (Notably includes: d51f669, addressing cursor placement issues)
OS: Arch Linux
Term: Kitty

cd ~/Random
# press: `esc v b d` to delete `Random`
cd ~/[CURSOR] # this is incorrect, cursor should be on the slash
# press: `a` to attempt to enter insert mode after the current cursor
cd ~/b # example of b is the first character of the insert

This example uses visual mode d to delete some words, moving the cursor backwards, then a to try to move into insert mode, which causes two issues:

  1. The cursor is misplaced (should be at the slash, in accordance with real vim)
  2. The first character of completion gets inserted incorrectly.

I believe the actual issue here is the placement of the cursor the wrong place after the delete, similar to other issues d51f669 has fixed. Because of this, the a is considered used to take the autocomplete character.

If you move the cursor back to the slash correctly first, then press a, this behavior doesn't occur - but I'm not sure if just doing so would fully fix the issue, because moving the cursor like that also removes the autocomplete suggestion.

@johnpyp johnpyp changed the title [vi-mode] bug: cursor or normal mode is misplaced/misbehaving after deleting [vi-mode] bug: cursor gets misplaced after delete Mar 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants