Page tree
Skip to end of metadata
Go to start of metadata

Parameters

Mako supports methods to control the way in which an output file is produced. These can be set in code using setParameter() with two strings. For example, to specify a target colorspace one could use:

Setting an output parameter with strings
IPDFOutputPtr output = IPDFOutput::create(jawsMako);
output->setParameter("TargetColorSpace", "DeviceCMYK");

This method supports scenarios where it is necessary to set an output parameter at runtime, and is exploited by the sample makoconverter, which allows you to experiment with these parameters by adding them to the command line: For example:

makoconverter MyInput.pdf MyOutput.ps TargetColorSpace=DeviceGray ConvertAllObjectsToTargetColorSpace=true

The various output classes that Mako supports offer their own set of output parameters, and are described on the pages in this section.

Presets

Presets 'roll up' several parameters to be set together. They are a useful shortcut, particularly for PDF standards such as PDF/X or PDF/A as they guarantee a compliant file, content permitting. They work in a similar way to parameters - see Output presets (PDF) for details.


  • No labels