Name
  doc:AddPage -- add new page to document
Synopsis

      page = doc:AddPage()

Function
  `doc:AddPage()` creates a new page and adds it after the last page of a document.

  `doc:AddPage()` returns the handle of created page object on success. Otherwise, it returns an error code and the error handler is called.

Inputs
  none

Results
  page
    handle to a page
Errors
  `#HPDF_INVALID_DOCUMENT` - An invalid document handle was set.

  `#HPDF_FAILED_TO_ALLOC_MEM` - Memory allocation failed.

Show TOC