Simulation support:

This function is mandatory for hardcopy drivers and must be implemented in order to have a valid OS/2 hardcopy driver. For other drivers, it is simulated by a handling routine in the graphics engine.

Description:

GreEscape DEVESC_STARTDOC starts a new document. The handling routine in the presentation driver does whatever initialization is required to spool or print the document.

Note: DEVESC_STARTDOC is mandatory at the API for an OD_QUEUED device with PM_Q_STD data.

#define INCL_GRE_DEVICE
#include <os2.h>

HDC      hdc;         /*  Device context handle. */
LONG     lEscape;     /*  DEVESC_STARTDOC escape code. */
LONG     cInCount;    /*  Number of bytes pointed to by pInData. */
PBYTE    pInData;     /*  Pointer to a string containing the name of the document. */
PLONG    pcOutCount;  /*  The handling routine ignores this parameter. */
PLONG    pOutData;    /*  The handling routine ignores this parameter. */
PVOID    pInstance;   /*  Pointer to instance data. */
ULONG    lFunction;   /*  High-order WORD=flags; low-order WORD=NGreEscape. */
LONG     rc;          /*  Return Code. */

rc = GreEscape(hdc, lEscape, cInCount, pInData,
       pcOutCount, pOutData, pInstance, lFunction);


[Back: GreEscape DEVESC_STARTDOC]
[Next: GreEscape DEVESC_STARTDOC Parameter - hdc]