PDFiumVCL Docs

SetPdfPrintPaperHandlingDevMode function

Dieser API-Eintrag behält Bezeichner, Signaturen, Codeblöcke und PDF-Begriffe in ihrer Originalform.
Component: TPdf  ·  Unit: PDFium
Maps a PDF PrintPaperHandling duplex hint into a Windows printer DEVMODE.

Syntax

function SetPdfPrintPaperHandlingDevMode(var DevMode: TDeviceMode; PrintPaperHandling: TPrintPaperHandling): Boolean;

Description

SetPdfPrintPaperHandlingDevMode converts the PDF viewer-preference duplex enum into the Windows printer-driver fields used by GDI print jobs.

For mapped values the function also marks DM_DUPLEX in DEVMODE.dmFields and returns True. For phUndefined it returns False and leaves the supplied DEVMODE unchanged.

Example

if SetPdfPrintPaperHandlingDevMode(DevMode, Pdf1.PrintPaperHandling) then
  ApplyPrinterDevMode(DevMode);

See Also

PrintPaperHandling, PrintCopies, PrintScaling, SetPdfPrintMode