PdfEditorAddHtmlTemplate(Int32, Int32, Int32, Int32, String, String) Method
Creates a HTML Template object to be rendered in PDF pages based on the HTML string and an optional base URL.
The height of template is fixed. If AutoResizeHeight is true, the HTML content may be scaled down to fit the
specified height
Namespace: HiQPdf.ChromiumAssembly: HiQPdf.Chromium (in HiQPdf.Chromium.dll) Version: 17.0.0
public PdfHtmlTemplate AddHtmlTemplate(
int x,
int y,
int width,
int height,
string html,
string htmlBaseUrl
)
- x Int32
- The X position of the template in the PDF pages relative to the top left of the page
- y Int32
- The Y position of the template in the PDF pages relative to the top left of the page
- width Int32
- The width of the PDF template
- height Int32
- The height of the PDF template
- html String
- The HTML content of the template. It can contain template variable like {page_number} or {total_pages}
- htmlBaseUrl String
- The base URL used to resolve external resources in the HTML
PdfHtmlTemplateThe created HTML template which can be further customized