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

switching to visual mode and going down puts the cursor one to the right of where it should be #310

Open
alisonatwork opened this issue Nov 2, 2022 · 0 comments
Labels

Comments

@alisonatwork
Copy link
Collaborator

If you go into visual mode using v, it moves the cursor one to the right to highlight one character of text. This is not the same as vim behavior, but not completely weird given the way selections work in normal GUI apps. What is weird is that if you then go down one line using j, it moves the cursor one more column to the right. And if you go up two lines with kk it the moves the column back to the left again. Alternatively if you start by going up using k, it stays in the correct column, but then when you go down with j it jumps one more column to the right.

There is a bunch of code in the extension that tries to figure out the selection start and end points and will nudge them back or forward one character given some context. I think there is an off-by-one problem in this code, I just haven't had enough time to methodically go through it and figure out where that problem is.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant