fix(options/pdftops)!: use camelcase for optimizecolorspace (#773)

* fix(options/pdftops)!: use camelcase for `optimizecolorspace`

BREAKING CHANGE: `optimizecolorspace` renamed to `optimizeColorSpace` for pdfToPs function

* fix(options/pdftops): add minversion

* fix: minversion for rasterize
This commit is contained in:
Frazer Smith
2026-05-13 15:15:57 +01:00
committed by GitHub
parent 59647cec3a
commit a8635dd4d3
+4 -3
View File
@@ -64,7 +64,7 @@
* @property {boolean} [noShrink] Do not scale PDF pages which are larger than the paper.
* By default, pages larger than the paper are shrunk to fit.
* @property {boolean} [opi] Generate OPI comments for all images and forms which have OPI information.
* @property {boolean} [optimizecolorspace] By default, bitmap images in the PDF pass through to the
* @property {boolean} [optimizeColorSpace] By default, bitmap images in the PDF pass through to the
* output PostScript in their original color space, which produces predictable results.
* This option converts RGB and CMYK images into Gray images if every pixel of the image has equal components.
* This can fix problems when doing color separations of PDFs that contain embedded black and
@@ -156,9 +156,10 @@ module.exports = {
},
noShrink: { arg: "-noshrink", type: "boolean" },
opi: { arg: "-opi", type: "boolean" },
optimizecolorspace: {
optimizeColorSpace: {
arg: "-optimizecolorspace",
type: "boolean",
minVersion: "0.32.0",
},
originalPageSizes: {
arg: "-origpagesizes",
@@ -184,7 +185,7 @@ module.exports = {
rasterize: {
arg: "-rasterize",
type: "string",
minVersion: "0.90.0",
minVersion: "0.32.0",
},
resolutionXYAxis: { arg: "-r", type: "number" },
userPassword: { arg: "-upw", type: "string" },