Method AddTextOverlays
AddTextOverlays(Attachment, IEnumerable<PageTextOverlay>, PdfSaveOptions)
Adds invisible text overlays to multiple pages of a PDF attachment in a single operation using precomputed PageElement instances. No OCR is performed.
public static Attachment AddTextOverlays(Attachment source, IEnumerable<PageTextOverlay> overlays, PdfSaveOptions saveOptions = PdfSaveOptions.None)
Parameters
sourceAttachmentThe source PDF attachment to modify.
overlaysIEnumerable<PageTextOverlay>A collection of PageTextOverlay entries, each associating a page index with its text layout.
saveOptionsPdfSaveOptionsOptions controlling how the modified PDF is written. Default: full rewrite.
Returns
- Attachment
A new Attachment containing the modified PDF.
Exceptions
- ArgumentNullException
sourceoroverlaysisnull.