Generating PostScript for CUPS

programming, postscript, document structuring conventions

Generating PostScript for CUPS


This document describes how to generate PostScript output for CUPS and is largely based on the Adobe TechNote #5001: PostScript Language Document Structuring Conventions Specification Version 3.0. While CUPS can generally print any PostScript file, following the rules in the Adobe TechNote and this document will ensure that your PostScript output will work reliably.

Note: While PostScript is currently the de-facto standard print job file format/language for UNIX-based applications, it is slowly being phased out in favor of Adobe’s Portable Document Format (“PDF”) which offers many advantages over PostScript. macOS uses PDF as the primary print job file format and Linux is making the transition. Both PostScript and PDF are complex formats, and we highly recommend using high-level toolkits whenever possible to create your print jobs.

Anatomy of a PostScript File

PostScript files are ASCII text files starting with a header line (%!PS-Adobe-3.0) followed by a combination of comment lines starting with the percent sign (%) and PostScript code lines. The lines themselves should not exceed 255 characters to conform to the DSC. The following short PostScript file produces a box with a smiley face in it:

Embedding Printer Options

There are two main strategies for embedding printer options in PostScript files. The first is to list CUPS options using the %cupsJobTicket comment:

CUPS options apply to the entire job. To apply options to individual pages, use the %%IncludeFeature comment instead:

Embedding Fonts and Text

Always embed the fonts used by your print job, and for best performance embed the fonts and character encodings in the setup section of the PostScript file. Type 1 and Type 3 fonts are supported by all PostScript printers, while Type 42 (TrueType) and CID fonts are supported by most level 2 and all level 3 PostScript printers. Binary font files should always be converted to the corresponding ASCII (hex) encoding to avoid problems when printing over interfaces that do not support binary PostScript.

Embedding Images

The image operator should be used to embed images in PostScript files. Always use ASCII hex or Base-85 encoding for the image data to avoid problems when printing over interfaces that do not support binary PostScript. In most cases, the Base-85 encoding and compression filters can be used to embed images with very little, if any, increase in data size.

Help – Submission of PostScript

PostScript > help

PostScript is not an ideal submission format, for several reasons:

  • PostScript loses all contextual information.
  • PostScript loses portability by fixing the page size and resolution.
  • Many broken programs on PCs and Macs produce PostScript which does not conform to the Adobe specification.
  • Level II Postscript cannot always be printed on Level I printers.
  • Note: a PostScript file created from a TeX/LaTeX file will be rejected. There are good reasons for insisting on LaTeX source if it is available.

Unfortunately, many people are under the illusion that submitting PostScript is ideal because it can be printed directly or viewed on the screen. Authors who write in TeX should never submit PostScript, except for figure attachments (see discussion of benefits of TeX source).

If you use an old version of a word processor such as MS Word then PostScript may be a good option. However, PDF is usually better if your word processor supports it. If you use bitmapped fonts or you have some other resolution dependence, produce the PostScript file at 300 dpi for maximum portability.

You must submit any figures that go along with your paper. For PostScript submissions it is best to produce a single PostScript file that includes all figures. However, you may also submit figures in separate PostScript (ps, eps) files. Other file formats (PDF, JPEG, PNG, GIF. ) are not permitted.

Postscript Theater, Inlitify OA


Inlitify OA

Postscript Theater

Volume 11 Postscript Theater

Let’s Play a Card Game Postscript Theater

Fourth Generation Head (-@∀@): “Fwahahaha, did you see! The strongest ‘Celes’ card has been placed on the field. Meanwhile, your field has nothing but a single ‘’Damn Gigolo Lyle’ card… With this, you’re over, Third Generation Head!”

Third Generation Head (`・ω・´): “… Not yet! I can’t lose yet! It’s my turn! Draw!”

Third Generation Head ( ̄ー ̄)*Grin*: “Hmm, finally the card has come…”

Fourth Generation Head (;-@∀@): “W-what are you talking about! A comeback at this point is…”

Third Generation Head (`・ω・´): “Oh yes I can! I sacrifice all of Lyle’s future to the graveyard to summon the ‘Wives’! On top of that, I discard all of his shame and everything else to level up ‘Damn Gigolo Lyle’ to ‘mr. lyle’!”

Fourth Generation Head (;-@∀@): “S-say what!?”

