Place home and end before insert and delete.
These keys have different sequences when using cursorkeys, while insert and delete stay the same. If they are placed like this, libteken will return NULL instead of a proper sequence for these characters.
This commit is contained in:
parent
c8f1c81702
commit
d80a1e6c1b
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=199175
@ -484,8 +484,8 @@ static const char * const special_strings_cons25[] = {
|
|||||||
[TKEY_UP] = "\x1B[A", [TKEY_DOWN] = "\x1B[B",
|
[TKEY_UP] = "\x1B[A", [TKEY_DOWN] = "\x1B[B",
|
||||||
[TKEY_LEFT] = "\x1B[D", [TKEY_RIGHT] = "\x1B[C",
|
[TKEY_LEFT] = "\x1B[D", [TKEY_RIGHT] = "\x1B[C",
|
||||||
|
|
||||||
[TKEY_INSERT] = "\x1B[L", [TKEY_DELETE] = "\x7F",
|
|
||||||
[TKEY_HOME] = "\x1B[H", [TKEY_END] = "\x1B[F",
|
[TKEY_HOME] = "\x1B[H", [TKEY_END] = "\x1B[F",
|
||||||
|
[TKEY_INSERT] = "\x1B[L", [TKEY_DELETE] = "\x7F",
|
||||||
[TKEY_PAGE_UP] = "\x1B[I", [TKEY_PAGE_DOWN] = "\x1B[G",
|
[TKEY_PAGE_UP] = "\x1B[I", [TKEY_PAGE_DOWN] = "\x1B[G",
|
||||||
|
|
||||||
[TKEY_F1] = "\x1B[M", [TKEY_F2] = "\x1B[N",
|
[TKEY_F1] = "\x1B[M", [TKEY_F2] = "\x1B[N",
|
||||||
@ -507,8 +507,8 @@ static const char * const special_strings_normal[] = {
|
|||||||
[TKEY_UP] = "\x1B[A", [TKEY_DOWN] = "\x1B[B",
|
[TKEY_UP] = "\x1B[A", [TKEY_DOWN] = "\x1B[B",
|
||||||
[TKEY_LEFT] = "\x1B[D", [TKEY_RIGHT] = "\x1B[C",
|
[TKEY_LEFT] = "\x1B[D", [TKEY_RIGHT] = "\x1B[C",
|
||||||
|
|
||||||
[TKEY_INSERT] = "\x1B[2~", [TKEY_DELETE] = "\x1B[3~",
|
|
||||||
[TKEY_HOME] = "\x1B[H", [TKEY_END] = "\x1B[F",
|
[TKEY_HOME] = "\x1B[H", [TKEY_END] = "\x1B[F",
|
||||||
|
[TKEY_INSERT] = "\x1B[2~", [TKEY_DELETE] = "\x1B[3~",
|
||||||
[TKEY_PAGE_UP] = "\x1B[5~", [TKEY_PAGE_DOWN] = "\x1B[6~",
|
[TKEY_PAGE_UP] = "\x1B[5~", [TKEY_PAGE_DOWN] = "\x1B[6~",
|
||||||
|
|
||||||
[TKEY_F1] = "\x1BOP", [TKEY_F2] = "\x1BOQ",
|
[TKEY_F1] = "\x1BOP", [TKEY_F2] = "\x1BOQ",
|
||||||
|
@ -173,10 +173,10 @@ void teken_set_winsize(teken_t *, const teken_pos_t *);
|
|||||||
#define TKEY_LEFT 0x02
|
#define TKEY_LEFT 0x02
|
||||||
#define TKEY_RIGHT 0x03
|
#define TKEY_RIGHT 0x03
|
||||||
|
|
||||||
#define TKEY_INSERT 0x04
|
#define TKEY_HOME 0x04
|
||||||
#define TKEY_DELETE 0x05
|
#define TKEY_END 0x05
|
||||||
#define TKEY_HOME 0x06
|
#define TKEY_INSERT 0x06
|
||||||
#define TKEY_END 0x07
|
#define TKEY_DELETE 0x07
|
||||||
#define TKEY_PAGE_UP 0x08
|
#define TKEY_PAGE_UP 0x08
|
||||||
#define TKEY_PAGE_DOWN 0x09
|
#define TKEY_PAGE_DOWN 0x09
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user