vte: implement basic cursor-movement controls
This adds support for line-feed and carriage-return controls. The two special line-feed controls which are not \n do not take care NL-mode so they must be handled separately. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This commit is contained in:
parent
7c8eb3b108
commit
9b058b1f90
@ -157,13 +157,17 @@ static void parse_control(struct kmscon_vte *vte, uint32_t ctrl)
|
||||
/* Move to next tab stop or end of line */
|
||||
break;
|
||||
case 0x0a: /* LF */
|
||||
case 0x0b: /* VT */
|
||||
case 0x0c: /* FF */
|
||||
/* Line feed or newline (CR/NL mode) */
|
||||
kmscon_console_newline(vte->con);
|
||||
break;
|
||||
case 0x0b: /* VT */
|
||||
case 0x0c: /* FF */
|
||||
/* Line feed */
|
||||
kmscon_console_move_down(vte->con, 1, true);
|
||||
break;
|
||||
case 0x0d: /* CR */
|
||||
/* Move cursor to left margin */
|
||||
kmscon_console_move_line_home(vte->con);
|
||||
break;
|
||||
case 0x0e: /* SO */
|
||||
/* Invoke G1 character set */
|
||||
|
Loading…
x
Reference in New Issue
Block a user