SoftZenPdf API reference
Generated from the XML documentation comments in the library source. For task-oriented explanations and complete examples, start with the Getting started guide under Docs in the menu above.
Where to begin
| To… | Start with |
|---|---|
| Create a document and draw on pages | PdfDocument, PdfPage, ContentStreamWriter |
| Use fonts | StandardFont, TrueTypeFont |
| Add images | PdfImage |
| Choose sizes and colours | PageSize, PdfColor |
| Add bookmarks, links, metadata, watermarks | PdfOutline, AddLink, PdfDocumentInfo, Watermark |
| Read, merge, split and extract text | PdfReader |
| Encrypt | Encrypt, PdfPermissions |
| Create and fill forms | PdfTextField, PdfFormFiller |
| Create PDF/A-2b files | CreateForPdfA, PdfAValidationResult |
| Recognise text in scans (SoftZenPdf.Ocr package) | TesseractOcrEngine, OcrPdfCreator, OcrPage |
| Redact sensitive content (SoftZenPdf.Redact package) | PdfRedactor, RedactionResult |
| Make files smaller (SoftZenPdf.Optimizer package) | PdfOptimizer, OptimizationResult |
Namespaces
- SoftZenPdf: everything most applications need.
- SoftZenPdf.Ocr: OCR with Tesseract 5 and searchable PDFs, in the separate SoftZenPdf.Ocr package.
- SoftZenPdf.Redact: secure redaction, in the separate SoftZenPdf.Redact package.
- SoftZenPdf.Optimizer: file-size optimization, in the separate SoftZenPdf.Optimizer package.
- SoftZenPdf.Objects: the low-level PDF object model (dictionaries, arrays, streams, references) for inspecting files or building structures that have no high-level API.
Coordinates throughout are PDF user-space points (1/72 inch), with the origin at the bottom-left corner of the page.