Third Generation Head ( ゜∀゜): “It’s not over yet! On top of all that, I activate Lyle’s effect! By maximizing his Gigolo Constitution, the abilities of the Wives rise even further! And female enemy cards on the field receive a decrease in stats! Until your life points hit zero, I’ll keep on chipping…”

Fourth Generation Head (;-@∀@): “You can’t just summon a bunch of monsters in one turn, that’s against the rules! And wait, that effect doesn’t even work on Celes, you hear! You lose by default, father.”

Third Generation Head (・∀・): “…”

Fourth Generation Head *Kapow*∵(@ε(○=(゜∀゜ ) Third Generation Head: “I attack your life points directly!”

Fourth Generation Head ( @д@⊂彡☆))Д゜) *Thwap*: “That’s also against the rules.”

Mrs. Milleia, Part 1

Milleia (´∀`): “Uhaha, our profits in Beim are simply scrumptious (lolol), keep on wringing them out (lolol). ”

Fifth Generation Head ( ;∀;): (The Sixth sure disappeared at a good time. She used to be so honest… huh? Wait, was she always like this?)

Mrs. Milleia, Part 2

Fourth Generation Head (-@∀@): “Milleia-chan, were you like that? Were you putting on an act in front of the Sixth?”

Milleia 。・゜・(ノ∀`)・゜・。: “Is that how you see me? Grandfather, how cruel!”

Fourth Generation Head (;-@∀@): “Eh? Um… S-sorry!”

Seventh Generation Head |ω・`): (How shameful, Fourth… but the Sixth is also at fault for not seeing through that shady-as-all-hell personality.)

Mrs. Milleia, Part 3

Milleia ( ・∀・): “… Even like this, I’m a ‘kind elder sister character’ you know. I’ll just throw this out there, but that’s why the Jewel chose me in the first place. The other women were much worse than me, you hear.”

Milleia (・∀・): “Don’t forget it.”

Seventh Generation Head|д゜) *glance*: “It’s a lie. And elder sister? The Jewel definitely made a mistake with its personnel sel–”

Milleia ( ´∀`);y=ー(゜д゜)・∵.*Bang*: “Oh, Brod-kun, you just don’t learn, do you (lolol).”

Share this:

Post navigation

So, what’s on your mind? Cancel reply

Hahaha nice one, thanks for a bonus

Woah that card battle is interesting i kinda want it

That card game is imbalanced, no way is it going commercial without rebalancing. LOL

It’s time to dududududuel!

Wait, that was a Yugioh Abridged reference, wasn’t it?

Why yes, yes it was.

“Oh, Brod-kun, you just don’t learn, do you (lolol).”

He likes pain is what I would say…

But I think He is just a straight shooter.

I think Goddess Novem stats will be 3000atk & 2500def, Miranda is 2500atk & 2100def.

Novem killed sex, when on the field all players will discard character cards when drawn until she is removed.

the third use the wives o defeat celes hahahah that is one big of a card.

Lol…Sacrificing Lyle’s future to summon the wives… That’s gold…

If the third summon the ‘wives’, fourth should just activated ‘Novem’s scheme’ trap to taken control of all demi human wives…

Lol japanese text emojis are incredible, didn’t think you could make a face punch with them.

Don’t forget that there’s Celes in jewel so Milleia being sweetest might not be a lie.

thank for the update

mr. lyle is mythic rare status!

thanks for the chapter ^^

Milleia (・∀・)*is reading the comments*

I honestly don’t know what I find funnier…

– The foreshadowing on an upcoming mr. lyle meaning we get even better antics than we’ve seen before. Likely in regards to a loosely stated plan that Max let slip from his mouth a while ago in regards to “seducing some princesses out there”. I mean you can already count a certain unfortunate Lorphys princess as done already with the potential of including Zayin’s two in the picture as well.

– Max (/Sleigh) regarding Lyle’s current collection of wives as “monsters” and they haven’t even gotten near their full potential.

– Being reminded of how much the wives, and daughter(/in-law)s actually disliked one another.

– Milleia being Milleia, just as evil minded as Sleigh.

wow u’re really right. I didn’t see it the first time I read, but in the second time., you got me there

Thanks 4 the chapter!

LOL. They’re questioning Sixth version of Millea.

