THotPDF.AddPronunciationLexicon Method
Embeds a PLS pronunciation lexicon and appends its indirect file specification to the PDF 2.0 structure tree in lookup order
Declaração
function AddPronunciationLexicon(
const FileName, Description: AnsiString;
const LexiconBytes: TBytes): THPDFDictionaryObject;
Parâmetros e resultado
| Valor | Finalidade |
|---|---|
FileName | Non-empty embedded file name used by the Filespec and embedded-files name tree |
Description | Optional human-readable Filespec/Desc text |
LexiconBytes | Non-empty XML bytes conforming to Pronunciation Lexicon Specification 1.0 |
| Resultado | Indirect Filespec dictionary that owns the embedded lexicon reference |
Comportamento
- O método requer PDF 2.0 e segue
StrictVersionLockbehavior - The payload is written as an indirect
EmbeddedFilestream withapplication/pls+xml, size, and modification-date metadata - The returned indirect
Filespecis appended toStructTreeRoot/PronunciationLexicon - Lexicon order is significant because text-to-speech consumers should use the first matching entry
ValidatePDFUA2Structurechecks array type, indirect references, embedded payloads, and MIME identity