DynaPDF Manual - Page 784
Previous Page 783 Index Next Page 785

Function Reference
Page 784 of 874
SetLanguage
Syntax:
LBOOL pdfSetLanguage(
const PPDF* IPDF,
// Instance pointer
const char* ISOTag) // Language identifier see below
The property specifies the language of the document. The document's language should always be
set when creating Tagged PDF files or Interactive Forms. The spell check feature in Adobe's Acrobat
depends on the properly defined document language.
Language Identifiers
The value of the language property is a string that specifies the language with a language identifier
having the syntax, defined in Internet RFC 3066, Tags for the Identification of Languages.
This syntax, which is summarized below, is also used to identify languages in XML, according to the
World Wide Web Consortium document Extensible Markup Language (XML) 1.0.
Language identifiers can be based on codes defined by the International Organization for
Standardization in ISO 639 and ISO 3166 or registered with the Internet Assigned Numbers
Authoring (IANA, whose Web site is located at http://www.iana.org), or they can include codes
created for private use. A language identifier consists of a primary code optionally followed by one
or more sub codes (each preceded by a hyphen). The primary code can be any of the following:
• A 2-character ISO 639 language code - for example, en for English or es for Spanish.
• The letter i, designating an IANA-registered identifier
• The letter x for private use
The first sub code can be a 2-character ISO 3166 country code, as in en-US, or a 3- to 8-character sub
code registered with IANA, as in en-cockney or i-cherokee (except in private identifiers, for which sub
codes are not registered). Sub codes beyond the first can be any that have been registered at IANA.
Language identifiers are treated case-sensitive.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
Previous topic: SetItalicAngle, SetJPEGQuality
Next topic: SetLeading
Web links on this page: