Binds a variable to either t
or nil
, and executes a body of code to print a page only if the variable is t
.
The macro with-page
binds
printp
to t
if a page is to be printed, or nil
if it is to be skipped. The
body
is executed once, and is expected to draw the document only if
printp
is t
.
Each call to with-page
contributes a new page to the document.
with-page
must be called within the dynamic context of with-print-job.
with-page
does not work on Cocoa.nil
when only part of the document is printed, for example when the user specifies that she wants only odd pages. When
printp
is nil
, the code in
body
needs to ensure that the next call to with-page
prints the right page.
with-document-pages
with-page-transform
with-print-job
Printing from the CAPI—the Hardcopy API
CAPI User Guide and Reference Manual (Macintosh version) - 3 Aug 2017