Binds a stream variable and prints its output.
capi
with-output-to-printer (stream &key printer tab-spacing interactive jobname) &body body => result*
| stream⇩ |
A variable. |
| printer⇩ |
A printer or nil. |
| tab-spacing⇩ |
An integer. |
| interactive⇩ |
A boolean. |
| jobname⇩ |
A string. |
| body⇩ |
Lisp forms. |
| result* |
The values returned by evaluating body. |
The macro with-output-to-printer binds the variable stream to a stream object, and prints everything is that is written to it in the code of body.
If interactive is t then print-dialog is called to select the printer to use. If interactive is nil then printer is used unless it is nil in which case the current-printer is used. The default value of interactive is t and the default value of printer is nil.
The values of jobname and tab-spacing are passed to print-text, which is used to actually do the printing. The default value of tab-spacing is 8 and the default value of jobname is "Text".
current-printer
print-dialog
print-text
16 Printing from the CAPI—the Hardcopy API
CAPI User Guide and Reference Manual (Unix version) - 18 Feb 2025 15:34:22