Summary of the Printing Manager
Pascal Summary
Constants
CONST
iPrPgFst = 1; {page range constant--first page}
iPrRelease = 3; {current version number of the printer driver}
iPrPgFract = 120; {page scale factor}
iPFMaxPgs = 128; {maximum pages in spool file}
iPrPgMax = 9999; {page range constant--last page}
{PrCtlCall constants for the iWhichCtl parameter}
iPrBitsCtl = 4; {print a bitmap object}
iPrIOCtl = 5; {perform text streaming}
iPrEvtCtl = 6; {print object specified in lParam1 parameter}
iPrDevCtl = 7; {device control command}
{constants used with iPrBitsCtl (in the lParam1 parameter of PrCtlCall)}
lScreenBits = $00000000; {resolution is 80 x 72 dpi}
lPaintBits = $00000001; {resolution is 72 x 72 dpi}
lHiScreenBits = $00000002; {resolution is 160 x 144 dpi}
lHiPaintBits = $00000003; {resolution is 144 x 144 dpi}
{constants used with iPrEvtCtl (in the lParam3 parameter of PrCtlCall)}
lPrEvtAll = $0002FFFD; {the entire screen}
lPrEvtTop = $0001FFFD; {the frontmost window}
{constants used with iPrDevCtl (in the lParam1 parameter of PrCtlCall)}
lPrReset = $00010000; {reserved}
lPrLineFeed = $00030000; {paper advance}
lPrLFStd = $0003FFFF; {carriage return with line feed}
lPrLFSixth = $0003FFFF; {used for low-level call for ImageWriter}
lPrPageEnd = $00020000; {end page}
lPrDocOpen = $00010000; {open document for printing}
lPrPageOpen = $00040000; {open page for printing}
lPrPageClose = $00020000; {close page for printing}
lPrDocClose = $00050000; {close document for printing}
bDraftLoop = 0; {draft-quality printing}
bSpoolLoop = 1; {deferred printing}
bUser1Loop = 2; {reserved}
bUser2Loop = 3; {reserved}
iPrSavPFil = -1; {problem saving print file}
iPrAbort = $0080; {the user pressed Command-period}
iFMgrCtl = 8; {File Mgr's dialog-hook proc's control number}
pPrGlobals = $00000944; {PrVars low memory area}
iPrDrvrRef = -3; {reference number of printer driver}
{opcodes used with PrGeneral}
getRslDataOp = 4; {get resolutions for the current printer}
setRslOp = 5; {set resolutions for a TPrint record}
draftBitsOp = 6; {force enhanced draft-quality printing}
noDraftBitsOp = 7; {cancel enhanced draft-quality printing}
getRotnOp = 8; {get page orientation of a TPrint record}
{result codes from PrGeneral}
noSuchRsl = 1; {resolution not supported}
Data Types
TYPE
TPPrint = ^TPrint; {pointer to a TPrint record}
THPrint = ^TPPrint; {handle to a TPrint record}
TPrint = {print record}
RECORD
iPrVersion: Integer; {reserved}
prInfo: TPrInfo; {resolution of device & page rectangle}
rPaper: Rect; {paper rectangle}
prStl: TPrStl; {printer driver number & feed type}
prInfoPT: TPrInfo; {reserved}
prXInfo: TPrXInfo; {reserved}
prJob: TPrJob; {information from the job dialog box}
printX: ARRAY[1..19] OF Integer;
{reserved}
END;
TPPrInfo = ^TPrInfo;
TPrInfo = {printer information record}
RECORD
iDev: Integer; {reserved}
iVRes: Integer; {vertical resolution of printer, in dpi}
iHRes: Integer; {horizontal resolution of printer, in dpi}
rPage: Rect; {the page rectangle}
END;
TPPrJob = ^TPrJob;
TPrJob = {print job record}
RECORD
iFstPage: Integer; {first page of page range}
iLstPage: Integer; {last page of page range}
iCopies: Integer; {number of copies}
bJDocLoop: SignedByte; {printing method: draft or deferred}
fFromUsr: Boolean; {reserved}
pIdleProc: PrIdleProcPtr; {pointer to an idle procedure}
pFileName: StringPtr; {spool filename: NIL for default}
iFileVol: Integer; {spool file volume; set to 0 initially}
bFileVers: SignedByte; {spool file version; set to 0 initially}
bJobX: SignedByte; {reserved}
END;
TPPrStl = ^TPrStl;
TPrStl = {printing style record}
RECORD
wDev: Integer; {device number of printer}
iPageV: Integer; {reserved}
iPageH: Integer; {reserved}
bPort: SignedByte; {reserved}
feed: TFeed; {feed type}
END;
TPPrStatus = ^TPrStatus;
TPrStatus = {printing status record}
RECORD
iTotPages: Integer; {total pages in print file}
iCurPage: Integer; {current page number}
iTotCopies: Integer; {total copies requested}
iCurCopy: Integer; {current copy number}
iTotBands: Integer; {reserved}
iCurBand: Integer; {reserved}
fPgDirty: Boolean; {TRUE if current page has been written to}
fImaging: Boolean; {reserved}
hPrint: THPrint; {handle to the active TPrint record}
pPrPort: TPPrPort; {pointer to the active printing graphics port}
hPic: PicHandle; {handle to the active picture}
END;
TPPrDlg = ^TPrDlg;
TPrDlg = {print dialog box record}
RECORD
Dlg: DialogRecord; {a dialog record}
pFltrProc: ModalFilterProcPtr; {pointer to event filter}
pItemProc: PItemProcPtr; {pointer to item-handling function}
hPrintUsr: THPrint; {handle to a TPrint record}
fDoIt: Boolean; {TRUE means user clicked OK}
fDone: Boolean; {TRUE means user clicked OK or Cancel}
lUser1: LongInt; {storage for your application}
lUser2: LongInt; {storage for your application}
lUser3: LongInt; {storage for your application}
lUser4: LongInt; {storage for your application}
END;
TPPrPort = ^TPrPort;
TPrPort = {printing graphics port record}
RECORD
gPort: GrafPort; {graphics port for printing}
gProcs: QDProcs; {procedures for printing in the graphics port}
lGParam1: LongInt; {reserved}
lGParam2: LongInt; {reserved}
lGParam3: LongInt; {reserved}
lGParam4: LongInt; {reserved}
fOurPtr: Boolean; {reserved}
fOurBits: Boolean; {reserved}
END;
TFeed = (feedCut,feedFanfold,feedMechCut,feedOther);
TScan = (scanTB,scanBT,scanLR,scanRL);
TPRect = ^Rect;
PrIdleProcPtr = ProcPtr;
PItemProcPtr = ProcPtr;
PDlgInitProcPtr = ProcPtr;
{records used by PrGeneral}
TGnlData =
RECORD
iOpCode: Integer; {opcode passed to PrGeneral}
iError: Integer; {result code returned by PrGeneral}
lReserved: LongInt; {more fields here depending on opcode}
END;
TGetRslBlk = {get-resolution record}
RECORD
iOpCode: Integer; {the getRslDataOp opcode}
iError: Integer; {result code returned by PrGeneral}
lReserved: LongInt; {reserved}
iRgType: Integer; {printer driver version number}
xRslRg: TRslRg; {x-direction resolution range}
yRslRg: TRslRg; {y-direction resolution range}
iRslRecCnt: Integer; {number of resolution records}
rgRslRec: ARRAY[1..27] OF TRslRec;
{array of resolution records}
END;
TRslRg =
RECORD
iMin: Integer; {minimum resolution supported}
iMax: Integer; {maximum resolution supported}
END;
TRslRec =
RECORD
iXRsl: Integer; {discrete resolution, x direction}
iYRsl: Integer; {discrete resolution, y direction}
END;
TSetRslBlk = {set-resolution record}
RECORD
iOpCode: Integer; {the setRslOp opcode}
iError: Integer; {result code returned by PrGeneral}
lReserved: LongInt; {reserved}
hPrint: THPrint; {handle to the current TPrint record}
iXRsl: Integer; {x-direction resolution you want}
iYRsl: Integer; {y-direction resolution you want}
END;
TDftBitsBlk = {draft bits record}
RECORD
iOpCode: Integer; {draftBitsOp or noDraftBitsOp opcode}
iError: Integer; {result code returned by PrGeneral}
lReserved: LongInt; {reserved}
hPrint: THPrint; {handle to the current TPrint record}
END;
TGetRotnBlk = {page orientation record}
RECORD
iOpCode: Integer; {the getRotnOp opcode}
iError: Integer; {result code returned by PrGeneral}
lReserved: LongInt; {reserved}
hPrint: THPrint; {handle to current TPrint record}
fLandscape: Boolean; {TRUE if user selected landscape printing}
bXtra: SignedByte; {reserved}
END;
Printing Manager Routines
Opening and Closing the Printing Manager
PROCEDURE PrOpen;
PROCEDURE PrClose;
Initializing and Validating TPrint Records
PROCEDURE PrintDefault (hPrint: THPrint);
FUNCTION PrValidate (hPrint: THPrint): Boolean;
Displaying and Customizing the Print Dialog Boxes
FUNCTION PrStlDialog (hPrint: THPrint): Boolean;
FUNCTION PrJobDialog (hPrint: THPrint): Boolean;
FUNCTION PrDlgMain (hPrint: THPrint; pDlgInit: PDlgInitProcPtr):
Boolean;
FUNCTION PrStlInit (hPrint: THPrint): TPPrDlg;
FUNCTION PrJobInit (hPrint: THPrint): TPPrDlg;
PROCEDURE PrJobMerge (hPrintSrc: THPrint; hPrintDst: THPrint);
Printing a Document
FUNCTION PrOpenDoc (hPrint: THPrint; pPrPort: TPPrPort;
pIOBuf: Ptr): TPPrPort;
PROCEDURE PrCloseDoc (pPrPort: TPPrPort);
PROCEDURE PrOpenPage (pPrPort: TPPrPort; pPageFrame: TPRect);
PROCEDURE PrClosePage (pPrPort: TPPrPort);
PROCEDURE PrPicFile (hPrint: THPrint; pPrPort: TPPrPort;
pIOBuf: Ptr; pDevBuf: Ptr;
VAR prStatus: TPrStatus);
Optimizing Printing
PROCEDURE PrGeneral (pData: Ptr);
Handling Printing Errors
FUNCTION PrError : Integer;
PROCEDURE PrSetError (iErr: Integer);
Low-Level Routines
FUNCTION PrDrvrVers : Integer;
PROCEDURE PrDrvrOpen;
PROCEDURE PrDrvrClose;
FUNCTION PrDrvrDCE: Handle;
PROCEDURE PrCtlCall (iWhichCtl: Integer; lParam1: LongInt;
lParam2: LongInt; lParam3: LongInt);
Application-Defined Routines
PROCEDURE MyDoPrintIdle;
FUNCTION MyPrDialogAppend (hPrint: THPrint): TPPrDlg;
C Summary
Constants
enum {
iPrPgFst = 1, /* page range constant--first page */
iPrRelease = 3, /* current version number of the printer driver */
iPrPgFract = 120, /* page scale factor */
iPFMaxPgs = 128, /* maximum pages in spool file */
iPrPgMax = 9999, /* page range constant--last page */
/* PrCtlCall constants for the iWhichCtl parameter */
iPrBitsCtl = 4, /* print a bitmap object */
iPrIOCtl = 5, /* perform text streaming */
iPrEvtCtl = 6, /* print object specified in lParam1 parameter */
iPrDevCtl = 7, /* device control command */
/* constants used with iPrBitsCtl (in the lParam1 parameter
of PrCtlCall) */
lScreenBits = 0, /* resolution is 80 x 72 dpi */
lPaintBits = 1, /* resolution is 72 x 72 dpi */
lHiScreenBits = 0x00000002, /* resolution is 160 x 144 dpi */
lHiPaintBits = 0x00000003, /* resolution is 144 x 144 dpi */
/* constants used with iPrEvtCtl (in the lParam3 parameter
of PrCtlCall) */
lPrEvtAll = 0x0002FFFD, /* the entire screen */
lPrEvtTop = 0x0001FFFD, /* the frontmost window */
/* constants used with iPrDevCtl (in the lParam1 parameter
of PrCtlCall) */
lPrReset = 0x00010000, /* reserved */
lPrLineFeed = 0x00030000, /* paper advance */
lPrLFStd = 0x0003FFFF, /* carriage return with line feed */
lPrLFSixth = 0x0003FFFF, /* used for low-level call for
ImageWriter */
lPrPageEnd = 0x00020000, /* end page */
lPrDocOpen = 0x00010000, /* open document for printing */
lPrPageOpen = 0x00040000, /* open page for printing */
lPrPageClose = 0x00020000, /* close page for printing */
lPrDocClose = 0x00050000, /* close document for printing */
bDraftLoop = 0, /* draft-quality printing */
bSpoolLoop = 1, /* deferred printing */
bUser1Loop = 2, /* reserved */
bUser2Loop = 3, /* reserved */
iPrSavPFil = -1, /* problem saving print file */
iPrAbort = 0x0080, /* the user pressed Command-period */
iFMgrCtl = 8, /* File Mgr's dialog-hook proc's control
number */
pPrGlobals = 0x00000944, /* PrVars low memory area */
iPrDrvrRef = -3, /* reference number of printer driver */
/* opcodes used with PrGeneral */
getRslDataOp = 4, /* get resolutions for the current printer */
setRslOp = 5, /* set resolutions for a TPrint record */
draftBitsOp = 6, /* force enhanced draft-quality printing */
noDraftBitsOp = 7, /* cancel enhanced draft-quality printing */
getRotnOp = 8, /* get page orientation of a TPrint record */
/* result code from PrGeneral */
noSuchRsl = 1, /* resolution not supported */
};
Data Types
struct TPrint { /* print record */
short iPrVersion; /* reserved */
TPrInfo prInfo; /* resolution of device & page rectangle */
Rect rPaper; /* paper rectangle */
TPrStl prStl; /* printer driver number & feed type */
TPrInfo prInfoPT; /* reserved */
TPrXInfo prXInfo; /* reserved */
TPrJob prJob; /* information from the job dialog box */
short printX[19]; /* reserved */
};
typedef struct TPrint TPrint;
typedef TPrint *TPPrint, **THPrint;
struct TPrInfo { /* printer information record */
short iDev; /* reserved */
short iVRes; /* vertical resolution of printer, in dpi */
short iHRes; /* horizontal resolution of printer, in dpi */
Rect rPage; /* the page rectangle */
};
typedef struct TPrInfo TPrInfo;
typedef TPrInfo *TPPrInfo;
struct TPrJob { /* print job record */
short iFstPage; /* first page of page range */
short iLstPage; /* last page of page range */
short iCopies; /* number of copies */
char bJDocLoop; /* printing method: draft or deferred */
Boolean fFromUsr; /* reserved */
PrIdleProcPtr
pIdleProc; /* pointer to an idle procedure */
StringPtr
pFileName; /* spool filename: NIL for default */
short iFileVol; /* spool file volume; set to 0 initially */
char bFileVers; /* spool file version; set to 0 initially */
char bJobX; /* reserved */
};
typedef struct TPrJob TPrJob;
typedef TPrJob *TPPrJob;
struct TPrStl { /* printing style record */
short wDev; /* device number of printer */
short iPageV; /* reserved */
short iPageH; /* reserved */
char bPort; /* reserved */
TFeed feed; /* feed type */
};
typedef struct TPrStl TPrStl;
typedef TPrStl *TPPrStl;
struct TPrStatus { /* printing status record */
short iTotPages; /* total pages in print file */
short iCurPage; /* current page number */
short iTotCopies; /* total copies requested */
short iCurCopy; /* current copy number */
short iTotBands; /* reserved */
short iCurBand; /* reserved */
Boolean fPgDirty; /* TRUE if current page has been written to */
Boolean fImaging; /* reserved */
THPrint hPrint; /* handle to the active TPrint record */
TPPrPort pPrPort; /* pointer to the active printing graphics port */
PicHandle hPic; /* handle to the active picture */
};
typedef struct TPrStatus TPrStatus;
typedef TPrStatus *TPPrStatus;
struct TPrDlg { /* print dialog box record */
DialogRecord Dlg; /* a dialog record */
ModalFilterProcPtr
pFltrProc; /* pointer to event filter */
PItemProcPtr pItemProc; /* pointer to item-handling function */
THPrint hPrintUsr; /* handle to a TPrint record */
Boolean fDoIt; /* TRUE means user clicked OK */
Boolean fDone; /* TRUE means user clicked OK or Cancel */
long lUser1; /* storage for your application */
long lUser2; /* storage for your application */
long lUser3; /* storage for your application */
long lUser4; /* storage for your application */
};
typedef struct TPrDlg TPrDlg;
typedef TPrDlg *TPPrDlg;
typedef pascal TPPrDlg (*PDlgInitProcPtr)(THPrint hPrint);
truct TPrPort { /* printing graphics port record */
GrafPort gPort; /* graphics port for printing */
QDProcs gProcs; /* procedures for printing in the graphics port */
long lGParam1; /* reserved */
long lGParam2; /* reserved */
long lGParam3; /* reserved */
long lGParam4; /* reserved */
Boolean fOurPtr; /* reserved */
Boolean fOurBits; /* reserved */
};
typedef struct TPrPort TPrPort;
typedef TPrPort *TPPrPort;
enum {feedCut,feedFanfold,feedMechCut,feedOther};
typedef unsigned char TFeed;
enum {scanTB,scanBT,scanLR,scanRL};
typedef unsigned char TScan;
typedef Rect *TPRect;
typedef pascal void (*PrIdleProcPtr)(void);
typedef pascal void (*PItemProcPtr)(DialogPtr theDialog, short item);
/* structures used by PrGeneral */
struct TGnlData {
short iOpCode; /* opcode passed to PrGeneral */
short iError; /* result code returned by PrGeneral */
long lReserved; /* more fields here depending on call */
};
typedef struct TGnlData TGnlData;
struct TGetRslBlk { /* get-resolution record */
short iOpCode; /* the getRslDataOp opcode */
short iError; /* result code returned by PrGeneral */
long lReserved; /* reserved */
short iRgType; /* printer driver version number */
TRslRg xRslRg; /* x-direction resolution range */
TRslRg yRslRg; /* y-direction resolution range */
short iRslRecCnt; /* number of resolution records */
TRslRec rgRslRec[27]; /* array of resolution records */
};
typedef struct TGetRslBlk TGetRslBlk;
struct TRslRg {
short iMin; /* minimum resolution supported */
short iMax; /* maximum resolution supported */
};
typedef struct TRslRg TRslRg;
struct TRslRec {
short iXRsl; /* discrete resolution, x direction */
short iYRsl; /* discrete resolution, y direction */
};
typedef struct TRslRec TRslRec;
struct TSetRslBlk { /* set-resolution record */
short iOpCode; /* the setRslOp opcode */
short iError; /* result code returned by PrGeneral */
long lReserved; /* reserved */
THPrint hPrint; /* handle to the current TPrint record */
short iXRsl; /* x-direction resolution you want */
short iYRsl; /* y-direction resolution you want */
};
typedef struct TSetRslBlk TSetRslBlk;
struct TDftBitsBlk { /* draft bits record */
short iOpCode; /* draftBitsOp or noDraftBitsOp opcode */
short iError; /* result code returned by PrGeneral */
long lReserved; /* reserved */
THPrint hPrint; /* handle to the current TPrint record */
};
typedef struct TDftBitsBlk TDftBitsBlk;
struct TGetRotnBlk { /* page orientation record */
short iOpCode; /* the getRotnOp opcode */
short iError; /* result code returned by PrGeneral */
long lReserved; /* reserved */
THPrint hPrint; /* handle to current TPrint record */
Boolean fLandscape; /* TRUE if user selected landscape printing */
char bXtra; /* reserved */
};
typedef struct TGetRotnBlk TGetRotnBlk;
Printing Manager Functions
Opening and Closing the Printing Manager
pascal void PrOpen (void);
pascal void PrClose (void);
Initializing and Validating TPrint Records
pascal void PrintDefault (THPrint hPrint);
pascal Boolean PrValidate (THPrint hPrint);
Displaying and Customizing the Print Dialog Boxes
pascal Boolean PrStlDialog (THPrint hPrint);
pascal Boolean PrJobDialog (THPrint hPrint);
pascal Boolean PrDlgMain (THPrint hPrint, PDlgInitProcPtr pDlgInit);
pascal TPPrDlg PrStlInit (THPrint hPrint);
pascal TPPrDlg PrJobInit (THPrint hPrint);
pascal void PrJobMerge (THPrint hPrintSrc, THPrint hPrintDst);
Printing a Document
pascal TPPrPort PrOpenDoc (THPrint hPrint, TPPrPort pPrPort, Ptr pIOBuf);
pascal void PrCloseDoc (TPPrPort pPrPort);
pascal void PrOpenPage (TPPrPort pPrPort, TPRect pPageFrame);
pascal void PrClosePage (TPPrPort pPrPort);
pascal void PrPicFile (THPrint hPrint, TPPrPort pPrPort, Ptr pIOBuf,
Ptr pDevBuf, TPrStatus *prStatus);
Optimizing Printing
pascal void PrGeneral (Ptr pData);
Handling Printing Errors
pascal short PrError (void);
pascal void PrSetError (short iErr);
Low-Level Functions
pascal short PrDrvrVers (void);
pascal void PrDrvrOpen (void);
pascal void PrDrvrClose (void);
pascal Handle PrDrvrDCE (void);
pascal void PrCtlCall (short iWhichCtl, long lParam1,
long lParam2, long lParam3);
Application-Defined Functions
pascal void MyDoPrintIdle (void);
pascal TPPrDlg MyPrDialogAppend
(THPrint hPrint);
Assembly-Language Summary
Data Structures
TPrint Data Structure
0 | iPrVersion | word | printer driver version that initialized this record |
2 | prInfo | 14 bytes | TPrInfo data structure with resolution of device and page rectangle |
16 | rPaper | 8 bytes | paper rectangle |
24 | prStl | 8 bytes | TPrStl data structure with printer driver number and feed type |
32 | prInfoPT | 14 bytes | TPrInfo data structure; reserved |
46 | prXInfo | 16 bytes | TPrXInfo data structure; reserved |
62 | prJob | 20 bytes | TPrJob data structure with printing information from the job dialog box |
82 | printX | 40 bytes | reserved |
TPrInfo Data Structure
0 | iDev | 6 bytes | first word is reserved; second word contains vertical resolution of printer, in dpi; third word contains horizontal resolution of printer, in dpi |
6 | rPage | 8 bytes | the page rectangle |
TPrJob Data Structure
0 | iFstPage | word | first page of page range |
2 | iLstPage | word | last page of page range |
4 | iCopies | word | number of copies |
6 | bJDocLoop | 1 byte | printing method: draft or deferred |
7 | fFromApp | 1 byte | reserved |
8 | pIdleProc | long | pointer to an idle procedure |
12 | pFileName | long | spool filename: NIL for default |
16 | iFileVol | word | spool file volume: set to 0 initially |
18 | bFileVers | 1 byte | spool file version: set to 0 initially |
TPrStl Data Structure
0 | wDev | word | device number of the current printer (in the high-order byte of this field); the low-order byte of this field is reserved |
2 | iPageV | word | reserved |
4 | iPageH | word | reserved |
7 | feed | 1 byte | paper feed type |
TPrStatus Data Structure
0 | iTotPages | word | total pages in print file |
2 | iCurPage | word | current page number |
4 | iTotCopies | word | total copies requested |
6 | iCurCopy | word | current copy number |
8 | iTotBands | word | reserved |
10 | iCurBand | word | reserved |
12 | fPgDirty | 1 byte | TRUE if current page has been written to |
13 | fImaging | 1 byte | reserved |
14 | hPrint | long | handle to the active TPrint data structure |
18 | pPrPort | long | pointer to the active printing graphics port |
22 | hPic | long | handle to the active picture |
TPrDlg Data Structure
0 | dlg | 168 bytes | a dialog record |
168 | pFltrProc | long | pointer to event filter |
172 | pItemProc | long | pointer to item-handling function |
176 | hPrintUsr | long | handle to TPrint data structure |
180 | fDoIt | 1 byte | TRUE means user clicked OK |
181 | fDone | 1 byte | TRUE means user clicked OK or Cancel |
182 | lUser1 | long | storage for your application |
186 | lUser2 | long | storage for your application |
190 | lUser3 | long | storage for your application |
194 | lUser4 | long | storage for your application |
TPrPort Data Structure
0 | gPort | 178 bytes | graphics port and procedures for printing |
Trap Macros
Trap Macros Requiring Routine Selectors
_PrGlue
Selector | Routine |
$C8000000 | PrOpen |
$D0000000 | PrClose |
$20040480 | PrintDefault |
$52040498 | PrValidate |
$2A040484 | PrStlDialog |
$32040488 | PrJobDialog |
$4A040894 | PrDlgMain |
$3C04040C | PrStlInit |
$44040410 | PrJobInit |
$5804089C | PrJobMerge |
$04000C00 | PrOpenDoc |
$08000484 | PrCloseDoc |
$10000808 | PrOpenPage |
$1800040C | PrClosePage |
$60051480 | PrPicFile |
$BA000000 | PrError |
$C0000200 | PrSetError |
$70070480 | PrGeneral |
$94000000 | PrDrvrDCE |
$9A000000 | PrDrvrVers |
$80000000 | PrDrvrOpen |
$88000000 | PrDrvrClose |
$A0000E00 | PrCtlCall |
Global Variable
Result Codes
iPrAbort | 128 | Application or user requested cancel |
opNotImpl | 2 | Requested PrGeneral opcode not implemented in the current printer driver |
noSuchRsl | 1 | Resolution requested with the PrGeneral procedure is not supported |
noErr | 0 | No error |
iPrSavPFil | -1 | Problem saving print file |
controlErr | -17 | Unimplemented control instructions; the Device Manager returns this result code |
iIOAbort | -27 | I/O error |
iMemFullErr | -108 | There is not enough room in the heap zone |
resNotFound | -192 | The current printer driver does not support PrGeneral ; you should clear this error with a call to PrSetError with a parameter value of 0; otherwise, PrError might still contain this error next time you check it |
PAPNoCCBs | -4096 | There are no free connect control blocks (CCBs) available |
PAPBadRefnum | -4097 | Bad connection reference number |
PAPActive | -4098 | The request is already active |
PAPTooBig | -4099 | The write request is too big |
PAPConnClosed | -4100 | The connection is closed |
PAPNoPrinter | -4101 | The printer is not found, is closed, or is not selected |
| -8131 | Printer not responding |
manualFeedTOErr | -8132 | A timeout occurred (that is, no communication has occurred with the printer for two minutes); this is usually caused by an extremely long imaging time or a dropped connection |
generalPSErr | -8133 | A PostScript error occurred during transmission of data to the printer; this is most often caused by a bug in the application-supplied PostScript code |
zoomRangeErr | -8160 | The print image enlarged by the user with the Page Setup dialog box overflows the available page resolution |
errBadFontKeyType | -8976 | Font found in printer is not Type 1, TrueType, or bitmapped font |
errPSStateUnderflow | -8977 | PostScript stack underflow while restoring graphics state |
errNoPattern | -8978 | The pixel pattern could not be found and could not be built |
errBadConverterID | -8979 | The 'PDEF' converter doesn't exist |
errNoPagesSpooled | -8980 | Application called PrOpenDoc and PrCloseDoc without calling PrOpenPage and PrClosePage in between |
errNullColorInfo | -8981 | The getColor function called with null GetColorInfo handle |
errPSFileNameNull | -8982 | The filename pointer for the spool file is null |
errSpoolFolderIsAFile | -8983 | The spool folder is a file instead of a folder |
errBadConverterIndex | -8984 | When saving a spool file to disk, the value fileTypeIndex field had no matching entry in the driver |
errDidNotDownloadFont | -8985 | A PostScript outline could not be found for a PostScript font, and there is no associated 'sfnt' resource |
errBitmapFontMissing | -8986 | Unable to build bitmap for font |
errPSFileName | -8987 | PostScript file isn't named |
errCouldNotMakeNumberedFilename | -8989 | Could not make a unique filename for the spool file |
errBadSpoolFileVersion | -8990 | Bad version number in header of spool file |
errNoProcSetRes | -8991 | The resource describing needed procedure sets is unavailable for the PostScript prolog |
errInLineTimeout | -8993 | The printer is not responding |
errUnknownPSLevel | -8994 | The PostScript level has an unknown value |
errFontNotFound | -8995 | Font query reply didn't match any fonts in list of PostScript names |
errSizeListBad | -8996 | The size list contained an entry that could not be reconciled with the typeface list |
errFaceListBad | -8997 | Entry could not be found in typeface list |
errNotAKey | -8998 | Key for desired font number and style could not be found in font table |