Important: The information in this document is obsolete and should not be used for new development.
PrPicFileprocedure to complete deferred printing.
PROCEDURE PrPicFile (hPrint: THPrint; pPrPort: TPPrPort; pIOBuf: Ptr; pDevBuf: Ptr; VAR prStatus: TPrStatus);
- A handle to a
TPrintrecord (described on page 9-41) for a document.
- A pointer to the printing graphics port. (The
TPrPortrecord that defines a printing graphics port is described on page 9-48.) If this parameter is
PrPicFileprocedure allocates a new printing graphics port in a heap.
- A pointer to an area of memory to be used as an input/output buffer. This parameter should be
NILto use the volume buffer for the spool file's volume. If you allocate your own buffer, it must be exactly 522 bytes.
- A pointer to a device-dependent buffer. This parameter should be
PrPicFileallocates a buffer in a heap.
PrPicFileuses to report on the current page number, current copy, or current file being spooled. You can then display this information to the user. The
TPrStatusrecord is described on page 9-46.
PrPicFileprocedure sends a file spooled for deferred printing to the printer.
You can determine whether a user has chosen deferred printing by testing for the
bSpoolLoopconstant in the
bJDocLoopfield of the
TPrJobrecord contained in the
TPrintrecord specified in the
hPrintparameter. If the
bJDocLoopfield contains the value represented by the
bSpoolLoopconstant, call the
PrPicFileprocedure, which sends the spool file to the printer.
Your application should normally call
PrCloseDocprocedure (described on page 9-65).
SPECIAL CONSIDERATIONSDo not pass, in the
pPrPortparameter, a pointer to the same printing graphics port you received from the
PrOpenDocfunction (described on page 9-64). If that port was allocated by
PrOpenDocitself (that is, if the
PrCloseDocwill already have disposed of the port, making your pointer to it invalid. Of course, if you earlier provided your own storage in
PrOpenDoc, there's no reason you can't use the same storage again for
ASSEMBLY-LANGUAGE INFORMATIONThe trap macro and routine selector for the
Trap macro Selector _PrGlue $60051480
SEE ALSOFor an example of the use of
PrPicFile, see Listing 9-2 beginning on page 9-18.