Skip to content

Conversation

@tompng
Copy link
Member

@tompng tompng commented Jun 8, 2024

Add SS3 cursor keys to set_default_key_bindings_ansi_cursor

Added \eOA \eOB \eOC \eOD \eOF \eOH (arrow keys, home key, end key for application mode) to default key bindings.
Adding this, we can reduce set_default_key_bindings_comprehensive_list.

We added ANSI CSI cursor keys in #569.
This pull request adds SS3 keys that we forgot to add. https://vt100.net/docs/vt100-ug/chapter3.html#T3-6

Removing \eGA \eGB \eGC \eGD

Removed them because these are not specified in terminfo for any terminal emulator.
I think the bytes [27, 71, 65..68] is a mistake of [27, 79, 65..68]

In KDE source code, arrow keys are CSI + (A|B|C|D) or SS3 + (A|B|C|D)
https://invent.kde.org/utilities/konsole/-/blob/master/data/keyboard-layouts/default.keytab?ref_type=heads#L62-72

@tompng tompng force-pushed the application_key_cursors branch from ca3b3d8 to 3dc856a Compare June 10, 2024 13:59
Copy link
Member

@ima1zumi ima1zumi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@ima1zumi ima1zumi merged commit 546a425 into ruby:master Oct 7, 2024
matzbot pushed a commit to ruby/ruby that referenced this pull request Oct 7, 2024
key bindings
(ruby/reline#719)

* Add SS3 arrow sequence to default key bindings

* Remove wrong KDE arrow sequence

ruby/reline@546a42522e
@tompng tompng deleted the application_key_cursors branch October 7, 2024 04:13
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