Printer Escapes Under Windows 95Last reviewed: September 29, 1995Article ID: Q125692 |
The information in this article applies to:
SUMMARYPrinter escapes are used to access special printer device features and have been used widely in Windows version 3.x. With Windows 95, Microsoft is encouraging application developers to move away from these escapes by providing GDI functionality to replace them. For example, a Win32-based application should not call the NEXTBAND and BANDINFO escapes. Banding is no longer needed in Windows 95. Most of these escapes, however, are still provided for 16-bit-based applications for backwards compatibility. The only recommended escapes for 32-bit, Windows 95-based applications are the QUERYESCSUPPORT and PASSTHROUGH escapes.
MORE INFORMATIONApplications written for Windows version 3.x can use the QUERYESCSUPPORT and the PASSTHROUGH escapes, as well as the following 10 escapes. It is important to note that these escapes are only supported for backwards compatibility. All new Windows 95-based applications should use Win32 API that replaces these escapes:
ABORTDOC ENDDOC GETPHYSPAGESIZE GETPRINTINGOFFSET GETSCALINGFACTOR NEWFRAME NEXTBAND SETABORTPROC SETCOPYCOUNT STARTDOCThe following functions should always be used in place of a printer escape:
Function Printer Escape Replaced ---------------------------------------- AbortDoc ABORTDOC EndDoc ENDDOC EndPage NEWFRAME SetAbortProc SETABORTPROC StartDoc STARTDOCWindows 95 provides six new indexes for the GetDeviceCaps function that replace some additional printer escapes:
Index for GetDeviceCaps Printer Escape Replaced -------------------------------------------------------- PHYSICALWIDTH GETPHYSPAGESIZE PHYSICALHEIGHT GETPHYSPAGESIZE PHYSICALOFFSETX GETPRINTINGOFFSET PHYSICALOFFSETY GETPRINTINGOFFSET SCALINGFACTORX GETSCALINGFACTOR SCALINGFACTORY GETSCALINGFACTORAlthough a lot of the escapes have been replaced with Win32 GDI equivalent APIs, not all device-dependent escapes have been replaced. It is up to the printer driver manufacturer to decide whether or not its Windows 95-based driver will contain device-specific escapes that were present in its Windows version 3.x driver. An example of a device-specific escape would be the Windows version 3.x PostScript driver's POSTSCRIPT_IGNORE escape. Before calling any of these escapes, an application must first call the QUERESCSUPPORT escape to find out if the escape is supported or not.
|
Additional reference words: 4.00
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |