|
|
|
6.0 |
|
|
|
true if a binary channel to the printer is supported. The default is true.
Boolean
R/W
The dots per inch (DPI) to use when producing bitmaps or rasterizing transparency. The valid range is 1 to 9600. If the document protections specify a maximum printing resolution, the lower of the two values is used. The default is 300. Illegal values are treated as 300. See also gradientDPI.
Integer
R/W
|
8.0 |
|
|
|
An object used to set the parameters for booklet printing. The properties of the booklet object are listed in the table below.
|
Property |
Type |
Access |
Description |
|---|---|---|---|
|
binding |
Integer |
R/W |
When printing a booklet, the binding property determines the paper binding direction and the page arrange order. The value of binding is set through the constants bookletBindings object, given below. The default is Left. |
|
duplexMode |
Integer |
R/W |
When printing a booklet, the duplexMode property determines the duplex printing mode. The value of duplexMode property is set through the constants duplexMode object, given below. The default is BothSides. When the output device doesn't support automatic duplex functionality, a manual duplex can be performed by two separated printings of front and back sides. |
|
subsetFrom |
Integer |
R/W |
When printing a booklet, subsetFrom determines the first booklet sheet to be printed. Independently from the general page range selection, only a subset of the final booklet result is printed by this option. Valid sheet numbers start from 0, which is the first sheet. The default value is 0. The special value of -1 represents the last sheet. More generally, the negative integer -N represents the sheet that is (N-1) from the last sheet. Thus, -2 is the sheet just before the last sheet, -3 is the sheet that is 2 sheets from the last one. See the additional note below on booklet subsetting. |
|
subsetTo |
Integer |
R/W |
When printing a booklet, subsetTo determines the last booklet sheet to be printed. Independently from the general page range selection, only a subset of the final booklet result is printed by this option. Valid sheet numbers start from 0, but the value -1 represents the last sheet. The default value is -1. The negative integer -N represents the sheet that is (N-1) from the last sheet. Thus, -2 is the sheet just before the last sheet, -3 is the sheet that is 2 sheets from the last one. See the additional note below on booklet subsetting. |
The bookletBindings object has properties used to set the value of booklet.binding.
|
Property |
Description |
|---|---|
|
Left |
Left-side binding for Western-style left-to-right reading direction. The paper is folded on the short side. |
|
Right |
Right-side binding for text with right-to-left reading direction or Japanese-style vertical writing. The paper is folded on the short side. |
|
LeftTall |
Left-side binding for Western-style left-to-right reading direction. The paper is folded on the long side producing long and narrow pages. |
|
RightTall |
Right-side binding for text with right-to-left reading direction or Japanese-style vertical writing. The paper is folded on the long side producing long and narrow pages. |
The bookletDuplexModes object has properties used to set the value of booklet.duplexMode.
|
Property |
Description |
|---|---|
|
BothSides |
Automatically prints both sides of the paper. The selected printer must support automatic duplex printing. |
|
FrontSideOnly |
Only prints all pages that appear on the front side of the paper. Reinsert the printed pages and print again with BacksideOnly mode to complete a manual duplex printing. |
|
BackSideOnly |
Only prints all pages that appear on the back side of the paper. |
object
R/W
Note:(Booklet subsetting using subsetFrom and subsetTo) Since the booklet output can change by the source page range (by setting firstPage and lastPage properties of the PrintParams object), the same effect cannot be achieved easily by changing these page range properties. For example. the first (2-side) sheet of an 8-page booklet job has a page number sequence of [8, 1, 2, 7] while the first sheet of 16-page booklet job has a page number sequence of [16, 1, 2, 15]. The subsetFrom and subsetTo properties are useful for printing certain pages of a booklet document with different devices or media. A typical example would be printing the cover and the inside cover in color while rest of the document is in black and white. Another common example is printing the cover page on thicker colored paper.
Set up booklet printing for right-side binding of text, and print.
var pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.booklet;
pp.booklet.binding = pp.constants.bookletBindings.Right;
this.print(pp);
Print booklet in duplex mode, printing only the front pages.
var pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.booklet;
pp.booklet.duplexMode = pp.constants.bookletDuplexModes.FrontSideOnly;
this.print(pp);
Set up booklet printing to print the second sheet only and print.
var pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.booklet;
pp.booklet.subsetFrom = 1;
pp.booklet.subsetTo = 1;
this.print(pp);
Set booklet printing from the second sheet to the last sheet.
pp.booklet.subsetFrom = 1;
pp.booklet.subsetTo = -1;
Set booklet printing to print last sheet only.
pp.booklet.subsetFrom = -1;
pp.booklet.subsetTo = -1;
Set booklet printing to print last sheet two sheets.
pp.booklet.subsetFrom = -2;
pp.booklet.subsetTo = -1;
Set booklet printing to print all pages except the last two.
pp.booklet.subsetFrom = 0;
pp.booklet.subsetTo = -3;
The color profile to use. A list of available color spaces can be obtained from printColorProfiles. The default is “Printer/PostScript Color Management”.
String
R/W
|
6.0 |
|
|
|
Each instance of a PrintParams object inherits this property, which is a wrapper that holds various constant values. The values are all integers allowing read access only. They are used as option values of some of the other properties of the PrintParams object, and their values are listed with the properties to which they apply.
|
Constant object |
Contains constant values for this property |
|---|---|
|
bookletBindings |
|
|
bookletDuplexModes |
|
|
duplexTypes |
|
|
fontPolicies |
|
|
handling |
|
|
interactionLevel |
|
|
nUpPageOrders |
|
|
printContents |
|
|
flagValues |
|
|
rasterFlagValues |
|
|
subsets |
|
|
tileMarks |
|
|
usages |
object
R
|
6.0 |
|
|
|
If true (the default), send Far East fonts to the printer if needed. Set this property to false if the printer has Far East fonts but incorrectly reports that it needs them.
Boolean
R/W
|
8.0 |
|
|
|
Sets the printing duplex mode to simplex, duplex long edge, or duplex short edge feed. This property appears as DuplexMode under the Advanced tab of the Document Properties dialog box.
The duplex options are accessed through the constants.duplexType object. The properties of this object are listed in the table that follows.
|
Property |
Description |
|---|---|
|
Simplex |
Prints on one side of the paper. |
|
DuplexFlipLongEdge |
Prints on both sides of the paper; the paper flips along the long edge. |
|
DuplexFlipShortEdge |
Prints on both sides of the paper; the paper flips along the short edge. |
The selected printer should support duplex printing, if either DuplexFlipLongEdge or DuplexFlipShortEdge is used.
Integer
R/W
Set printing to duplex short edge feed and print.
var pp = this.getPrintParams();
pp.DuplexType = pp.constants.duplexTypes.DuplexFlipShortEdge;
this.print(pp);
|
6.0 |
|
|
|
The device-independent path for a file name to be used instead of sending the print job to the printer (Print to File). The path may be relative to the location of the current document. When printing to a file, if the interaction level (see interactive) is set to full, it is lowered to automatic.
The default value is the empty string (no file name).
Note:Printing to a file produces output suitable for the printer, for example, Postscript or GDI commands.
When printerName is an empty string andfileName is specified, the current document is saved as a PostScript file.
String
R/W
var pp = this.getPrintParams();
pp.fileName = "/c/print/myDoc.prn";
this.print(pp);
Save the current document as a PostScript file.
var pp = this.getPrintParams();
pp.fileName = "/c/temp/myDoc.ps";
pp.printerName = "";
this.print(pp);
|
6.0 |
|
|
|
The first page number of the document to print. The number is 0-based. The first page of any document is 0, regardless of page number labels. The default value is 0, and values that are out of the document’s page range are treated as 0.
See also lastPage.
Integer
R/W
var pp = this.getPrintParams();
pp.firstPage = 0;
pp.lastPage = 9;
this.print(pp);
|
6.0 |
|
|
|
A bit field of flags to control printing. These flags can be set or cleared using bitwise operations through the constants flagValues object.
Zero or more flags can be set; unsupported flags are ignored. The flags default to those set by user preferences.
The table below lists the properties of the flagValues object; unless otherwise noted, these properties are not available in
|
Property |
Description |
|---|---|
|
applyOverPrint |
Do overprint preview when printing. Turn off if overprinting is natively supported. |
|
applySoftProofSettings |
Use the soft proofing settings before doing color management. |
|
applyWorkingColorSpaces |
Apply working color spaces when printing. |
|
emitHalftones |
Emit the halftones specified in the document. |
|
emitPostScriptXObjects |
PostScript only, do include PostScript XObjects’ content in output. |
|
emitFormsAsPSForms |
Converts Form XObjects to PS forms. The default is off. |
|
maxJP2KRes |
Use the maximum resolution of JPeg2000 images instead of the best matching resolution. |
|
setPageSize |
Enable setPageSize. Choose the paper tray by the PDF page size. Available in |
|
suppressBG |
Do not emit the BlackGeneration in the document. |
|
suppressCenter |
Do not center the page. Available in |
|
suppressCJKFontSubst |
Suppress CJK Font Substitution on Printer—does not apply when kAVEmitFontAllFonts is used. |
|
suppressCropClip |
Do not emit the cropbox page clip. Available in |
|
suppressRotate |
Do not rotate the page. Available in |
|
suppressTransfer |
Do not emit the transfer functions in the document. |
|
suppressUCR |
Do not emit UnderColorRemovals in the document. |
|
useTrapAnnots |
Print TrapNet and PrinterMark annotations, even if the print setting is “document only”. |
|
usePrintersMarks |
Print PrinterMark annotations, even if the print setting is “document only”. Available in |
Integer
R/W
In the Output options section of the Advanced Print Setup dialog box, check the Apply Output Preview Settings check box.
pp = getPrintParams();
fv = pp.constants.flagValues;
// or pp.flags |= fv.applySoftProofSettings;;
pp.flags = pp.flags | fv.applySoftProofSettings;
this.print(pp);
Uncheck Auto-Rotate and Center (checked by default) in the Print dialog box.
pp = getPrintParams();
fv = pp.constants.flagValues;
pp.flags |= (fv.suppressCenter | fv.suppressRotate);
this.print(pp);
In the PostScript options section of the Advanced Print Setup dialog box, check the Emit Undercolor Removal/Black Generation check box.
pp = getPrintParams();
fv = pp.constants.flagValues;
pp.flags &= ~(fv.suppressBG | fv.suppressUCR)
this.print(pp)
|
6.0 |
|
|
|
Sets the font policy. The value of the fontpolicy property is set through the constants fontPolicies object. The default is pageRange.
Integer
R/W
|
Property |
Description |
|---|---|
|
everyPage |
Emit needed fonts before every page and free all fonts after each page. This produces the largest, slowest print jobs, but requires the least amount of memory from the printer. |
|
jobStart |
Emit needed fonts at the beginning of the print job and free them at the end of the print job. This produces the smallest, fastest print jobs, but requires the most memory from the printer. |
|
pageRange |
(Default) Emit fonts before the first page that uses them and free them after the last page that uses them. This also produces the smallest and fastest print jobs and can use less memory. However, the print job must be printed as produced because of page ordering. Note:pageRange can be a good compromise between speed and memory. However, do not use it if the PostScriptcript pages will be programmatically reordered afterwards. |
The dots per inch to use when rasterizing gradients. This value can generally be set lower than bitmapDPI because it affects areas to which the eye is less sensitive. It must be set from 1 to 9600. Illegal values are treated as 150. If the document protections specify a maximum printing resolution, the lower of the two values will be used. The default value is 150.
Integer
R/W
|
6.0 |
|
|
|
Specifies the level of interaction between the user and the print job. The value of this property is set through the constants interactionLevel object. The default is full.
Note:(
var pp = this.getPrintParams();
pp.interactive = pp.constants.interactionLevel.silent;
Outside of batch, console, and menu events, the values of bUI and of interactive are ignored, and a print dialog box will always be presented.
See also Privileged versus non-privileged context.
Integer
R/W
|
Property |
Description |
|---|---|
|
automatic |
No print dialog box is displayed. During printing, a progress monitor and cancel dialog box are displayed and removed automatically when printing is complete. |
|
full |
Displays the print dialog box, allowing the user to change print settings and requiring the user to press OK to continue. During printing, a progress monitor and cancel dialog box is displayed and removed automatically when printing is complete. |
|
silent |
No print dialog box is displayed. No progress or cancel dialog box is displayed. Even error messages are not displayed. |
var pp = this.getPrintParams();
pp.interactive = pp.constants.interactionLevel.automatic;
pp.printerName = "Adobe PDF";
this.print(pp);
|
6.0 |
|
|
|
The last 0-based page number of the document to print. The term “0-based” means the first page of any document is 0, regardless of page number labels. If the value is less than firstPage or outside the legal range of the document, this reverts to the default value. The default value is the number of pages in the document less one.
See firstPage for an example.
Integer
R/W
|
7.0 |
|
|
|
A Boolean value that if true, automatically rotates each page to match the page orientation to the available paper area during Multiple Pages Per Sheet printing. The default is false, but nUpAutoRotate obeys the print settings.
Multiple Pages Per Sheet is obtained by setting pageHandling to nUp.
Boolean
R/W
|
7.0 |
|
|
|
The number of pages to lay out in the horizontal direction when printing Multiple Pages Per Sheet. The default is 2, but nUpNumPagesH obeys the print settings.
Multiple Pages Per Sheet is obtained by setting pageHandling to nUp.
Integer
R/W
Perform Multiple Pages Per Sheet printing on this document, set up parameters, and print.
pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.nUp;
pp.nUpPageOrders = pp.constants.nUpPageOrders.Vertical;
pp.nUpNumPagesH = 3;
pp.nUpNumPagesV = 3;
pp.nUpPageBorder=true;
pp.nUpAutoRotate=true;
this.print(pp);
|
7.0 |
|
|
|
The number of pages to be laid out in the vertical direction when printing Multiple Pages Per Sheet. The default is 2, but nUpNumPagesV obeys the print settings.
Multiple Pages Per Sheet is obtained by setting pageHandling to nUp.
See nUpNumPagesH for an example.
Integer
R/W
|
7.0 |
|
|
|
A Boolean value that if true, draws and prints a page boundary around each of the pages during Multiple Pages Per Sheet printing. The default is false, but nUpPageBorder obeys the print settings.
Multiple Pages Per Sheet is obtained by setting pageHandling to nUp.
See nUpNumPagesH for an example.
Boolean
R/W
|
7.0 |
|
|
|
When printing multiple pages per sheet, the nUpPageOrder property determines how the multiple pages are laid out on the sheet. The value of the nUpPageOrder property is set through the constants nUpPageOrders object. The default is Horizontal, but nUpPageOrder obeys the print settings.
Multiple Pages Per Sheet is obtained by setting pageHandling to nUp.
Integer
R/W
|
Property |
Description |
|---|---|
|
Horizontal |
Pages are placed from left to right, from top to bottom. |
|
HorizontalReversed |
Pages are placed from right to left, from top to bottom. |
|
Vertical |
Pages are placed from top to bottom, from left to right. |
Perform Multiple Pages Per Sheet printing on this document, set the parameters, and print.
pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.nUp;
pp.nUpPageOrders = pp.constants.nUpPageOrders.Horizontal;
pp.nUpNumPagesH = 2;
pp.nUpNumPagesV = 2;
pp.nUpPageBorder=true;
this.print(pp);
|
8.0 |
|
|
|
Sets the number of copies to be printed for this print job.
Integer
R/W
Set print job for duplex printing with two copies.
var pp = this.getPrintParams();
pp.DuplexType = pp.constants.duplexTypes.DuplexFlipShortEdge;
pp.NumCopies = 2;
this.print(pp);
|
6.0 |
|
|
|
Takes one of seven values specified by the constants handling object. If set to an illegal value, it is treated as shrink. The default is shrink.
Integer
R/W
|
Property |
Reader |
Description |
|---|---|---|
|
none |
|
No page scaling is applied. |
|
fit |
|
Pages are enlarged or shrunk to fit the printer’s paper. |
|
shrink |
|
Small pages are printed small, and large pages are shrunk to fit on the printer’s paper. |
|
tileAll |
No |
All pages are printed using tiling settings. This can be used to turn a normal-sized page into a poster by setting the tileScale property greater than 1. |
|
tileLarge |
No |
Small or normal pages are printed in the original size and large pages are printed on multiple sheets of paper. |
|
nUp |
|
(Version 7.0) Pages are rescaled to print multiple pages on each printer page. Properties related to Multiple Pages Per Sheet printing are nUpAutoRotate, nUpNumPagesH, nUpNumPagesV, nUpPageBorder and nUpPageOrder. |
|
booklet |
|
(Version 8.0) Prints multiple pages on the same sheet of paper in the order required to read correctly when folded. The properties of the booklet object are used to set the parameters for booklet printing. |
var pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.shrink;
this.print(pp);
Perform Multiple Pages Per Sheet printing on this document, set the parameters and print.
pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.nUp;
pp.nUpPageOrders = pp.constants.nUpPageOrders.Horizontal;
pp.nUpNumPagesH = 2;
pp.nUpNumPagesV = 2;
pp.nUpPageBorder=true;
this.print(pp);
Print document as a booklet, taking all the default settings.
var pp = this.getPrintParams();
pp.pageHandling = pp.constants.handling.booklet;
this.print(pp);
|
6.0 |
|
|
|
Select even, odd, or all the pages to print. The value of pageSubset is set through the constants subsets object. The default is all.
Integer
R/W
|
Property |
Description |
|---|---|
|
all |
Print all pages in the page range. |
|
even |
Print only the even pages. Page labels are ignored, and the document is treated as if it were numbered 1 through n, the number of pages. |
|
odd |
Print only the odd pages. |
var pp = this.getPrintParams();
pp.pageSubset = pp.constants.subsets.even;
this.print(pp);
|
6.0 |
|
|
|
Set to true to send pages as large bitmaps. This can be slow and more jagged looking but can work around problems with a printer’s PostScript interpreter. Set bitmapDPI to increase or decrease the resolution of the bitmap. If interaction (see interactive) is full, the user’s printer preferences for printAsImage will be used. The default is false.
Boolean
R/W
|
6.0 |
|
|
|
Sets the contents of the print job. The value of the printContents property is set through the constants printContents object. The default is doc.
Integer
R/W
|
Property |
Description |
|---|---|
|
doc |
Print the document contents, not comments. |
|
docAndComments |
Print the document contents and comments. |
|
formFieldsOnly |
Print the contents of form fields only. Useful for printing onto pre-preprinted forms. |
Set printer to silently print form fields only.
var pp = this.getPrintParams();
pp.interactive = pp.constants.interactionLevel.silent;
pp.printContent = pp.constants.printContents.formFieldsOnly;
this.print(pp);
|
11.0 |
|
|
|
Use the printRange property to print multiple sets of pages, each having a different page range. The parameter format is an array of pairs (nStart, nEnd), where nStart and nEnd are 0-based index pages of the PDF document.
Array
R/W
The ESErrorInvalidArgs exception occurs when:
the format of the specified parameters is invalid
the startPage and endPage values are less than 0.
the startPage and endPage values are greater than or equal to totalPages in the PDF.
var pp = this.getPrintParams();
pp.interactive = pp.constants.interactionLevel.full;
pp.printRange=[[1, 1], [3, 4]];
this.print(pp);
|
6.0 |
|
|
|
The name of the destination printer. This property is a Windows and, beginning with version 9.0, a Mac OS feature.
By default, printerName is set to the name of the default printer. If printerName is set to an empty string, the printer used is either the last printer used by Acrobat/Adobe Reader (if printing occurred during the current session) or the System Default printer. When printerName is an empty string and fileName is a nonempty string, the current document is saved as a PostScript file. See Example 2 below.
See also app.printerNames.
String
R/W
Set the printer, and print.
var pp = this.getPrintParams();
pp.printerName = "hp officejet d series";
this.print(pp);
Save the current document as a PostScript file.
var pp = this.getPrintParams();
pp.fileName = "/c/temp/myDoc.ps";
pp.printerName = "";
this.print(pp);
|
6.0 |
|
|
|
Level of PostScript that is emitted to PostScript printers. Level 0 indicates to use the PostScript level of the printer. Level 1 is not supported. In addition to 0, current legal values of psLevel are 2 and 3. If the printer only supports PostScript level 1, printAsImage is set to true. Illegal values are treated as 3. The default value for psLevel is 3.
Integer
R/W
A bit field of flags. These flags can be set or cleared using bitwise operations through the constants rasterFlagValues object. The default is set by user preferences.
Integer
R/W
The table that follows lists the properties of the rasterFlagValues object. None of these properties are available in
|
Property |
Description |
|---|---|
|
textToOutline |
Text converted to outlines can become thicker (especially noticeable on small fonts). If text is mixed into artwork with transparency, it may be converted to outline during flattening, resulting in inconsistency with text that is not mixed into artwork. In this case, turning on this option ensures that all text looks consistent. |
|
strokesToOutline |
Strokes converted to outlines can become thicker (especially noticeable on thin strokes). If strokes are mixed into artwork with transparency, they may be converted to outlines during flattening, resulting in inconsistency with strokes that are not mixed into artwork. In this case, turning on this option ensures that all strokes look consistent. |
|
allowComplexClip |
This option ensures that the boundaries between vector artwork and rasterized artwork fall closely along object paths. Selecting this option reduces stitching artifacts that result when part of an object is flattened while another part of the object remains in vector form. However, selecting this option may result in paths that are too complex for the printer to handle. |
|
preserveOverprint |
Select this option if you are printing separations and the document contains overprinted objects. Selecting this option generally preserves overprint for objects that are not involved in transparency and therefore improves performance. This option has no effect when printing composite. Turning it off might result in more consistent output because all overprinting will be flattened, whether or not it is involved in transparency. |
In the Advanced Printing Setup dialog box, check the “Convert All Text to Outlines” check box in the Transparency Flattening option.
pp = getPrintParams();
rf = pp.constants.rasterFlagValues;
pp.rasterFlags |= rf.textToOutline;
this.print(pp);
In the Advanced Printing Setup dialog box, uncheck “Complex Clip Regions” (checked by default) in the Transparency Flattening option.
pp = getPrintParams();
rf = pp.constants.rasterFlagValues;
pp.rasterFlags = pp.rasterFlags & ~rf.allowComplexClip;
// or pp.rasterFlags &= ~rf.allowComplexClip;
this.print(pp);
|
6.0 |
|
|
|
Set to true to print pages in reverse order (last to first). The default value is false.
Boolean
R/W
Label each page of tiled output. Labeled pages indicate row and column, file name, and print date. The default is false.
Boolean
R/W
Tile marks indicate where to cut the page and where overlap occurs. The value is set through the constants tileMarks object. If set to an illegal value, it is treated as none. The default is none.
Integer
R/W
|
Property |
Description |
|---|---|
|
none |
No tile marks |
|
west |
Western style tile marks |
|
east |
Eastern style tile marks |
The number of points that tiled pages have in common. Value must be between 0 and 144. Illegal values are treated as 0. The default value is 0.
Integer
R/W
The amount that tiled pages are scaled. Pages that are not tiled are unaffected by this value. The default is unscaled (1.0). Larger values increase the size of the printout (for example, 2.0 is twice as large, a value of 0.5 is half as large). The value of tileScale must be between 0.01 and 99.99. Illegal values are treated as 1.0, which is the default value.
Number
R/W
An integer value from 1 to 100 indicates how hard
Integer
R/W
|
6.0 |
|
|
|
Takes one of three values. The value is set through the constants usages object. See also useT1Conversion; the two properties use the same values, but the interpretations are different.
Integer
R/W
|
Property |
Description |
|---|---|
|
auto |
Let Illegal values are treated as auto. The default is auto. |
|
use |
Use the printer’s CRD. |
|
noUse |
Do not use the printer’s CRD. |
|
6.0 |
|
|
|
Takes one of three values. The value of the useT1Conversion property is set through the constants usages object. See also usePrinterCRD; the two properties use the same values, but the interpretations are different.
Note:This property is supported on Windows platforms only.
Integer
R/W
This property uses the constants.usages Object values as follows.
|
Property |
Description |
|---|---|
|
auto |
Let Illegal values are treated as auto. The default is auto. |
|
use |
Allow conversion of Type 1 fonts even if the printer is known to have problems with alternative font representations. |
|
noUse |
Never convert Type 1 fonts to more efficient representations. |