BeginArtifactA
Tagged PDF, Accessibility
Description
The trailing A denotes the ANSI (char) DLL entry point; the ActiveX/COM surface exposes only the Unicode form. Behaviour is identical to BeginArtifact and string arguments are interpreted using the current SetAnsiMode code page
Opens a PDF artifact region. Artifact content is decorative or structural (page headers, footers, page numbers, background images, ruling lines) and is explicitly excluded from the logical document reading order. Screen readers skip artifact regions entirely.
Write the artifact's graphics or text between BeginArtifact and the matching EndArtifact call.
Syntax
Delphi
Function DLBeginArtifactA(InstanceID: Integer; SubType: PAnsiChar): Integer;
DLL
int DLBeginArtifactA(int InstanceID, const char * SubType);
Parameters
| SubType | Optional artifact sub-type name. Common values: Header, Footer, Watermark, Background. Pass an empty string to omit the sub-type. |
|---|
Return values
| 0 | Failed (no document is open) |
|---|---|
| 1 | Artifact region opened successfully |
Example
// Page footer as artifact
PDF.BeginArtifact('Footer');
PDF.SetFontSize(8);
PDF.PrintText(50, 20, 'Page 1 of 10');
PDF.EndArtifact;