Devmode Structure Printer Driver

  1. Hp Printer Drivers For Windows 10
  2. Devmode Structure Printer Driver Windows 10
  3. Devmode Structure Printer Driver Free
  4. Devmode Printer

Each page has its own Dialog procedure to. Hadle the messages. But I don't know how to return the document properties. (like paper size, orientation displayed on prop sheets) from Dialog procedure back to DrvDocumentPropertySheets so. That it can populate dmOut with the changed values. Thanks in advance. Specifies the version number of the initialization data specification on which the structure is based. Specifies the printer driver version number assigned by the printer driver developer. Specifies the size, in bytes, of the DEVMODE structure except the dmDriverData (device-specific) member. If an application. Only be used to set printer model specific features, like stapler, etc. The Windows API 'DevMode' structure is used by Windows and the Printer Driver to define the printer setup. The name DevMode is short for DeviceMode.-Nard Moseley Digital Metaphors www.digital-metaphors.com. If you are truly using raw printer output, OpenPrinter etc, then changing DEVMODE will not have any effect, you are bypassing the printer driver. It is then completely up to you to rotate output. Quite painful if the printer itself doesn't support it. The kind where bypassing the driver makes sense never do. – Hans Passant Mar 18 '13 at 15:24.

GUI ScreenIOfor WindowsScreenIO.com

The GS-DEVMODE-DATA resides in the GSPRTDEF.COB copybook. This copybook holds what Microsoft calls DEVMODE data (Device Mode data) which is used to pass data to the printer sub-system to set up the printer.

The PrintDlg API will invoke the Standard Printer Dialog, and return this information to you in this data structure. The OpenPrinter API and the PrintFile API will pass this data to the printer. You may make changes to this information by using any of the settings provided in 88 items below. You need to set only those that are of interest to you, and you can allow the rest to default to the printer's default settings.

The definitions of the data names are below.

