Functions¶
|
|
|
|
|
|
|
Details¶
- PangoOT.tag_from_language(language)¶
- Parameters:
language (
Pango.Language
orNone
) – APangoLanguage
- Returns:
PangoOTTag
best matching language or %PANGO_OT_TAG_DEFAULT_LANGUAGE if none found or if language isNone
.- Return type:
Finds the OpenType language-system tag best describing language.
New in version 1.18.
- PangoOT.tag_from_script(script)¶
- Parameters:
script (
Pango.Script
) – APangoScript
- Returns:
PangoOTTag
corresponding to script or %PANGO_OT_TAG_DEFAULT_SCRIPT if none found.- Return type:
Finds the OpenType script tag corresponding to script.
The
Pango.Script.COMMON
,Pango.Script.INHERITED
, andPango.Script.UNKNOWN
scripts are mapped to the OpenType ‘DFLT’ script tag that is also defined as %PANGO_OT_TAG_DEFAULT_SCRIPT.Note that multiple
PangoScript
values may map to the same OpenType script tag. In particular,Pango.Script.HIRAGANA
andPango.Script.KATAKANA
both map to the OT tag ‘kana’.New in version 1.18.
- PangoOT.tag_to_language(language_tag)¶
- Parameters:
language_tag (
int
) – APangoOTTag
OpenType language-system tag- Returns:
PangoLanguage
best matching language_tag orPangoLanguage
corresponding to the string “xx” if none found.- Return type:
Finds a
PangoLanguage
corresponding to language_tag.New in version 1.18.
- PangoOT.tag_to_script(script_tag)¶
- Parameters:
script_tag (
int
) – APangoOTTag
OpenType script tag- Returns:
PangoScript
corresponding to script_tag orPango.Script.UNKNOWN
if none found.- Return type:
Finds the
PangoScript
corresponding to script_tag.The ‘DFLT’ script tag is mapped to
Pango.Script.COMMON
.Note that an OpenType script tag may correspond to multiple
PangoScript
values. In such cases, thePangoScript
value with the smallest value is returned. In particular,Pango.Script.HIRAGANA
andPango.Script.KATAKANA
both map to the OT tag ‘kana’. This function will returnPango.Script.HIRAGANA
for ‘kana’.New in version 1.18.