– I sacrifice all of Lyle’s future to the graveyard.

– I discard all of his shame and everything else to level up ‘Damn Gigolo Lyle’ to ‘mr. lyle’.

Well that how it was huh.

i attack your life points directly lol

Poor Seventh…I don’t think Milleia would hit her elders…but the Seventh is fair game and the only punching bag available left.

If Milleia is the ‘kindest’ out of all, hard to imagine how the other wives are lol.

Another volume ends and we’re getting near to the final battle against Celes. Maybe Lyle’s last stage of skill is [memories], He can extract memories from anything, living or not. Useful skill to learn the lost record of past wars against Agrissa and maybe uncovers some weird facts as well.

The duel part is so good

LOL at card battle.

Women are scary

Thanks for the chapter.

Yorai-kun are you continuing with the next volume of sevens right away, or translate one of other projects?

I’m not doing anything right now

How many children need to be sacrificed for a few more Sevens chapters?

Shouldn’t beg him for chapters, just let him do as he pleases!

His motivational power will come back soon enough.

POSTSCRIPT synonyms, another word for Postscript

postscript, synonym postscript, another word for postscript, words like postscript, thesaurus postscript

What is another word for postscript ?

116 synonyms found

Quotes for Postscript:

  1. In postscript let's just say that I am very fortunate cause I've gotten to work with a lot of great bands! Jim Diamond.
  2. A woman seldom writes her mind but in her postscript . Richard Steele.

DomainOptions, Inc., 7260 W Azure Dr Ste 140-829, Las Vegas, NV 89130 USA. Email:

© 2011-2017 DomainOptions, Inc. Trademarks belong to their respective owners. All rights reserved.

How to Open POSTSCRIPT Files – File Extension POSTSCRIPT

postscript file,postscript files,postscript file extension,open postscript file,how to open postscript file,how to open a postscript file,what is postscript file,what is a postscript file,postscript file format,postscript file type

Solvusoft: Microsoft Gold Certified Company

Recognized for best-in-class capabilities as an ISV (Independent Software Vendor)

Solvusoft is recognized by Microsoft as a leading Independent Software Vendor, achieving the highest level of completence and excellence in software development. Solvusoft’s close relationship with Microsoft as a Gold Certified Partner enables us to provide best-in-class software solutions that are optimized for performance on Windows operating systems.

How is the Gold Competency Level Attained?

To achieve a Gold competency level, Solvusoft goes through extensive independent analysis that looks for, amongst other qualities, a high level of software expertise, a successful customer service track record, and top-tier customer value. As a Gold Certified Independent Software Vendor (ISV), Solvusoft is able to provide the highest level of customer satisfaction through delivering top-level software and service solutions, which have been subject to a rigourous and continually-audited approval process by Microsoft.

Ghostscript and the PostScript language


Ghostscript and the PostScript language

Table of contents

Ghostscript’s capabilities in relation to PostScript

The Ghostscript interpreter, except as noted below, is intended to execute properly any source program written in the (LanguageLevel 3) PostScript language as defined in the PostScript Language Reference, Third Edition (ISBN 0-201-37922-8) published by Addison-Wesley in mid-1999. However, the interpreter is configurable in ways that can restrict it to various subsets of this language. Specifically, the base interpreter accepts the Level 1 subset of the PostScript language, as defined in the first edition of the PostScript Language Reference Manual (ISBN 0-201-10174-2) Addison-Wesley 1985, plus the file system, version 25.0 language, and miscellaneous additions listed in sections A.1.6, A.1.7, and A.1.8 of the Second Edition respectively, including allowing a string operand for the “status” operator. The base interpreter may be configured (see the documentation on building Ghostscript for how to configure it) by adding any combination of the following:

  • The ability to process PostScript Type 1 fonts. This facility is normally included in the interpreter.
  • The CMYK color extensions listed in section A.1.4 of the Second Edition (including colorimage). These facilities are available only if the color, dps, or level2 feature was selected when Ghostscript was built.
  • The Display PostScript extensions listed in section A.1.3 of the Second Edition, but excluding the operators listed in section A.1.2. These facilities are available only if the dps feature or the level2 feature was selected when Ghostscript was built.
  • The composite font extensions listed in section A.1.5 of the Second Edition, and the ability to handle Type 0 fonts. These facilities are available only if the compfont feature or the level2 feature was selected when Ghostscript was built.
  • The ability to load TrueType fonts and to handle PostScript Type 42 (encapsulated TrueType) fonts. These facilities are available only if the ttfont feature was selected when Ghostscript was built.
  • The PostScript Level 2 “filter” facilities except the DCTEncode and DCTDecode filters. These facilities are available only if the filter, dps, or level2 feature was selected when Ghostscript was built.
  • The PostScript Level 2 DCTEncode and DCTDecode filters. These facilities are available only if the dct or level2 feature was selected when Ghostscript was built.
  • All the other PostScript Level 2 operators and facilities listed in section A.1.1 of the Second Edition and not listed in any of the other A.1.n sections. These facilities are available only if the level2 feature was selected when Ghostscript was built.
  • All PostScript LanguageLevel 3 operators and facilities listed in the Third Edition, except as noted below. These facilities are available only if the psl3 feature was selected when Ghostscript was built.
  • The ability to recognize DOS EPSF files and process only the PostScript part, ignoring bitmap previews or other information. This facility is available only if the epsf feature was selected when Ghostscript was built.

