vt: implement SI/SO (shift in, shift out)

This enables switching between the G0 and G1 charsets.
This commit is contained in:
Daniel Eklöf 2019-07-15 12:04:40 +02:00
parent 6077b57ca5
commit 6ac115bffd
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

10
vt.c
View file

@ -810,6 +810,16 @@ action(struct terminal *term, enum action _action, uint8_t c)
break;
}
case '\016':
/* SO - shift out */
term->selected_charset = 1; /* G1 */
break;
case '\017':
/* SI - shift in */
term->selected_charset = 0; /* G0 */
break;
default:
LOG_ERR("execute: unimplemented: %c (0x%02x)", c, c);
abort();