DMDEVICENAME
Specifies the 'friendly' name of the printer or display; for example, 'PCL/HP LaserJet' in the case of PCL/HP LaserJet. This string is unique among device drivers. Note that this name may be truncated to fit in the DMDEVICENAME array.
DMSPECVERSION
Specifies the version number of the initialization data specification on which the structure is based.
DMDRIVERVERSION
Specifies the driver version number assigned by the driver developer.
DMSIZE
Specifies the size, in bytes, of the DEVMODE portion of this structure, not including any auxiliary data that might follow.
DMDRIVEREXTRA
Contains the number of bytes of auxiliary driver-data that follow this structure. This may be zero.
DMFIELDS
Specifies whether certain items in structure have been initialized. If a field is initialized, its corresponding bit is set, otherwise the bit is clear.
DMORIENTATION
Devmode
For printer devices only, selects the orientation of the paper. This field can be either DMORIENT-PORTRAIT (1) or DMORIENT-LANDSCAPE (2).
DMPAPERSIZE
For printer devices only, selects the size of the paper to print on. This field can be set to zero if the length and width of the paper are both set by the DMPAPERLENGTH and DMPAPERWIDTH fields. Otherwise, the DevmodeDMPAPERSIZE field can be set to one of the following predefined values.
ValueMeaning
DMPAPER-LETTERLetter, 8 1/2- by 11-inches
DMPAPER-LEGALLegal, 8 1/2- by 14-inches
DMPAPER-10X1410- by 14-inch sheet
DMPAPER-11X1711- by 17-inch sheet
DMPAPER-12X11Windows 98/Me, Windows NT 4.0 and later: 12- by 11-inch sheet
DMPAPER-A3A3 sheet, 297- by 420-millimeters
DMPAPER-A3-ROTATEDWindows 98/Me, Windows NT 4.0 and later: A3 rotated sheet, 420- by 297-millimeters
DMPAPER-A4A4 sheet, 210- by 297-millimeters
DMPAPER-A4-ROTATEDWindows 98/Me, Windows NT 4.0 and later: A4 rotated sheet, 297- by 210-millimeters
DMPAPER-A4SMALLA4 small sheet, 210- by 297-millimeters
DMPAPER-A5A5 sheet, 148- by 210-millimeters
DMPAPER-A5-ROTATEDWindows 98/Me, Windows NT 4.0 and later: A5 rotated sheet, 210- by 148-millimeters
DMPAPER-A6Windows 98/Me, Windows NT 4.0 and later: A6 sheet, 105- by 148-millimeters
DMPAPER-A6-ROTATEDWindows 98/Me, Windows NT 4.0 and later: A6 rotated sheet, 148- by 105-millimeters
DMPAPER-B4B4 sheet, 250- by 354-millimeters
DMPAPER-B4-JIS-ROTATEDWindows 98/Me, Windows NT 4.0 and later: B4 (JIS) rotated sheet, 364- by 257-millimeters
DMPAPER-B5B5 sheet, 182- by 257-millimeter paper
DMPAPER-B5-JIS-ROTATEDWindows 98/Me, Windows NT 4.0 and later: B5 (JIS) rotated sheet, 257- by 182-millimeters
DMPAPER-B6-JISWindows 98/Me, Windows NT 4.0 and later: B6 (JIS) sheet, 128- by 182-millimeters
DMPAPER-B6-JIS-ROTATEDWindows 98/Me, Windows NT 4.0 and later: B6 (JIS) rotated sheet, 182- by 128-millimeters
DMPAPER-CSHEETC Sheet, 17- by 22-inches
DMPAPER-DBL-JAPANESE-POSTCARDWindows 98/Me, Windows NT 4.0 and later: Double Japanese Postcard, 200- by 148-millimeters
DMPAPER-DBL-JAPANESE-POSTCARD-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Double Japanese Postcard Rotated, 148- by 200-millimeters
DMPAPER-DSHEETD Sheet, 22- by 34-inches
DMPAPER-ENV-9#9 Envelope, 3 7/8- by 8 7/8-inches
DMPAPER-ENV-10#10 Envelope, 4 1/8- by 9 1/2-inches
DMPAPER-ENV-11#11 Envelope, 4 1/2- by 10 3/8-inches
DMPAPER-ENV-12#12 Envelope, 4 3/4- by 11-inches
DMPAPER-ENV-14#14 Envelope, 5- by 11 1/2-inches
DMPAPER-ENV-C5C5 Envelope, 162- by 229-millimeters
DMPAPER-ENV-C3C3 Envelope, 324- by 458-millimeters
DMPAPER-ENV-C4C4 Envelope, 229- by 324-millimeters
DMPAPER-ENV-C6C6 Envelope, 114- by 162-millimeters
DMPAPER-ENV-C65C65 Envelope, 114- by 229-millimeters
DMPAPER-ENV-B4B4 Envelope, 250- by 353-millimeters
DMPAPER-ENV-B5B5 Envelope, 176- by 250-millimeters
DMPAPER-ENV-B6B6 Envelope, 176- by 125-millimeters
DMPAPER-ENV-DLDL Envelope, 110- by 220-millimeters
DMPAPER-ENV-ITALYItaly Envelope, 110- by 230-millimeters
DMPAPER-ENV-MONARCHMonarch Envelope, 3 7/8- by 7 1/2-inches
DMPAPER-ENV-PERSONAL6 3/4 Envelope, 3 5/8- by 6 1/2-inches
DMPAPER-ESHEETE Sheet, 34- by 44-inches
DMPAPER-EXECUTIVEExecutive, 7 1/4- by 10 1/2-inches
DMPAPER-FANFOLD-USUS Std Fanfold, 14 7/8- by 11-inches
DMPAPER-FANFOLD-STD-GERMANGerman Std Fanfold, 8 1/2- by 12-inches
DMPAPER-FANFOLD-LGL-GERMANGerman Legal Fanfold, 8 - by 13-inches
DMPAPER-FOLIOFolio, 8 1/2- by 13-inch paper
DMPAPER-JAPANESE-POSTCARD-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Postcard Rotated, 148- by 100-millimeters
DMPAPER-JENV-CHOU3Windows 98/Me, Windows NT 4.0 and later: Japanese Envelope Chou #3
DMPAPER-JENV-CHOU3-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Envelope Chou #3 Rotated
DMPAPER-JENV-CHOU4Windows 98/Me, Windows NT 4.0 and later: Japanese Envelope Chou #4
DMPAPER-JENV-CHOU4-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Envelope Chou #4 Rotated
DMPAPER-JENV-KAKU2Windows 98/Me, Windows NT 4.0 and later: Japanese Envelope Kaku #2
DMPAPER-JENV-KAKU2-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Envelope Kaku #2 Rotated
DMPAPER-JENV-KAKU3Windows 98/Me, Windows NT 4.0 and later: Japanese Envelope Kaku #3
DMPAPER-JENV-KAKU3-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Envelope Kaku #3 Rotated
DMPAPER-JENV-YOU4Windows 98/Me, Windows NT 4.0 and later: Japanese Envelope You #4
DMPAPER-JENV-YOU4-ROTATEDWindows 98/Me, Windows NT 4.0 and later: Japanese Envelope You #4 Rotated
DMPAPER-LASTWindows 2000/XP: DMPAPER-PENV-10-ROTATED
DMPAPER-LEDGERLedger, 17- by 11-inches
DMPAPER-LETTER-ROTATEDLetter Rotated 11 by 8 1/2 11 inches
DMPAPER-LETTERSMALLLetter Small, 8 1/2- by 11-inches
DMPAPER-NOTENote, 8 1/2- by 11-inches
DMPAPER-P16KWindows 98/Me, Windows NT 4.0 and later: PRC 16K, 146- by 215-millimeters
DMPAPER-P16K-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC 16K Rotated, 215- by 146-millimeters
DMPAPER-P32KWindows 98/Me, Windows NT 4.0 and later: PRC 32K, 97- by 151-millimeters
DMPAPER-P32K-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC 32K Rotated, 151- by 97-millimeters
DMPAPER-P32KBIGWindows 98/Me, Windows NT 4.0 and later: PRC 32K(Big) 97- by 151-millimeters
DMPAPER-P32KBIG-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC 32K(Big) Rotated, 151- by 97-millimeters
DMPAPER-PENV-1Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #1, 102- by 165-millimeters
DMPAPER-PENV-1-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #1 Rotated, 165- by 102-millimeters
DMPAPER-PENV-2Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #2, 102- by 176-millimeters
DMPAPER-PENV-2-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #2 Rotated, 176- by 102-millimeters
DMPAPER-PENV-3Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #3, 125- by 176-millimeters
DMPAPER-PENV-3-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #3 Rotated, 176- by 125-millimeters
DMPAPER-PENV-4Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #4, 110- by 208-millimeters
DMPAPER-PENV-4-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #4 Rotated, 208- by 110-millimeters
DMPAPER-PENV-5Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #5, 110- by 220-millimeters
DMPAPER-PENV-5-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #5 Rotated, 220- by 110-millimeters
DMPAPER-PENV-6Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #6, 120- by 230-millimeters
DMPAPER-PENV-6-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #6 Rotated, 230- by 120-millimeters
DMPAPER-PENV-7Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #7, 160- by 230-millimeters
DMPAPER-PENV-7-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #7 Rotated, 230- by 160-millimeters
DMPAPER-PENV-8Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #8, 120- by 309-millimeters
DMPAPER-PENV-8-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #8 Rotated, 309- by 120-millimeters
DMPAPER-PENV-9Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #9, 229- by 324-millimeters
DMPAPER-PENV-9-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #9 Rotated, 324- by 229-millimeters
DMPAPER-PENV-10Windows 98/Me, Windows NT 4.0 and later: PRC Envelope #10, 324- by 458-millimeters
DMPAPER-PENV-10-ROTATEDWindows 98/Me, Windows NT 4.0 and later: PRC Envelope #10 Rotated, 458- by 324-millimeters
DMPAPER-QUARTOQuarto, 215- by 275-millimeter paper
DMPAPER-STATEMENTStatement, 5 1/2- by 8 1/2-inches
DMPAPER-TABLOIDTabloid, 11- by 17-inches
DMPAPERLENGTH
For printer devices only, overrides the length of the paper specified by the DMPAPERSIZE field, either for custom paper sizes or for devices such as dot-matrix printers that can print on a page of arbitrary length. These values, along with all other values in this structure that specify a physical length, are in tenths of a millimeter.
DMPAPERWIDTH
For printer devices only, overrides the width of the paper specified by the DMPAPERSIZE field.
DMSCALE
Specifies the factor by which the printed output is to be scaled. The apparent page size is scaled from the physical page size by a factor of DMSCALE/100. For example, a letter-sized page with a DMSCALE value of 50 would contain as much data as a page of 17- by 22-inches because the output text and graphics would be half their original height and width. nORMALLY SET TO 100.
DMCOPIES
Selects the number of copies printed if the device supports multiple-page copies.
DMDEFAULTSOURCE
Specifies the paper source. To retrieve a list of the available paper sources for a printer. This field can be one of the following values, or it can be a device-specific value greater than or equal to DMBIN-USER.
DMBIN-AUTO
DMBIN-CASSETTE
DMBIN-ENVELOPE
DMBIN-ENVMANUAL
DMBIN-FORMSOURCE
DMBIN-LARGECAPACITY
DMBIN-LARGEFMT
DMBIN-LOWER
DMBIN-MANUAL
DMBIN-MIDDLE
DMBIN-ONLYONE
DMBIN-TRACTOR
DMBIN-SMALLFMT