Ghostscript currently does not implement the following PostScript LanguageLevel 3 facilities:

  • Native Separation and DeviceN color spaces — the alternate space is always used.
  • Settable ProcessColorModel for page devices, except for a very few special devices.
  • IODevices other than %stdin, %stdout, %stderr, %lineedit, %statementedit, %os%, and (if configured) %pipe%.

Ghostscript can also interpret files in the Portable Document Format (PDF) 1.3 format defined in the Portable Document Format Reference Manual Version 1.3 of March 11, 1999, distributed by Adobe Systems Incorporated, except as noted below. This facility is available only if the pdf feature was selected when Ghostscript was built.

Ghostscript currently does not implement the following PDF 1.3 facilities:

  • Native Separation and DeviceN color spaces, as noted above for PostScript.
  • Native ICCBased color spaces — these too always use the alternate space.

Ghostscript also includes a number of additional operators defined below that are not in the PostScript language defined by Adobe.

Implementation limits

The implementation limits show here correspond to those in Tables B.1 and B.2 of the Second and Third Editions, which describe the quantities fully. Where Ghostscript’s limits are different from those of Adobe’s implementations (as shown in the Third Edition), Adobe’s limits are also shown.

Architectural limits

* The limit on the length of a file name is 128 characters if the name starts with a %. % IODevice designation, or 124 characters if it does not.

Typical memory limits in LanguageLevel 1

for1-, 2-, 4-, or 8-bit samples

Other differences in VM consumption

Packed array elements occupy either 2 bytes or 8 bytes. The average element size is probably about 5 bytes. Names occupy 12 bytes plus the space for the string.

Additional operators in Ghostscript

Graphics and text operators


Ghostscript provides a set of operators for implementing the transparency and compositing facilities of PDF 1.4. These are defined only if the transpar option was selected when Ghostscript was built. We do not attempt to explain the underlying graphics model here: for details, see Adobe Technical Note #5407, “Transparency in PDF”. Note, however, that Ghostscript’s model generalizes that of PDF 1.4 in that Ghostscript maintains separate alpha and mask values for opacity and shape, rather than a single value with a Boolean that says whether it represents opacity or shape. EVERYTHING IN THIS SECTION IS SUBJECT TO CHANGE.

Graphics state operators
Rendering stack operators

The interpreter state is extended to include a (per-context) rendering stack for handling transparency groups and masks (generically, “layers”). Groups accumulate a full value for each pixel (paint plus transparency); masks accumulate only a coverage value. Layers must be properly nested, i.e., the ‘end’ or ‘discard’ operator must match the corresponding ‘begin’ operator.

