mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
vt: DECALN: erase sixels, reset margins, home the cursor
https://vt100.net/docs/vt510-rm/DECALN.html: Notes on DECALN DECALN sets the margins to the extremes of the page, and moves the cursor to the home position.
This commit is contained in:
parent
d6c5bc3262
commit
60c5d889ec
1 changed files with 8 additions and 0 deletions
8
vt.c
8
vt.c
|
|
@ -18,6 +18,7 @@
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
#include "grid.h"
|
#include "grid.h"
|
||||||
#include "osc.h"
|
#include "osc.h"
|
||||||
|
#include "sixel.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
#include "xmalloc.h"
|
#include "xmalloc.h"
|
||||||
|
|
||||||
|
|
@ -561,8 +562,15 @@ action_esc_dispatch(struct terminal *term, uint8_t final)
|
||||||
case '#':
|
case '#':
|
||||||
switch (final) {
|
switch (final) {
|
||||||
case '8': /* DECALN */
|
case '8': /* DECALN */
|
||||||
|
sixel_overwrite_by_rectangle(term, 0, 0, term->rows, term->cols);
|
||||||
|
|
||||||
|
term->scroll_region.start = 0;
|
||||||
|
term->scroll_region.end = term->rows;
|
||||||
|
|
||||||
for (int r = 0; r < term->rows; r++)
|
for (int r = 0; r < term->rows; r++)
|
||||||
term_fill(term, r, 0, 'E', term->cols, false);
|
term_fill(term, r, 0, 'E', term->cols, false);
|
||||||
|
|
||||||
|
term_cursor_home(term);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break; /* private[0] == '#' */
|
break; /* private[0] == '#' */
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue