mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-24 01:40:12 -05:00
vt: implement (untested!) insert mode
\E4l is not horizontal index, but disable INSERT mode
This commit is contained in:
parent
1373d18dbc
commit
90dadfcc22
3 changed files with 20 additions and 9 deletions
16
csi.c
16
csi.c
|
|
@ -484,16 +484,16 @@ csi_dispatch(struct terminal *term, uint8_t final)
|
|||
break;
|
||||
}
|
||||
|
||||
case 'l': {
|
||||
/* Horizontal index */
|
||||
case 'h':
|
||||
/* smir - insert mode enable */
|
||||
assert(false && "untested");
|
||||
int param = param_get(term, 0, 1);
|
||||
int col = term->cursor.col;
|
||||
|
||||
col = (col + param * 8) / 8 * 8;
|
||||
term_cursor_right(term, col - term->cursor.col);
|
||||
term->insert_mode = true;
|
||||
break;
|
||||
|
||||
case 'l':
|
||||
/* rmir - insert mode disable */
|
||||
term->insert_mode = false;
|
||||
break;
|
||||
}
|
||||
|
||||
case 'r': {
|
||||
int start = param_get(term, 0, 1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue