Options
All
  • Public
  • Public/Protected
  • All
Menu
deprecated

for the old WebKit backend rendering only. For the new Chrome backend, see the IPdfOptions documentation. options specific to rendering pdfs. IMPORTANT NOTE: we strongly recommend using px as your units of measurement.

example
{
border: "0",
footer: {
firstPage: "", height: "1cm", lastPage: "", onePage: "", repeating: "<h1><span style='float:right'>%pageNum%/%numPages%</span></h1>"
},
format: "letter",
header: {
firstPage: "", height: "0cm", lastPage: "", onePage: "", repeating: ""
},
height: "11in",
orientation: "portrait",
width: "8.5in",     }

Hierarchy

  • IPdfOptions_WebKit

Index

Properties

Optional border

border: string

Border is optional and defaults to 0. A non-uniform border can be specified in the form {left: '2cm', top: '2cm', right: '2cm', bottom: '3cm'} Use of px is strongly recommended.

Optional dpi

dpi: number

set the DPI for pdf generation. defaults to 150, which causes each page to be 2x as large (use "fit to paper" when printing) If you want exact, proper page dimensions, set this to 72.

Optional footer

settings for footers of the pdf

Optional format

format: string

Supported formats are: 'A3', 'A4', 'A5', 'Legal', 'Letter', 'Tabloid'. .

Optional header

settings for headers of the pdf

Optional height

height: string

height and width are optional if format is specified. Use of px is strongly recommended. Supported dimension units are: 'mm', 'cm', 'in', 'px'. No unit means 'px'.

Optional orientation

orientation: string

optional. ('portrait', 'landscape') and defaults to 'portrait'

Optional width

width: string

height and width are optional if format is specified. Use of px is strongly recommended. Supported dimension units are: 'mm', 'cm', 'in', 'px'. No unit means 'px'.