Skip to content

Add support for PuTTY ALT+arrow key sequences#532

Open
tobwen wants to merge 1 commit intoanomalyco:mainfrom
tobwen:fix/putty-escape-sequence
Open

Add support for PuTTY ALT+arrow key sequences#532
tobwen wants to merge 1 commit intoanomalyco:mainfrom
tobwen:fix/putty-escape-sequence

Conversation

@tobwen
Copy link

@tobwen tobwen commented Jan 16, 2026

Adds recognition for double ESC sequences generated by PuTTY terminal when ALT+arrow keys are pressed (format: ESC ESC [A-D).

Updates the keypress parser to properly identify these sequences and mark them with meta/option flags while ensuring regular arrow keys still work correctly.

Enhances terminal compatibility for users of PuTTY in default mode.

Adds recognition for double ESC sequences generated by PuTTY terminal
when ALT+arrow keys are pressed (format: ESC ESC [A-D).

Updates the keypress parser to properly identify these sequences and
mark them with meta/option flags while ensuring regular arrow keys
still work correctly.

Enhances terminal compatibility for users of PuTTY in default mode.
@kommander
Copy link
Collaborator

This only tests parseKeypress, but does the stdin-buffer handle doubled escapes?

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

Successfully merging this pull request may close these issues.

2 participants