Beginning and ending layers must nest properly with respect to save and restore: save and restore do not save and restore the layer stack. Currently, layers are not required to nest with respect to gsave and grestore, except that the device that is current in the graphics state when ending a layer must be the same as the device that was current when beginning the layer. THIS AREA IS SUBJECT TO CHANGE. <paramdict> <llx> <lly> <urx> <ury> .begintransparencygroup - Begins a new transparency group. The ll/ur coordinates are the bounding box of the group in the current user coordinate system. paramdict has the following keys: /Isolated (optional) Boolean; default value = false. /Knockout (optional) Boolean; default value = false. - .discardtransparencygroup - Ends and discards the current transparency group. - .endtransparencygroup - Ends the current transparency group, compositing the group being ended onto the group that now becomes current. <paramdict> <llx> <lly> <urx> <ury> .begintransparencymask - Begins a new transparency mask. The ll/ur coordinates are the bounding box of the mask in the current user coordinate system. paramdict has the following keys: /Subtype (required) Name, either /Alpha or /Luminosity. /Background (optional) Array of number. /TransferFunction (optional) Function object (produced by applying .buildfunction to a Function dictionary). - .discardtransparencymask - Ends and discards the current transparency mask. <masknum> .endtransparencymask - Ends the current transparency mask, installing it as the current opacity (masknum = 0) or shape (masknum = 1) mask in the graphics state. <masknum> .inittransparencymask - Resets the current opacity (masknum = 0) or shape (masknum = 1) mask to an infinite mask with alpha = 1 everywhere.

New ImageType

The transparency extension defines a new ImageType 103, similar to ImageType 3 with the following differences:

  • The required MaskDict is replaced by two optional dictionaries, OpacityMaskDict and ShapeMaskDict. If present, these dictionaries must have a BitsPerComponent entry, whose value may be greater than 1. Note that in contrast to ImageType 3, where any non-zero chunky mask value is equivalent to 1, ImageType 103 simply takes the low-order bits of chunky mask values.
  • A Matte entry may be present in one or both mask dictionaries, indicating premultiplication of the data values. If both MaskDicts have a Matte entry and the values of the two Matte entries are different, a rangecheck error occurs.
  • InterleaveType appears in the MaskDicts, not the DataDict, because each mask has its own InterleaveType. InterleaveType 2 (interlaced scan lines) is not supported.

Other graphics state operators

Path operators

Painting operators

Ghostscript supports an experimental extension of the PostScript imaging model to include RasterOp and some related facilities. This extension is available only if the rasterop option was selected when building Ghostscript.

With the RasterOp extension, imaging operations compute a function D = f(D,S,T) in RGB space, where f is an arbitrary 3-input Boolean function, D is the destination (frame buffer or print buffer), S is the source (described below), and T is the texture (the current PostScript color, which may be a pattern). The source and texture depend on the PostScript imaging operation:

  • For fill and stroke, the source is solid black, covering the region to be painted; the texture is the current PostScript color.
  • For show and imagemask, the source is solid black, covering the pixels to be painted; the texture is the current PostScript color.
  • For image and colorimage, the source is the image data; the texture depends on an optional Boolean parameter, CombineWithColor, in the image dictionary. If CombineWithColor is false (the default), the texture is solid black. If CombineWithColor is true, the texture is the current color. For the non-dictionary form of the image operator, CombineWithColor is considered to be false.

The rasterop option adds the following operators: <int8> .setrasterop - Sets the RasterOp function in the graphics state. The default function is 252, Source | Texture. - .currentrasterop <int8> Returns the current RasterOp function. <bool> .setsourcetransparent - Sets source transparency in the graphics state. When source transparency is true, white source pixels prevent storing into the destination, regardless of what the RasterOp function returns. The default source transparency is false. - .currentsourcetransparent <bool> - Returns the current source transparency. <bool> .settexturetransparent - Sets texture transparency in the graphics state. When texture transparency is true, white texture pixels prevent storing into the destination, regardless of what the RasterOp function returns. The default texture transparency is false. - .currenttexturetransparent <bool> - Returns the current texture transparency.

For more information on RasterOp and transparency, please consult chapter 5 of the “PCL 5 Color Technical Reference Manual”, Hewlett-Packard Manual Part No. 5961-0635.

Character operators

This creates a path whose pathbbox is the bbox of the string.

  • If <bool> is false, the equivalent of: p1x p1y moveto

