Skip to content
This repository has been archived by the owner on Aug 23, 2023. It is now read-only.

waiting with [5] doesn't work w/o NumLock #24

Open
kilobyte opened this issue Sep 22, 2018 · 2 comments
Open

waiting with [5] doesn't work w/o NumLock #24

kilobyte opened this issue Sep 22, 2018 · 2 comments

Comments

@kilobyte
Copy link
Contributor

I'm afraid the fix for #18 is incomplete: if you press [5], you get:

Unknown key ' '. Type ? for help. Unknown key 'O'. Type ? for help. Unknown key 'E'. Type ? for help.

@anaseto
Copy link
Owner

anaseto commented Sep 22, 2018

Indeed, I could not implement waiting with 5 w/o numlock: with the tcell backend I wrongly get the code of 'O' for the key, and termbox doesn't even seem to have a predefined constant for that key, so I'm unsure what to do about it, as it seems this key is not handled by the backends. Waiting is still possible by typing dot. I could make the keypad dot key (supr) work too.

@kilobyte
Copy link
Contributor Author

I see what's going on: both current libvte and current xterm changed their code to middle arrow to "\e[E" — it used to be "\e[G" in cursor mode and "\eOu" (no '[') in application mode. I'm not sure where the O comes from, but it's possible that whatever mode your library sets the terminal to returns "\e[OE", per analogy with other arrows.

So the library would need to handle all four of these sequences.

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

No branches or pull requests

2 participants