DMPRINTQUALITY
Specifies the printer resolution. There are four predefined device-independent values: (NEGATIVE values)

DMRES-HIGH
DMRES-MEDIUM
DMRES-LOW
DMRES-DRAFT

If a positive value is specified, it specifies the number of dots per inch (DPI) and is therefore device dependent.

DMCOLOR
Switches between color and monochrome on color printers. Following are the possible values:

DMCOLOR-COLOR
DMCOLOR-MONOCHROME

DMDUPLEX
Selects duplex or double-sided printing for printers capable of duplex printing. Following are the possible values.
ValueMeaning
DMDUP-SIMPLEXNormal (nonduplex) printing.
DMDUP-HORIZONTALShort-edge binding, that is, the long edge of the page is horizontal.
DMDUP-VERTICALLong-edge binding, that is, the long edge of the page is vertical.

DMYRESOLUTION
Specifies the y-resolution, in dots per inch, of the printer. If the printer initializes this field, the DMPRINTQUALITY field specifies the x-resolution, in dots per inch, of the printer.
DMTTOPTIONS
Specifies how TrueType fonts should be printed. This field can be one of the following values.
ValueMeaning
DMTT-BITMAPPrints TrueType fonts as graphics. This is the default action for dot-matrix printers.
DMTT-DOWNLOADDownloads TrueType fonts as soft fonts. This is the default action for Hewlett-Packard printers that use Printer Control Language (PCL).
DMTT-DOWNLOAD-OUTLINEWindow 95/98/Me, Windows NT 4.0 and later: Downloads TrueType fonts as outline soft fonts.
DMTT-SUBDEVSubstitutes device fonts for TrueType fonts. This is the default action for PostScript printers.