If the CTM is well-behaved (consists only of reflection, scaling, and rotation by multiples of 90 degrees), this too creates a (simpler) path whose pathbbox is the bbox of the string. <font> <charname|charcode> <charname> <charstring> .type1execchar - Does all the work for rendering a Type 1 outline. This operator, like setcharwidth and setcachedevice, is valid only in the context of a show operator — that is, it must only be called from within a BuildChar or BuildGlyph procedure. <font> <charcode> %Type1BuildChar - This is not a new operator: rather, it is a name known specially to the interpreter. Whenever the interpreter needs to render a character (during a . show, stringwidth, or charpath), it looks up the name BuildChar in the font dictionary to find a procedure to run. If it does not find this name, and if the FontType is 1, the interpreter instead uses the value (looked up on the dictionary stack in the usual way) of the name %Type1BuildChar.

The standard definition of %Type1BuildChar is in the initialization file Users should not need to redefine %Type1BuildChar, except perhaps for tracing or debugging. <font> <charname> %Type1BuildGlyph - Provides the Type 1 implementation of BuildGlyph.

Other operators

Mathematical operators

Dictionary operators

String and name operators

Relational operators

File operators

It is intended that in some future version of Ghostscript, files opened with .tempfile will be closed and deleted automatically when Ghostscript exits; however, this is not currently the case (version 7.01). <file> <integer> .unread - Pushes back the last-read character onto the front of the file. If the file is open only for writing, or if the integer argument is not the same as the last character read from the file, causes an ioerror error. May also cause an ioerror if the last operation on the file was not a reading operation. This operator is now deprecated: use .peekstring in new code.

Ghostscript also supports the following IODevice in addition to a subset of those defined in the Adobe documentation: %pipe%command, which opens a pipe on the given command. This is supported only on operating systems that provide popen (primarily Unix systems, and not all of those).

Virtual memory operators

Miscellaneous operators

except that it doesn’t actually create the array. <string> getenv <string> true <string> getenv false Looks up a name in the shell environment. If the name is found, returns the corresponding value and true; if the name is not found, returns false. <name> <array> .makeoperator <operator> Constructs and returns a new operator that is actually the given procedure in disguise. The name is only used for printing. The operator has the executable attribute.

Operators defined in this way do one other thing besides running the procedure: if an error occurs during the execution of the procedure, and there has been no net reduction in operand or dictionary stack depth, the operand or dictionary stack pointer respectively is reset to its position at the beginning of the procedure. <string> <boolean> .setdebug - If the Ghostscript interpreter was built with the DEBUG flag set, sets or resets any subset of the debugging flags normally controlled by -Z in the command line. Has no effect otherwise. - .oserrno <errno> Returns the error code for the most recent operating system error. - .oserrorstring <string> Returns the error string for the most recent operating system error.

Device operators

Alternatively, palette can be 16, 24, 32, or null (equivalent to 24). These are interpreted as:

Note that one can also make an image device (with the same palette as an existing image device) by copying a device using the copydevice operator. <matrix> <width> <height> <palette> <word?> makewordimagedevice <device> Makes an image device as described above. word? is a Boolean value indicating whether the data should be stored in a word-oriented format internally. No ordinary PostScript programs should use this operator. <device> <index> <string> copyscanlines <substring> Copies one or more scan lines from an image device into a string, starting at a given scan line in the image. The data is in the same format as for the image operator. It is an error if the device is not an image device or if the string is too small to hold at least one complete scan line. Always copies an integral number of scan lines. <device> setdevice - Sets the current device to the specified device. Also resets the transformation and clipping path to the initial values for the device. Signals an invalidaccess error if the device is a prototype. - currentdevice <device> Gets the current device from the graphics state. <device> getdeviceprops <mark> <name1> <value1> . <namen> <valuen> Gets the properties of a device. See the section on device parameters below for details. <mark> <name1> <value1> . <namen> <valuen> <device> putdeviceprops <device> Sets properties of a device. May cause undefined, typecheck, rangecheck, or limitcheck errors. - flushpage - On displays, flushes any buffered output, so that it is guaranteed to show up on the screen; on printers, has no effect.

Standard filters

In its usual configuration, Ghostscript supports all the standard PostScript LanguageLevel 3 filters, both encoding and decoding, except that it does not currently support:

  • the EarlyChange key in the LZWEncode filter.

Ghostscript also supports additional keys in the optional dictionary operands for some filters. For the LZWDecode filter: InitialCodeLength <integer> (default 8) An integer between 2 and 11 specifying the initial number of data bits per code. Note that the actual initial code length is 1 greater than this, to allow for the reset and end-of-data code values. FirstBitLowOrder <boolean> (default false) If true, codes appear with their low-order bit first. BlockData <boolean> (default false) If true, the data is broken into blocks in the manner specified for the GIF file format.

