Providing DEVMODE Structure Additions

Important

We recommend that you use Microsoft's IPP inbox class driver, along with Print Support Apps (PSA), to customize the print experience in Windows 10 and 11 for printer device development.

For more information, see the Print support app design guide.

Your UI plug-in can add its own private members to the DEVMODEW structure, as illustrated in the following figure.

diagram illustrating public and private devmode sections.

A UI plug-in can use these private DEVMODE members to store values associated with customized printer options. The plug-in makes these options available to the user by modifying a driver-supplied property sheet page or by adding new property sheet pages.

If your UI plug-in adds private DEVMODE members, the OEM_DMEXTRAHEADER structure must prefix the added members.

You are not required to add members to the DEVMODE structure, but if you do, your UI plug-in must implement the IPrintOemUI::DevMode method. This method's purpose, depending on input arguments, is to return the size of, initialize, convert, or validate the additional DEVMODE members.