mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-03-10 05:33:51 -04:00
sixel: limit image size to the one specified in the raster attrs
If a sixel has set an explicit width/height, in its raster attributes, do *not* allow the image to extend beyond this. Before this patch, we dynamically resized images if the sixel encoder emitted sixel data beyond the previously set width/height. Now, we ignore writes outside the configured size.
This commit is contained in:
parent
f17b989650
commit
f7bdc4c5b4
3 changed files with 18 additions and 1 deletions
|
|
@ -677,6 +677,7 @@ struct terminal {
|
|||
uint32_t *p; /* Pointer into data, for current position */
|
||||
int width; /* Image width, in pixels */
|
||||
int height; /* Image height, in pixels */
|
||||
int alloc_height; /* Image height, in pixels, aligned to 6-pixel boundary */
|
||||
} image;
|
||||
|
||||
/*
|
||||
|
|
@ -687,6 +688,7 @@ struct terminal {
|
|||
*/
|
||||
int pan;
|
||||
int pad;
|
||||
bool size_locked;
|
||||
|
||||
bool scrolling:1; /* Private mode 80 */
|
||||
bool use_private_palette:1; /* Private mode 1070 */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue