Closed
Description
Pandoc already supports the lang
variable for setting the document language (following the BCP 47 standard). PDFs can include such a language definition as described in the
- Techniques for WCAG 2.0 (PDF16) and
- Techniques for WCAG 2.0 (PDF19) and
- PDF 1.7 Specification > Section 14.9.2.3 Language Specification Hierarchy.
One can set the PDF language parameter via the hyperref
package with the option pdflang
. The W3C page mentions that the PDF language definition has to use the ISO 639 language code but the hyperref documentation states support for RFC 3066 language codes. I don't know much about these standards but the pandoc language code looks quite similar so that we might be able to simply pass it to hyperref
like this:
\hypersetup{
pdflang={$lang$},
}
It also might be trivial to map between codes, should it be necessary.
Metadata
Metadata
Assignees
Labels
No labels