sixel: add sixel_split_by_rectangle()

This function splits a sixel image into up to four pieces. The four
pieces correspond to the relative complement (set difference) of the
sixel image and the specified rectangle.

Use this function when (possibly) overwriting existing sixel images
when generating a new one, i.e. in sixel_unhook().
This commit is contained in:
Daniel Eklöf 2020-06-27 12:45:22 +02:00
parent f4fcdbf38b
commit dfc205e706
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
2 changed files with 74 additions and 58 deletions

View file

@ -14,7 +14,6 @@ void sixel_destroy(struct sixel *sixel);
void sixel_delete_in_range(struct terminal *term, int start, int end);
void sixel_delete_at_row(struct terminal *term, int _row);
void sixel_delete_at_cursor(struct terminal *term);
void sixel_split_at_cursor(struct terminal *term);
void sixel_colors_report_current(struct terminal *term);