E.1 Support for PostScript Output

CLIM implementations may choose to implement a PostScript back-end. Such a back-end must include a medium that supports CLIM's medium protocol, and should support CLIM's output stream protocol as well. [annotate]

with-output-to-postscript-stream  (stream-var file-stream &key device-type multi-page scale-to-fit orientation header-comments) &body body [Macro]

Within body, stream-var is bound to a stream that produces PostScript code. This stream is suitable as a stream or medium argument to any CLIM output utility, such as draw-line* or write-string. A PostScript program describing the output to the stream-var stream will be written to file-stream. stream-var must be a symbol. file-stream is a stream. [annotate]

device-type is a symbol that names some sort of PostScript display device. Its default value is unspecified, but must be a useful display device type for the CLIM implementation. [annotate]

multi-page is a boolean that specifies whether or not the output should be broken into multiple pages if it is larger than one page. How the output is broken into multiple pages, and how these multiple pages should be pieced together is unspecified. The default is nil. [annotate]

scale-to-fit is a boolean that specifies whether or not the output should be scaled to fit on a single page if it is larger than one page. The default is nil. It is an error if multi-page and scale-to-fit are both supplied as true. [annotate]

orientation may be one of :portrait (the default) or :landscape. It specifies how the output should be oriented. [annotate]

header-comments allows the programmer to specify some PostScript header comment fields for the resulting PostScript output. The value of header-comments is a list consisting of alternating keyword and value pairs. These are the supported keywords: [annotate]

  • :title---specifies a title for the document, as it will appear in the " [annotate]
  • :for---specifies who the document is for. The associated value will appear in a " [annotate]


new-page  stream [Function]

Give a PostScript stream stream, new-page sends all of the currently collected output to the related file stream (by emitting a PostScript showpage command), and resets the PostScript stream to have no output. [annotate]