Поделиться через


SPCLPASSTHROUGH2 Printer Escape function

The SPCLPASSTHROUGH2 printer escape function allows applications that print to PostScript devices using EPSPRINTING to include private PostScript procedures and other resources at the document-level save context.

This escape is supported only for backward compatibility with Adobe Acrobat. Other applications should not use this obsolete escape.

To perform this operation, call the ExtEscape function with the following parameters.

Syntax

int ExtEscape(
  _In_  HDC    hdc,
  _In_  int    nEscape,
  _In_  int    cbInput,
  _In_  LPCSTR lpszInData,
  _In_  int    cbOutput,
  _Out_ LPSTR  lpszOutData
);

Parameters

  • hdc [in]
    A handle to the printer device context.

  • nEscape [in]
    The escape function to be performed.

    Value Meaning
    SPCLPASSTHROUGH2

    Enables applications to include private procedures and other resources at the document level-save context.

     

  • cbInput [in]
    The number of bytes of data pointed to by the lpszInData parameter.

  • lpszInData [in]
    A pointer to the input structure required for the specified escape.

  • cbOutput [in]
    The number of bytes of data pointed to by the lpszOutData parameter.

    For this printer escape function, the value of this parameter is 0.

  • lpszOutData [out]
    A pointer to the structure that receives output from this escape.

    For this printer escape function, the value of the parameter is NULL.

Return value

The return value specifies the outcome of the function. It is greater than zero if the function is successful, except for the QUERYESCSUPPORT printer escape, which checks for implementation only. The return value is zero if the escape is not implemented. A return value less than zero indicates an error.

Remarks

The application must call this escape before calling StartDoc so that the driver will cache the data for insertion at the correct point in the PostScript stream. If this escape is supported, the driver will also allow escape DOWNLOADFACE calls prior to StartDoc. The driver internally caches the data to be inserted and the data required by any escape DOWNLOADFACE calls prior to StartDoc and emits them all immediately before %%EndProlog. The sequence of SPCLPASSTHROUGH2 and DOWNLOADFACE calls will be preserved in the order their data is passed in, that is, a later call results in data output after an earlier call's data. The driver will consider fonts downloaded by pre-StartDoc escape DOWNLOADFACE calls as unavailable for removal during the scope of the job.

This escape is not recorded in EMF files by the operating system, therefore applications must ensure that EMF recording is turned off for those jobs using the escape.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Wingdi.h (include Windows.h)

See also

Printing

GDI Printer Escape Functions

ExtEscape