mirror of
https://github.com/tmux/tmux.git
synced 2024-11-18 02:18:53 +00:00
Escape+Up and the other arrow keys should be kept as Escape+Up and not
converted to M-Up. Do not give them the implied meta flag so they don't match the M-Up entry in the output key tree. Fixes problem with vi reported by jsing@.
This commit is contained in:
parent
f70eda3817
commit
68c2d5c48d
23
tty-keys.c
23
tty-keys.c
@ -95,20 +95,25 @@ static const struct tty_default_key_raw tty_default_raw_keys[] = {
|
|||||||
{ "\033OC", KEYC_RIGHT|KEYC_CURSOR },
|
{ "\033OC", KEYC_RIGHT|KEYC_CURSOR },
|
||||||
{ "\033OD", KEYC_LEFT|KEYC_CURSOR },
|
{ "\033OD", KEYC_LEFT|KEYC_CURSOR },
|
||||||
|
|
||||||
{ "\033\033OA", KEYC_UP|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
|
||||||
{ "\033\033OB", KEYC_DOWN|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
|
||||||
{ "\033\033OC", KEYC_RIGHT|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
|
||||||
{ "\033\033OD", KEYC_LEFT|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
|
||||||
|
|
||||||
{ "\033[A", KEYC_UP|KEYC_CURSOR },
|
{ "\033[A", KEYC_UP|KEYC_CURSOR },
|
||||||
{ "\033[B", KEYC_DOWN|KEYC_CURSOR },
|
{ "\033[B", KEYC_DOWN|KEYC_CURSOR },
|
||||||
{ "\033[C", KEYC_RIGHT|KEYC_CURSOR },
|
{ "\033[C", KEYC_RIGHT|KEYC_CURSOR },
|
||||||
{ "\033[D", KEYC_LEFT|KEYC_CURSOR },
|
{ "\033[D", KEYC_LEFT|KEYC_CURSOR },
|
||||||
|
|
||||||
{ "\033\033[A", KEYC_UP|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
/*
|
||||||
{ "\033\033[B", KEYC_DOWN|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
* Meta arrow keys. These do not get the IMPLIED_META flag so they
|
||||||
{ "\033\033[C", KEYC_RIGHT|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
* don't match the xterm-style meta keys in the output tree - Escape+Up
|
||||||
{ "\033\033[D", KEYC_LEFT|KEYC_CURSOR|KEYC_META|KEYC_IMPLIED_META },
|
* should stay as Escape+Up and not become M-Up.
|
||||||
|
*/
|
||||||
|
{ "\033\033OA", KEYC_UP|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033OB", KEYC_DOWN|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033OC", KEYC_RIGHT|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033OD", KEYC_LEFT|KEYC_CURSOR|KEYC_META },
|
||||||
|
|
||||||
|
{ "\033\033[A", KEYC_UP|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033[B", KEYC_DOWN|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033[C", KEYC_RIGHT|KEYC_CURSOR|KEYC_META },
|
||||||
|
{ "\033\033[D", KEYC_LEFT|KEYC_CURSOR|KEYC_META },
|
||||||
|
|
||||||
/* Other (xterm) "cursor" keys. */
|
/* Other (xterm) "cursor" keys. */
|
||||||
{ "\033OH", KEYC_HOME },
|
{ "\033OH", KEYC_HOME },
|
||||||
|
Loading…
Reference in New Issue
Block a user