SetPDFUAMode
Document properties, Accessibility
Opis
Activates PDF/UA-1 (ISO 14289-1:2014) conformance mode for the selected document. This single call performs all document-level setup required by the standard: the document version is bumped to at least PDF 1.7, MarkInfo.Marked and MarkInfo.Suspects are written, DisplayDocTitle is enabled in ViewerPreferences, Catalog/Lang is set when a language is supplied, and the pdfuaid:part=1 XMP namespace entry is written. When the document is encrypted after SetPDFUAMode is active, CanCopyAccess (bit 10 of the encryption /P key) is automatically forced on regardless of the caller-supplied TPDFExtraPermissions mask, satisfying ISO 14289-1 §7.16. If the document was already encrypted before SetPDFUAMode was called, the existing encrypt dictionary is left unchanged — call Encrypt again after SetPDFUAMode to refresh the /P value. GetPDFUADiagnostics reports this situation as ENCRYPT-NO-ACCESS.
Pozovite ovo pre dodavanja bilo kog sadržaja. Sadržaj dokumenta tagujte pomoću BeginTag/EndTag i BeginArtifact/EndArtifact
Sintaksa
Delphi
Function TPDFlib.SetPDFUAMode(Const Language: WideString): Integer;
ActiveX
Function PDFlib::SetPDFUAMode(Language As String) As Long
DLL
int DLSetPDFUAMode(int InstanceID, const wchar_t * Language);
Parametri
| Language | BCP 47 jezički tag za podrazumevani jezik dokumenta, npr. "en-US", "de". Prosledite prazan string da se Catalog /Lang unos izostavi |
|---|
Return values
| 0 | Neuspeh (nijedan dokument nije otvoren) |
|---|---|
| 1 | PDF/UA režim je uspešno aktiviran |
Napomene
U trenutku čuvanja, sve otvorene stranice automatski dobijaju /Tabs /S unos (tab redosled zasnovan na strukturi) kad je PDF/UA režim aktivan, čime se ispunjava ISO 14289-1 §7.18.3. Ispravke pri čuvanju takođe automatski popunjavaju nedostajuće tooltip-ove vidžeta (/TU) i /Contents unose anotacija, prikačuju /AFRelationship ugrađenim datotekama, odsjeku sve TrapNet anotacije (zabranjene ISO 14289-1 §7.18.2) i prikačuju /O = List /ListNumbering = None svakom L strukturnom elementu kome nedostaje eksplicitan atribut ListNumbering (ISO 14289-1 §7.6)
Vidi takođe: SetDocumentLanguage, SetMarkInfo, SetPDFAMode