For the CCITTFaxEncode and CCITTFaxDecode filters: DecodedByteAlign <integer> (default 1) An integer N with the value 1, 2, 4, 8, or 16, specifying that decoded data scan lines are always a multiple of N bytes. The encoding filter skips data in each scan line from Columns to the next multiple of N bytes; the decoding filter pads each scan line to a multiple of N bytes.

Non-standard filters

In addition to the standard PostScript LanguageLevel 3 filters, Ghostscript supports the following non-standard filters. Many of these filters are used internally to implement standard filters or facilities; they are almost certain to remain, in their present form or a backward-compatible one, in future Ghostscript releases. <target> /BCPEncode filter <file> <source> /BCPDecode filter <file> Create filters that implement the Adobe Binary Communications Protocol. See Adobe documentation for details. <target> <seed_integer> /eexecEncode filter <file> Creates a filter for encrypting data into the encrypted format described in the Adobe Type 1 Font Format documentation. The seed_integer must be 55665 for the eexec section of a font, or 4330 for a CharString. Note that for the eexec section of a font, this filter produces binary output and does not include the initial 4 (or lenIV) garbage bytes. <source> <seed_integer> /eexecDecode filter <file> <source> <dict> /eexecDecode filter <file> Creates a filter for decrypting data encrypted as described in the Adobe Type 1 Font Format documentation. The seed_integer must be 55665 or 4330 as described just above. Recognized dictionary keys are: seed <16-bit integer> (required)

lenIV <non-negative integer> (default=4) <target> /MD5Encode filter <file> Creates a filter that produces the 16-byte MD5 digest of the input. Note that no output is produced until the filter is closed. <source> <hex_boolean> /PFBDecode filter <file> Creates a filter that decodes data in .PFB format, the usual semi-binary representation for Type 1 font files on IBM PC and compatible systems. If hex_boolean is true, binary packets are converted to hex; if false, binary packets are not converted. <target> <dict> /PixelDifferenceEncode filter <file> <source> <dict> /PixelDifferenceDecode filter <file> Implements the Predictor=2 pixel-differencing option of the LZW filters. Recognized keys are: Colors <integer> (1 to 4, default=1)

BitsPerComponent <integer> (1, 2, 4, or 8, default=8)

The Predictor is the PNG algorithm number + 10 for the Encoding filter; the Decoding filter ignores Predictor. 15 means the encoder attempts to optimize the choice of algorithm. For more details see the PNG specification <target> /TBCPEncode filter <file> <source> /TBCPDecode filter <file> Create filters that implement the Adobe Tagged Binary Communications Protocol. See Adobe documentation for details. <target> /zlibEncode filter <file> <source> /zlibDecode filter <file> Creates filters that use the data compression method variously known as ‘zlib’ (the name of a popular library that implements it), ‘Deflate’ (as in RFC 1951, which is a detailed specification for the method), ‘gzip’ (the name of a popular compression application that uses it), or ‘Flate’ (Adobe’s name). Note that the PostScript Flate filters are actually a combination of this filter with an optional predictor filter.

Unstable filters

Some versions of Ghostscript may also support other non-standard filters for experimental purposes. The current version includes the following such filters, which are not documented further. No code should assume that these filters will exist in compatible form, or at all, in future versions. <target/source> <string> ByteTranslateEncode/Decode filter <file> string must be a string of exactly 256 bytes. Creates a filter that converts each input byte b to string[b]. Note that the Encode and Decode filters operate identically: the client must provide a string for the Decode filter that is the inverse mapping of the string for the Encode filter. <target/source> <dict> BoundedHuffmanEncode/Decode filter <file> These filters encode and decode data using Huffman codes. Since these filters aren’t used anywhere, we don’t document them further, except to note the recognized dictionary keys, which must be set identically for encoding and decoding: FirstBitLowOrder <bool> (default=false)

