Do not force SIXEL images to a multiple of 6 lines. From nincsnevem662 at gmail

dot com in GitHub issue 4622.
This commit is contained in:
Nicholas Marriott
2025-09-07 14:55:18 +01:00
parent a7a94cb86f
commit 1dadd6c9ae

View File

@@ -423,8 +423,7 @@ sixel_scale(struct sixel_image *si, u_int xpixel, u_int ypixel, u_int ox,
/*
* We want to get the section of the image at ox,oy in image cells and
* map it onto the same size in terminal cells, remembering that we
* can only draw vertical sections of six pixels.
* map it onto the same size in terminal cells.
*/
sixel_size_in_cells(si, &cx, &cy);
@@ -448,7 +447,7 @@ sixel_scale(struct sixel_image *si, u_int xpixel, u_int ypixel, u_int ox,
psy = sy * si->ypixel;
tsx = sx * xpixel;
tsy = ((sy * ypixel) / 6) * 6;
tsy = sy * ypixel;
new = xcalloc (1, sizeof *si);
new->xpixel = xpixel;