Function

Pango-1.0Pangolanguage_from_string

  • Convert a language tag to a Pango.Language.

    The language tag must be in a RFC-3066 format. Pango.Language pointers can be efficiently copied (copy the pointer) and compared with other language tags (compare the pointer.)

    This function first canonicalizes the string by converting it to lowercase, mapping '_' to '-', and stripping all characters other than letters and '-'.

    Use Pango.Language.get_default if you want to get the Pango.Language for the current locale of the process.

    Parameters

    • Optionallanguage: string

      a string representing a language tag

    Returns Pango.Language

    a Pango.Language