wip: vt parsing

This commit is contained in:
Daniel Eklöf 2019-06-17 18:57:12 +02:00
parent 733223dd0c
commit 6d5f5b9f7a
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
4 changed files with 99 additions and 14 deletions

15
vt.c
View file

@ -160,8 +160,17 @@ action(struct terminal *term, enum action action, uint8_t c)
term->grid.cells[term->grid.cursor].dirty = true;
term->grid.cursor = term->grid.cursor / term->grid.cols * term->grid.cols;
term->grid.cells[term->grid.cursor].dirty = true;
term->grid.dirty = true;
break;
case '\b':
term->grid.cells[term->grid.cursor].dirty = true;
term->grid.cursor--;
term->grid.cells[term->grid.cursor].dirty = true;
term->grid.dirty = true;
break;
}
return true;
case ACTION_CLEAR:
@ -301,8 +310,10 @@ vt_from_slave(struct terminal *term, const uint8_t *data, size_t len)
abort();
if (transition->state != STATE_SAME) {
LOG_DBG("transition: %s -> %s", state_names[current_state],
state_names[transition->state]);
/*
* LOG_DBG("transition: %s -> %s", state_names[current_state],
* state_names[transition->state]);
*/
term->vt.state = transition->state;
enum action entry_action = entry_actions[transition->state];