1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-03 03:26:45 +02:00

make C-e and C-aa work like they do in bash and fix/format help messages

This commit is contained in:
Jfreegman
2014-02-27 18:55:18 -05:00
parent 6ee1f1ed0f
commit 46b046a209
7 changed files with 40 additions and 38 deletions

View File

@ -173,12 +173,12 @@ static void prompt_onKey(ToxWindow *self, Tox *m, wint_t key)
beep();
}
else if (key == KEY_HOME) { /* HOME key: Move cursor to beginning of line */
else if (key == KEY_HOME || key == T_KEY_C_A) { /* HOME/C-a key: Move cursor to start of line */
if (prt->pos != 0)
prt->pos = 0;
}
else if (key == KEY_END) { /* END key: move cursor to end of line */
else if (key == KEY_END || key == T_KEY_C_E) { /* END/C-e key: move cursor to end of line */
if (prt->pos != prt->len)
prt->pos = prt->len;
}