Tables <int_array> <target/source> <dict> BWBlockSortEncode/Decode filter <file> This filter implements the Burroughs-Wheeler block sorting compression method, which we’ve heard is also used in the popular bzip2 compression application. See for more information. The only recognized dictionary key is: BlockSize <integer> (default=16384) <target/source> MoveToFrontEncode/Decode filter <file> The Encode filter starts by initializing an internal 256-byte array a to the values 0 .. 255. This array will always hold a permutation of these values. Then for each input byte b, the filter outputs the index i such that a[i] = b, and moves that element to the front (element 0) of a, moving elements 0 .. i-1 to positions 1 .. i. The Decode filter inverts this process.

Device parameters

In addition, the following are defined per Adobe’s documentation for the setpagedevice operator: Duplex (if supported)

NumCopies (for printers only)

ProcessColorModel (usually read-only)

Some devices may only allow certain values for HWResolution and PageSize. The null device ignores attempts to set PageSize; its size is always [0 0].

For printers these are also defined: BufferSpace <integer> Buffer space for band lists, if the bitmap is too big to fit in memory. MaxBitmap <integer> Maximum space for a full bitmap in memory. OutputFile <string> An empty string means “send to printer directly”, otherwise specifies the file name for output; %d is replaced by the page number; on Unix systems %pipe%command writes to a pipe. (|command also writes to a pipe, but is now deprecated.) OpenOutputFile <boolean> If true, open the device’s output file when the device is opened, rather than waiting until the first page is ready to print. PageCount <integer> (read-only) Counts the number of pages printed on the device.

The following parameters are for use only by very specialized applications that separate band construction from band rasterization. Improper use may cause unpredictable errors. In particular, if you only want to allocate more memory for banding, to increase band size and improve performance, use the BufferSpace parameter, not BandBufferSpace. BandHeight <integer> The height of bands when banding. 0 means use the largest band height that will fit within the BandBufferSpace (or BufferSpace, if BandBufferSpace is not specified). BandWidth <integer> The width of bands in the rasterizing pass, in pixels. 0 means use the actual page width. BandBufferSpace <integer> The size of the band buffer in the rasterizing pass, in bytes. 0 means use the same buffer size as for the interpretation pass.

In addition, Ghostscript supports the following parameter for setpagedevice and currentpagedevice that is not a device parameter per se: ViewerPreProcess <procedure> Specifies a procedure to be applied to the page device dictionary before any other processing is done. The procedure may not alter the dictionary, but it may return a modified copy. This “hook” is provided for use by viewing programs such as GSview.

User parameters

Miscellaneous additions

Copyright © 1996, 2000 Aladdin Enterprises. All rights reserved.

This file is part of AFPL Ghostscript. See the Aladdin Free Public License (the “License”) for full details of the terms of using, copying, modifying, and redistributing AFPL Ghostscript.

Ghostscript version 7.03, 20 October 2001

About Plotting Adobe PostScript Files, AutoCAD, Autodesk Knowledge Network


About Plotting Adobe PostScript Files


Using the Adobe PostScript driver, you can use DWGs with an array of page layout programs and archive tools such as the Adobe Acrobat Portable Document Format (PDF).

You can use the non-system PostScript driver to plot drawings to PostScript printers and PostScript files. Use the PS file format for printers and the EPS file format for files. If you plot to a hardware port, PS output is automatic. If you plot to a file and plan to copy the file to a printer, configure for PS output.

Use the custom Properties dialog box in the Plotter Configuration Editor to customize the output. To display this dialog box, on the Device and Document Settings tab, in the tree view, select Custom Properties. Then under Access Custom Dialog, click the Custom Properties button.

The PostScript driver supports three types of PostScript.

  • Level 1: Use for most plotters.
  • Level 1.5: Use for plotters that support color images.
  • Level 2: If your plotter supports Level 2 PostScript, use to produce smaller files that print more rapidly.

The Tokenize PostScript Code and Compression options in the PostScript Custom Properties dialog box reduce output file size and improve printing speed on devices that support these options. If you have problems printing, try clearing all the options. If you successfully print with no optimizations, you can try turning the options on one at a time to determine the options your printer supports.

Some desktop publishing applications only support Level 1 PostScript. If you have problems using your EPS files, try a lower PostScript level and turn off the optimizations just described.

Including a preview thumbnail in your EPS file makes the file substantially larger but allows quick preview by many applications. The WMF preview is for Windows; the EPSF preview is for Macintosh and other platforms.

Including both preview images can triple your file size.