THotPDF Utility – metody

Tato stránka shromažďuje veřejné pomocné metody THotPDF, které pracují s existujícími PDF nebo provádějí čištění a analýzu v rozsahu dokumentu

File Encryption and Decryption

Method Popis
EncryptFile Encrypt an existing PDF directly from an input file to an output file. Overloads accept a THPDFKeyType plus THPDFProtectOptions, an integer strength plus permission mask, or the default encryption settings.
DecryptFile Decrypt an existing encrypted PDF to a new output file using the supplied password. The method returns 1 for success and 0 for failure, matching the Direct File API return style.
DecryptLoadedDocument Decrypt a document already loaded through LoadFromFile or LoadFromStream so it can later be saved as an unencrypted copy.

Page Splitting and Metadata Copy

Method Popis
SplitPDFToFiles Split selected logical pages from an input PDF into the corresponding output files. OutputFiles and LogicalPageIndices are parallel arrays; each selected page is written as a standalone document.
CopyDocumentMetadata Copy document information and related metadata from another THotPDF instance into the current document before output.

Optimization and Repair Helpers

Method Popis
OptimizeOverlappingImages Run a document-level cleanup pass for image-heavy content where overlapping image draws can be simplified before save.
FixImageClipping Repair image clipping state in page content where imported or edited content leaves clipping regions in a bad state for later output.
CalculateContentStreamScore, IsValidPageContentStream Inspect page content streams and classify whether they look usable for page-copy and repair workflows. These helpers are primarily useful for diagnostics and automated recovery paths.

Viz také