Print Production
Print Production
5
Setting Font Options
You can control the font policy by setting the
printParams
object’s
fontPolicy
property. There are three values that may be used:
●
everyPage
: emit needed fonts for every page, freeing fonts from the previous page.
This is useful for printers having a small amount of memory.
●
jobStart
: emit all fonts at the beginning of the print job, free them at the end of the
print job. This is useful for printers having a large amount of memory.
●
pageRange
: emit the fonts needed for a given range of pages, free them once those
pages are printed. This may be used to optimize the balance between memory and
speed constraints.
In the following example, all the fonts are emitted at the beginning of the print job, and
freed once the job is finished:
var pp = this.getPrintParams();
pp.fontPolicy = pp.constants.fontPolicy.jobStart;
this.print(pp);
You may also control whether Type 1 fonts will be converted to alternative font
representations, by setting the
printParams
object’s
useT1Conversion
property.
There are three values that may be used:
●
auto
: let Acrobat decide whether to disable the conversion, based on its internal list of
printers that have problems with these fonts.
●
●
use
: allow conversion of Type 1 fonts.
noUse
: do not allow conversion of Type 1 fonts.
In the following example, conversion of Type 1 fonts is set to automatic:
var pp = this.getPrintParams();
pp.useT1Conversion = pp.usages.useT1Conversion.auto;
this.print(pp);
Finally, it is possible to send Far East fonts to the printer by setting the
printParams
object’s
downloadFarEastFonts
property to
true
.
Acrobat JavaScript Scripting Guide
83