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

Arrow keys have long delay in REPL #91

Open
aplund opened this issue Nov 21, 2023 · 1 comment
Open

Arrow keys have long delay in REPL #91

aplund opened this issue Nov 21, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@aplund
Copy link

aplund commented Nov 21, 2023

In the REPL, moving along a line in normal mode using 'h' and 'l' seem to work great. But moving along the line using the arrow keys seems to result in long delays if held down for a repeat.

Using the debugging messages, I can see that the two movement methods have different code paths. The arrow keys generate "\e[C" and "\e[D" going through the "encoded sequence" path. Where as the 'h' and 'l' go through the motion commands.

@caleb-allen caleb-allen added the bug Something isn't working label Nov 21, 2023
@caleb-allen
Copy link
Owner

Interesting, thank you for filing the issue.

My guess is that the left and right keys use the encoded sequence, and VimBindings has some timing logic which causes a slight delay to detect which key was pressed. This isn't noticed with one key press, but then when the keys are held down it might result in longer delays.

I am a bit short on time at the moment, but I'll prioritize this in the next release, whenever that may be.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants