procedure CreateDocument;
Creates a brand-new empty in-memory PDF document; requires Active to be False (calling CreateDocument while a document is already open raises EPdfError)
The new document has zero pages until AddPage / ImportPages is called
Wraps the corresponding PDFium API and exposes it as a TPdf instance member so consumers do not have to manage FPDF_DOCUMENT handles directly
Pdf1.Active := False before calling CreateDocument; calling it on an active component raises EPdfErrorSaveAs to persistPDFium (LoadLibrary / UnloadLibrary / GetRecommendedV8Flags) can be called without a TPdf instance
Pdf1.CreateDocument;
Pdf1.AddPage(1, 595, 842);