Skip to content

vte: don't emit double escape for meta+arrow keys - #67

Merged
kdj0c merged 1 commit into
kmscon:mainfrom
perryprog:escape-the-escape
Aug 17, 2026
Merged

vte: don't emit double escape for meta+arrow keys#67
kdj0c merged 1 commit into
kmscon:mainfrom
perryprog:escape-the-escape

Conversation

@perryprog

Copy link
Copy Markdown
Contributor

When we write an arrow key escape sequence with meta as a modifier, TSM_VTE_FLAG_PREPEND_ESCAPE will get set by tsm_vte_handle_keyboard, causing us to write ^[^[[1;3A for meta+up arrow.

Let's just unset that flag since we're always writing an escape character when writing a arrow escape code.

When we write an arrow key escape sequence with meta as a modifier,
TSM_VTE_FLAG_PREPEND_ESCAPE will get set by tsm_vte_handle_keyboard,
causing us to write ^[^[[1;3A for meta+up arrow.

Let's just unset that flag since we're always writing an escape
character when writing a arrow escape code.
@kdj0c

kdj0c commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Yes, that looks good to me.

@kdj0c
kdj0c merged commit 5e8005a into kmscon:main Aug 17, 2026
2 checks passed
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