diff options
author | David Herrmann <dh.herrmann@googlemail.com> | 2012-02-05 15:52:34 +0100 |
---|---|---|
committer | David Herrmann <dh.herrmann@googlemail.com> | 2012-02-05 15:52:34 +0100 |
commit | a5a357e012d175397c028606e48cc9c579b5c1dc (patch) | |
tree | 2c240f98aa819fb42c0fa7f67599f3911d6a2277 /src | |
parent | 9b058b1f9040fae51102b18a3c2f13f08c8df8a0 (diff) |
vte: implement CSI-K
The K CSI is used to erase parts of the current line.
Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/vte.c | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -237,6 +237,15 @@ static void parse_csi(struct kmscon_vte *vte, uint32_t val) vte->parser.state = STATE_NORMAL; switch (val) { + case 'K': + if (vte->parser.csi_argc < 1 || + vte->parser.csi_argv[0] == 0) + kmscon_console_erase_cursor_to_end(vte->con); + else if (vte->parser.csi_argv[0] == 1) + kmscon_console_erase_home_to_cursor(vte->con); + else if (vte->parser.csi_argv[0] == 2) + kmscon_console_erase_current_line(vte->con); + break; default: log_debug("vte: unhandled CSI sequence\n"); } |