PDFium Delphi Component is a comprehensive, professional-grade component library that brings powerful PDF processing and viewing capabilities to Delphi and C++Builder applications. It uses the PDFium rendering engine for page rendering and document reading, and implements in Object Pascal everything that engine does not provide.
That distinction matters when you evaluate the library. PDFium draws pages, extracts text, and reads existing structures. It cannot sign a document, write encryption, validate a PDF standard, or emit a linearized or incremental revision. PDFium Delphi Component ships roughly 115,000 lines of Object Pascal across 55 units, and more than 62,000 of those lines are in 36 units that have no counterpart in the PDFium API at all — cryptography, signatures, encryption, standards conformance, PDF serialization, form-data interchange, layout, and text shaping. All of it is delivered as source.
The library consists of three registered components: TPdf for document processing and manipulation with 475 public members, TPdfView for interactive visual presentation with 152, and TPdfThumbnailView for page navigation. Whether you need to build a simple PDF viewer, a signed-document workflow, an archival conversion pipeline, or a complete document management system, PDFium Delphi Component provides the tools and flexibility you need.
The following capabilities have no counterpart in the PDFium C API. Each is implemented by PDFium Delphi Component in Object Pascal, verified against the published ISO, ETSI, IETF, or FIPS clauses, and available as source.
Complete signing, not signature reading. PDFium can report that a signature dictionary exists; PDFium Delphi Component creates one.
SignPades, SignPadesToStream and SignPadesBytes/Certs, /OCSPs and /CRLs, per-signature VRI dictionaries, and the /Extensions /ESIC marker/SubFilter /ETSI.RFC3161 covering the whole file, for B-LTAICmsSigner interface that any other backend can implementPreparePadesRemoteSignature and CompletePadesRemoteSignature split the operation so the private key can stay inside a remote service or hardware moduleValidatePades reports the highest baseline the document reaches plus clause-level issue codes; ValidatePadesTrust and ValidatePadesTrustAsync add certificate-chain trust checkingSignPadesWithPdfA converts to PDF/A-4 and signs in one call, per EN 319 142-1 Annex A.7PDFium opens encrypted files. It does not write encryption. PDFium Delphi Component implements the writing side against ISO 32000-2 and its technical specifications.
SaveAsEncrypted with V=5 / R=5 / R=6 key derivation, including the algorithm 2.B hash iteration, and the /O /U /OE /UE /Perms dictionary entries/Length correction and a rebuilt cross-reference table/AuthCode tokens — CMS AuthenticatedData with HKDF key derivation, key wrapping and HMAC verificationSix ISO standard families, each with a validator returning clause-level result codes, and a matching save or marker-injection path.
The engine offers one sequential whole-file save. Applications frequently need more than that, so PDFium Delphi Component writes its own revisions on top of the engine's semantic output.
SaveAsLinearized produces Fast Web View files with first-page grouping, two cross-reference sections, and Annex F page-offset and shared-object hint tablesSaveAsObjectStream groups eligible objects into /ObjStm with page-local ordering and complete type-2 cross-reference coverageBeginIncrementalSave and CommitIncrementalSave append only changed and new indirect objects to encrypted or unencrypted sources, preserving the previous output byte for byte along with /Prev, /Encrypt, /Info and the permanent /ID; a commit with no changes does not grow the fileSaveAsRepaired writes a single-revision copy and re-verifies it with an independent strict load before it is deliveredTPdf.PdfVersion reuses PDFium parser state and performs only an eight-byte header guard instead of reparsing the source documentTPdfRandomAccessStore keeps intermediate data in memory up to SaveMemoryLimit, then migrates to an exclusive delete-on-close temporary file; core save post-processing uses the same policy for all three workspaces, while default open-action and page-label catalog updates use bounded windows and a sparse index/AF arrays attached to the catalog or a target page, with the eight Table 45 relationship valuesIPdfOcrProvider accepts any recognition engine — the component supplies page bitmaps and writes the resulting searchable text layer, with per-page status and existing-text skipGetStructuredText builds a page / block / line / styled-span hierarchy from character geometry and Tagged PDF semantics; ExtractTables and ExtractDocumentTables detect bordered and whitespace-aligned tables, preserve merged spans, score confidence, and emit CSV or JSONBuildReflowDocument turns a fixed-layout PDF into a node tree whose safe HTML output preserves headings, paragraphs, lists, figures, page sections and table spansMeasureText and WrapText provide word-wrap without adding anything to a pageTPdfStreamInspector decodes arbitrary stream objects under explicit source, raw, decoded, expansion-ratio and stream-count budgets, returning a structured status rather than exhausting memory on a crafted fileThe heart of the PDF processing system, TPdf handles all document-level operations including loading, saving, text extraction, form processing, and metadata management.
A sophisticated visual control that provides rich PDF viewing experience with full user interaction capabilities.
TStream adapters via LoadCustomDocument, with compatible, strict, and recovery policies plus structured xref diagnosticsSaveAsRepairedSaveAsPdfA / SaveAsPdfAToStream with bundled sRGB ICC profile and custom-profile supportValidatePdfA and read-only PdfAConformance propertyMergeFiles (bounded-source batch merge), ImportPagesByIndex (subset import), ImportNPagesToOne (N-up grid), MovePages (in-place reorder)CreateXObjectFromPage and InsertFormObjectFromXObjectRenderPageProgressive and IPdfCancellationTokenTPdfProgressiveDocument, including sparse byte-range hints, prioritized range scheduling, bounded retries, cancellation, and document, form, and page availability gatesSaveAsLinearized, including first-page grouping, two cross-reference sections, and Annex F page-offset and shared-object hint tablesSaveAsObjectStream, including bounded ObjStm groups, page-local ordering, and complete type-2 xref coverageBeginIncrementalSave and CommitIncrementalSave, including encrypted prefix preservation, inherited security parameters, no-op commits, strict reopen validation, durable side files, atomic replacement, rollback, and per-commit statisticsTPdfRandomAccessStore and SaveMemoryLimit, including secure temporary-file spill, positioned I/O, and per-save peak diagnosticsFitMode chooses how the page sits in the viewport (manual zoom, actual size, fit page, fit width); re-applied automatically on Resize / page changePageColor decouples the rendered PDF page background from the surrounding control's Color for dark-mode viewersHighlightSearchText and ClearHighlightPageShadowSize / PageShadowColor) and page border (PageBorderColor)LinkOptions) and OnAnnotationLinkClick / OnWebLinkClick eventsAllowUserPageChange, ChangePageOnMouseScrolling, AllowUserTextSelection) for kiosks and read-only embeddingsTPdfThumbnailView side panel component| Aspect | Details |
|---|---|
| Rendering Engine | Google PDFium - Industry-standard, battle-tested PDF engine |
| PDF Support | PDF versions 1.0 through 1.7, encrypted and password-protected files |
| Platform Compatibility | Windows 32-bit and 64-bit applications |
| IDE Support | Delphi XE5 / C++Builder XE5 (RAD Studio XE5) through Delphi/C++Builder 13.1 Florence (RAD Studio 13.1), Lazarus 3.8+ |
| Character Encoding | Full Unicode support, multi-language text processing |
| Memory Management | Optimized for large documents, efficient resource usage |
| Thread Safety | Single-threaded design (as per PDFium requirements) |
PDFium Delphi Component follows a layered architecture pattern that cleanly separates concerns and maximizes code reusability:
| Layer | Files | Responsibility |
|---|---|---|
| VCL Components | PDFium.pas, FPdfThumbnail.pas | Delphi VCL components (TPdf, TPdfView, TPdfThumbnailView) with design-time support |
| API Bindings | FPdfView.pas, FPdfDoc.pas, FPdfText.pas, FPdfEdit.pas, FPdfAnnot.pas, FPdfFormFill.pas, FPdfPageOps.pas, FPdfAttachment.pas, FPdfSignature.pas, FPdfStructTree.pas, FPdfDataAvail.pas, FPdfExtensions.pas, FPdfFWLEvent.pas, FPdfCompress.pas, FPdfUtils.pas | Function pointer declarations for PDFium DLL calls |
| PDF/A Pipeline | FPdfPdfa.pas | PDF/A-1b creation (XMP injection, sRGB ICC OutputIntent, catalog update) and validation (conformance detection, issue enumeration) |
| Async Infrastructure | FPdfAsync.pas | IPdfCancellationToken / IPdfCancellationTokenSource, PdfNoCancellationToken singleton, and TPdfFuture<T> helper for long-running rendering and export work |
| Geometry Helpers | FPdfMatrix.pas | OO wrapper around FS_MATRIX with Translate, Scale, Rotate, Flip, Skew, and Multiply helpers |
| Page Operations | FPdfPageOps.pas | Wrappers for FPDF_ImportPagesByIndex, FPDF_ImportPages, FPDF_ImportNPagesToOne, FPDF_MovePages, scalable file-backed batch scheduling, plus Form-XObject helpers (CreateXObjectFromPage / InsertFormObjectFromXObject) |
| Thumbnail Side Panel | FPdfThumbnail.pas | TPdfThumbnailView — scrollable per-page thumbnail panel with hover, selection, and OnPageClick navigation |
| Native Engine | DLLs\Win32|Win64\pdfium.dll and pdfium.v8.dll | Google PDFium native rendering engine, with optional V8-enabled builds |
TPdf members and 36 ready-to-run projects reduce development timePDFium Delphi Component is designed for immediate productivity. The component library includes:
Whether you're building a simple PDF viewer or a complex document processing system, PDFium Delphi Component provides the foundation for professional PDF functionality in your Delphi and C++Builder applications.