]> git.ipfire.org Git - thirdparty/cups-filters.git/commit
libcupsfilters: Let imageto...() with print-scaling=none center correctly
authorTill Kamppeter <till.kamppeter@gmail.com>
Thu, 17 Feb 2022 13:41:39 +0000 (14:41 +0100)
committerTill Kamppeter <till.kamppeter@gmail.com>
Thu, 17 Feb 2022 13:41:39 +0000 (14:41 +0100)
commit0a1c76fc384615c8d22c171666a3157295bb789c
treecda8c4ebf3ab2298d59a57e6f08ed305d470beac
parent7cf3739186d72976947454668a823eb115addde7
libcupsfilters: Let imageto...() with print-scaling=none center correctly

In the imageto...() filter functions with print-scaling=none do the
math for centering the image on the page without the unprintable
margins, so that the image gets correctly centered relative to the
page, not to the printable area of the page.

As in imagetoraster we have to pass on a bitmap of the printable area
for CUPS Raster. we correct for the margins after calculating image
size and position without margins.
cupsfilters/imagetopdf.c
cupsfilters/imagetops.c
cupsfilters/imagetoraster.c