DARenderPageToDC
Direct access functionality, Rendering and printing
Description
Renders the specified page from the specified document directly onto a graphics surface. On Windows the target surface is a Device Context handle (DC).
By default rendering uses the GDI+ system which is available in Windows XP and later.
It is also possible to render using Cairo, use the SetCairoFileName and SelectRenderer
functions.
Syntax
Delphi
function TPDFlib.DARenderPageToDC(FileHandle, PageRef: Integer; DPI: Double; DC: HDC): Integer;ActiveX
Function PDFlib::DARenderPageToDC(FileHandle As Long, PageRef As Long, DPI As Double, DC As Variant) As LongDLL
int DLDARenderPageToDC(int InstanceID, int FileHandle, int PageRef, double DPI, int DC);Parameters
| FileHandle | A handle returned by the DAOpenFile, DAOpenFileReadOnly or DAOpenFromStream functions |
|---|---|
| PageRef | A page reference returned by the DAFindPage or DANewPage functions |
| DPI | The DPI to use when rendering the page |
| DC | The device context handle |
Return values
| 0 | The page could not be rendered |
|---|---|
| 1 | The page was rendered successfully double DPI, HDC DC); |