DMCOLLATE
Specifies whether collation should be used when printing multiple copies. (This field is ignored unless the printer driver includes support for collation. This field can be one of the following values.
ValueMeaning
DMCOLLATE-TRUECollate when printing multiple copies.
DMCOLLATE-FALSEDo not collate when printing multiple copies.

DMFORMSNAME
Windows NT/2000/XP: Specifies the name of the form to use; for example, 'Letter' or 'Legal'.

Windows 95/98/Me: Printer drivers do not use this field.

DMNUP
Specifies where the NUP is done. It can be one of the following. NUP = N Up, as in 3-up labels etc.
ValueMeaning
DMNUP-SYSTEMThe print spooler does the NUP.
DMNUP-ONEUPThe application does the NUP.

DMICMMETHOD
Windows 95/98/Me; Windows 2000/XP: Specifies how ICM is handled. For a non-ICM application, this field determines if ICM is enabled or disabled. For ICM applications, the system examines this field to determine how to handle ICM support. This field can be one of the following predefined values, or a driver-defined value greater than or equal to the value of DMICMMETHOD-USER.
ValueMeaning
DMICMMETHOD-NONESpecifies that ICM is disabled.
DMICMMETHOD-SYSTEMSpecifies that ICM is handled by Windows.
DMICMMETHOD-DRIVERSpecifies that ICM is handled by the device driver.
DMICMMETHOD-DEVICESpecifies that ICM is handled by the destination device.

The printer driver must provide a user interface for setting this field. Most printer drivers support only the DMICMMETHOD-SYSTEM or DMICMMETHOD-NONE value. Drivers for PostScript printers support all values.

CMICMINTENT
Windows 95/98/Me, Windows 2000/XP: Specifies which color matching method, or intent, should be used by default. This field is primarily for non-ICM applications. ICM applications can establish intents by using the ICM functions. This field can be one of the following predefined values, or a driver defined value greater than or equal to the value of DMICM-USER.
ValueMeaning
DMICM-ABS-COLORIMETRICColor matching should optimize to match the exact color requested without white point mapping. This value is most appropriate for use with proofing.
DMICM-COLORMETRICColor matching should optimize to match the exact color requested. This value is most appropriate for use with business logos or other images when an exact color match is desired.
DMICM-CONTRASTColor matching should optimize for color contrast. This value is the most appropriate choice for scanned or photographic images when dithering is desired.
DMICM-SATURATEColor matching should optimize for color saturation. This value is the most appropriate choice for business graphs when dithering is not desired.

DMMEDIATYPE
Windows 95/98/Me, Windows 2000/XP:Structure Specifies the type of media being printed on. The field can be one of the following predefined values, or a driver-defined value greater than or equal to the value of DMMEDIA-USER.

Hp Printer Drivers For Windows 10

ValueMeaning
DMMEDIA-STANDARDPlain paper.
DMMEDIA-GLOSSYGlossy paper.
DMMEDIA-TRANSPARENCYTransparent film.

Printer driver epson
DMDITHERTYPE
Windows 95/98/Me, Windows 2000/XP: Specifies how dithering is to be done. The field can be one of the following predefined values, or a driver-defined value greater than or equal to the value of DMDITHER-USER. Windows

Devmode Structure Printer Driver Windows 10

ValueMeaning
DMDITHER-NONENo dithering.
DMDITHER-COARSEDithering with a coarse brush.
DMDITHER-FINEDithering with a fine brush.
DMDITHER-LINEARTLine art dithering, a special dithering method that produces well defined borders between black, white, and gray scaling. It is not suitable for images that include continuous graduations in intensity and hue, such as scanned photographs.
DMDITHER-ERRORDIFFUSIONWindows 95/98/Me: Dithering in which an algorithm is used to spread, or diffuse, the error of approximating a specified color over adjacent pixels. In contrast, DMDITHER-COARSE, DMDITHER-FINE, and DMDITHER-LINEART use patterned halftoning to approximate a color.
DMDITHER-GRAYSCALEDevice does gray scaling.
DM-RESERVED
(just what it says)
© 2000-2019 Norcom, all rights reserved

Devmode Structure Printer Driver Free

DeviceCapabilities

Devmode Printer

Description

The DeviceCapabilities function retrieves the capabilities of a printer device driver.

C++ Syntax

DWORD DeviceCapabilities(

__in LPCTSTR pDevice,

__in LPCTSTR pPort,

__in WORD fwCapability,

__out LPTSTR pOutput,

__in const DEVMODE *pDevMode

);

PowerBASIC Syntax

FUNCTION DeviceCapabilities ( _

BYREF pDevice AS ASCIIZ, _

BYREF pPort AS ASCIIZ, _

BYVAL fwCapability AS WORD, _

BYREF pOutput AS ASCIIZ, _

BYREF pDevMode AS DEVMODE _

) AS DWORD

Unicode version:

FUNCTION DeviceCapabilitiesW ( _

BYVAL pDevice AS DWORD, _

BYVAL pPort AS DWORD, _

BYVAL fwCapability AS WORD, _

BYVAL pOutput AS DWORD, _

BYREF pDevMode AS DEVMODEW _

) AS DWORD

Parameters

pDevice

[in] Pointer to a null-terminated string that contains the name of the printer. Note that this is the name of the printer, not of the printer driver.

pPort

[in] Pointer to a null-terminated string that contains the name of the port to which the device is connected, such as LPT1.

fwCapability

[in] Specifies the capabilities to query. This parameter can be one of the following values.

DC_BINADJUST

Windows 95/98/Me: Retrieves the page positioning for the paper source specified in the DEVMODE structure pointed to by pdevMode. The return value can be one of the following:

DCBA_FACEUPNONE

DCBA_FACEUPCENTER

DCBA_FACEUPLEFT

DCBA_FACEUPRIGHT

DCBA_FACEDOWNNONE

DCBA_FACEDOWNCENTER

DCBA_FACEDOWNLEFT

DCBA_FACEDOWNRIGHT

Windows NT/2000/XP: Not supported.

DC_BINNAMES

Retrieves the names of the printer's paper bins. The pOutput buffer receives an array of string buffers. Each string buffer is 24 characters long and contains the name of a paper bin. The return value indicates the number of entries in the array. The name strings are null-terminated unless the name is 24 characters long. If pOutput is NULL, the return value is the number of bin entries required.

DC_BINS

Retrieves a list of available paper bins. The pOutput buffer receives an array of WORD values that indicate the available paper sources for the printer. The return value indicates the number of entries in the array. For a list of the possible array values, see the description of the dmDefaultSource member of the DEVMODE structure. If pOutput is NULL, the return value indicates the required number of entries in the array.

DC_COLLATE

If the printer supports collating, the return value is 1; otherwise, the return value is zero. The pOutput parameter is not used.

DC_COLORDEVICE

Windows 2000/XP: If the printer supports color printing, the return value is 1; otherwise, the return value is zero. The pOutput parameter is not used.

DC_COPIES

Returns the number of copies the device can print.

DC_DRIVER

Returns the version number of the printer driver.

DC_DATATYPE_PRODUCED

Windows 95/98/Me: The return value is the number of data types supported by the printer driver. If the function returns -1, the driver recognizes only the 'RAW' data type. The names of the supported data types are copied to an array. Use the names in the DOCINFO structure when calling the StartDoc function to specify the data type.

Windows NT/2000/XP: Not supported.

DC_DUPLEX

If the printer supports duplex printing, the return value is 1; otherwise, the return value is zero. The pOutput parameter is not used.

DC_EMF_COMPLIANT

Windows 95/98/Me: Determines if a printer driver supports enhanced metafiles (EMF). A return value of 1 means the driver supports EMF. A return value of -1 means the driver does not support EMF.

Windows NT/2000/XP: Not supported.

DC_ENUMRESOLUTIONS

Retrieves a list of the resolutions supported by the printer. The pOutput buffer receives an array of LONG values. For each supported resolution, the array contains a pair of LONG values that specify the x and y dimensions of the resolution, in dots per inch. The return value indicates the number of supported resolutions. If pOutput is NULL, the return value indicates the number of supported resolutions.

DC_EXTRA

Returns the number of bytes required for the device-specific portion of the DEVMODE structure for the printer driver.

DC_FIELDS

Returns the dmFields member of the printer driver's DEVMODE structure. The dmFields member indicates which members in the device-independent portion of the structure are supported by the printer driver.

DC_FILEDEPENDENCIES

Retrieves the names of any additional files that need to be loaded when a driver is installed. The pOutput buffer receives an array of string buffers. Each string buffer is 64 characters long and contains the name of a file. The return value indicates the number of entries in the array. The name strings are null-terminated unless the name is 64 characters long. If pOutput is NULL, the return value is the number of files.

DC_MANUFACTURER

Windows 95/98/Me: The return value is the identification number of the printer manufacturer. This value is used with Image Color Management (ICM).

Windows NT/2000/XP: Not supported.

DC_MAXEXTENT

Returns the maximum paper size that the dmPaperLength and dmPaperWidth members of the printer driver's DEVMODE structure can specify. The LOWORD of the return value contains the maximum dmPaperWidth value, and the HIWORD contains the maximum dmPaperLength value.

DC_MEDIAREADY

Windows 2000/XP: Retrieves the names of the paper forms that are currently available for use. The pOutput buffer receives an array of string buffers. Each string buffer is 64 characters long and contains the name of a paper form. The return value indicates the number of entries in the array. The name strings are null-terminated unless the name is 64 characters long. If pOutput is NULL, the return value is the number of paper forms.

DC_MEDIATYPENAMES

Windows XP: Retrieves the names of the supported media types. The pOutput buffer receives an array of string buffers. Each string buffer is 64 characters long and contains the name of a supported media type. The return value indicates the number of entries in the array. The strings are null-terminated unless the name is 64 characters long. If pOutput is NULL, the return value is the number of media type names required.

DC_MEDIATYPES

Windows XP: Retrieves a list of supported media types. The pOutput buffer receives an array of DWORD values that indicate the supported media types. The return value indicates the number of entries in the array. For a list of possible array values, see the description of the dmMediaType member of the DEVMODE structure. If pOutput is NULL, the return value indicates the required number of entries in the array.

DC_MINEXTENT

Returns the minimum paper size that the dmPaperLength and dmPaperWidth members of the printer driver's DEVMODE structure can specify. The LOWORD of the return value contains the minimum dmPaperWidth value, and the HIWORD contains the minimum dmPaperLength value.

DC_MODEL

Windows 95/98/Me: The return value is the identification of the printer model. This value is used with Image Color Management (ICM).

Windows NT/2000/XP: Not supported.

DC_ORIENTATION

Returns the relationship between portrait and landscape orientations for a device, in terms of the number of degrees that portrait orientation is rotated counterclockwise to produce landscape orientation. The return value can be one of the following:

0 No landscape orientation.

90 Portrait is rotated 90 degrees to produce landscape.

270 Portrait is rotated 270 degrees to produce landscape.

DC_NUP

Windows 2000/XP: Retrieves an array of integers that indicate that printer's ability to print multiple document pages per printed page. The pOutput buffer receives an array of DWORD values. Each value represents a supported number of document pages per printed page. The return value indicates the number of entries in the array. If pOutput is NULL, the return value indicates the required number of entries in the array.

DC_PAPERNAMES

Retrieves a list of supported paper names (for example, Letter or Legal). The pOutput buffer receives an array of string buffers. Each string buffer is 64 characters long and contains the name of a paper form. The return value indicates the number of entries in the array. The name strings are null-terminated unless the name is 64 characters long. If pOutput is NULL, the return value is the number of paper forms.

DC_PAPERS

Retrieves a list of supported paper sizes. The pOutput buffer receives an array of WORD values that indicate the available paper sizes for the printer. The return value indicates the number of entries in the array. For a list of the possible array values, see the description of the dmPaperSize member of the DEVMODE structure. If pOutput is NULL, the return value indicates the required number of entries in the array.

DC_PAPERSIZE

Retrieves the dimensions, in tenths of a millimeter, of each supported paper size. The pOutput buffer receives an array of POINT structures. Each structure contains the width (x-dimension) and length (y-dimension) of a paper size as if the paper were in the DMORIENT_PORTRAIT orientation. The return value indicates the number of entries in the array.

DC_PERSONALITY

Windows 2000/XP: Retrieves a list of printer description languages supported by the printer. The pOutput buffer receives an array of string buffers. Each buffer is 32 characters long and contains the name of a printer description language. The return value indicates the number of entries in the array. The name strings are null-terminated unless the name is 32 characters long. If pOutput is NULL, the return value indicates the required number of array entries.

DC_PRINTERMEM

Windows 2000/XP: The return value is the amount of available printer memory, in kilobytes. The pOutput parameter is not used.

DC_PRINTRATE

Windows 2000/XP: The return value indicates the printer's print rate. The value returned for DC_PRINTRATEUNIT indicates the units of the DC_PRINTRATE value. The pOutput parameter is not used.

DC_PRINTRATEPPM

Windows 2000/XP: The return value indicates the printer's print rate, in pages per minute. The pOutput parameter is not used.

DC_PRINTRATEUNIT

Windows 2000/XP: The return value is one of the following values that indicate the print rate units for the value returned for the DC_PRINTRATE flag. The pOutput parameter is not used.

PRINTRATEUNIT_CPS

Characters per second.

PRINTRATEUNIT_IPM

Inches per minute.

PRINTRATEUNIT_LPM

Lines per minute.

PRINTRATEUNIT_PPM

Pages per minute.

DC_SIZE

Returns the dmSize member of the printer driver's DEVMODE structure.

DC_STAPLE

Windows 2000/XP: If the printer supports stapling, the return value is a nonzero value; otherwise, the return value is zero. The pOutput parameter is not used.

DC_TRUETYPE

Retrieves the abilities of the driver to use TrueType fonts. For DC_TRUETYPE, the pOutput parameter should be NULL. The return value can be one or more of the following:

DCTT_BITMAP

Device can print TrueType fonts as graphics.

DCTT_DOWNLOA

DDevice can down-load TrueType fonts.

DCTT_DOWNLOAD_OUTLINE

Windows 95/98/Me: Device can download outline TrueType fonts.

DCTT_SUBDEV

Device can substitute device fonts for TrueType fonts.

DC_VERSION

Returns the specification version to which the printer driver conforms.

pOutput

[out] Pointer to an array. The format of the array depends on the setting of the fwCapability parameter. If pOutput is NULL, DeviceCapabilities returns the number of bytes required for the output data.

pDevMode

[in] Pointer to a DEVMODE structure. If this parameter is NULL, DeviceCapabilities retrieves the current default initialization values for the specified printer driver. Otherwise, the function retrieves the values contained in the structure to which pDevMode points.

Return Value

If the function succeeds, the return value depends on the setting of the fwCapability parameter. A return value of zero generally indicates that, while the function completed successfully, there was some type of failure, such as a capability that is not supported. For more details, see the descriptions for the fwCapability values.

If the function returns -1, this may mean either that the capability is not supported or there was a general function failure.

Remarks

The DEVMODE structure pointed to by the pDevMode parameter may be obtained by calling the DocumentProperties function.