Clear graphics when switching to the alternate screen buffer
This commit is contained in:
parent
600bff73d6
commit
480645877a
@ -266,3 +266,14 @@ take, and the default value they take when missing. All integers are 32-bit.
|
|||||||
| `r` | Positive integer | `0` | The number of rows to display the image over
|
| `r` | Positive integer | `0` | The number of rows to display the image over
|
||||||
| `z` | Integer | `0` | The *z-index* vertical stacking order of the image
|
| `z` | Integer | `0` | The *z-index* vertical stacking order of the image
|
||||||
|===
|
|===
|
||||||
|
|
||||||
|
|
||||||
|
== Interaction with screen changes
|
||||||
|
|
||||||
|
When resetting the screen, all images that are visible on the screen must be
|
||||||
|
cleared. When switching from the main screen to the alternate screen buffer
|
||||||
|
(1049 private mode) all images in the alternate screen must be cleared, just as
|
||||||
|
all text is cleared.
|
||||||
|
|
||||||
|
The commands to clear the screen and erase text must have no effect on
|
||||||
|
graphics. The dedicated delete graphics commands must be used for those.
|
||||||
|
|||||||
@ -436,6 +436,7 @@ screen_toggle_screen_buffer(Screen *self) {
|
|||||||
bool to_alt = self->linebuf == self->main_linebuf;
|
bool to_alt = self->linebuf == self->main_linebuf;
|
||||||
if (to_alt) {
|
if (to_alt) {
|
||||||
linebuf_clear(self->alt_linebuf, BLANK_CHAR);
|
linebuf_clear(self->alt_linebuf, BLANK_CHAR);
|
||||||
|
grman_clear(self->alt_grman);
|
||||||
screen_save_cursor(self);
|
screen_save_cursor(self);
|
||||||
self->linebuf = self->alt_linebuf;
|
self->linebuf = self->alt_linebuf;
|
||||||
self->tabstops = self->alt_tabstops;
|
self->tabstops = self->alt_tabstops;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user