Skip to content

RenderOptions

@scaryterry/pdfium


Defined in: src/core/types.ts:162

Options for rendering a PDF page.

optional backgroundColour: number

Defined in: src/core/types.ts:172

Background colour as ARGB integer (default: 0xFFFFFFFF - white)


optional clipRect: Rect

Defined in: src/core/types.ts:185

Clip rectangle in page coordinates for sub-region rendering.

When specified, only the portion of the page within this rectangle is rendered. The output bitmap dimensions still match the full page size (or the size determined by scale/width/height), but content outside the clip region is not drawn.

Coordinates are in PDF page points (1/72 inch).


optional height: number

Defined in: src/core/types.ts:168

Target height in pixels (overrides scale)


optional onProgress: ProgressCallback

Defined in: src/core/types.ts:187

Progress callback (0.0 to 1.0).


optional renderFormFields: boolean

Defined in: src/core/types.ts:170

Include form fields in render (default: false)


optional rotation: PageRotation

Defined in: src/core/types.ts:174

Rotation to apply during rendering (default: PageRotation.None)


optional scale: number

Defined in: src/core/types.ts:164

Scale factor (default: 1)


optional width: number

Defined in: src/core/types.ts:166

Target width in pixels (overrides scale)