Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Pango
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Support for OpenType features== [[Image:Pango locl demo.png|thumb|250px|Default rendering above, localized Romanian rendering below.]] Pango 1.17 and newer support the '{{not a typo|locl}}' feature tag that allows localized glyphs to be used for the same Unicode code point. Assuming you have [[Verdana]] version 5.01 installed, which supports the 'locl' feature for the latn/ROM (Romanian) script, a quick demonstration (on Linux) is: <syntaxhighlight lang="bash"> for lang in en ro do pango-view \ --font="Verdana 64" \ --text "ΕΕ£ vs. ΘΘ in $lang" \ --language=$lang done </syntaxhighlight> For an explanation of the substitutions rules for Romanian, see this [[Romanian alphabet#Comma-below .28.C8.99 and .C8.9B.29 versus cedilla .28.C5.9F and .C5.A3.29|discussion]]. Setting the locale via the POSIX environment variable, e.g. LANG=ro_RO.UTF-8 will also cause Pango to use 'locl' font feature. Finally, you can change the language on the fly in the same text using [https://docs.gtk.org/Pango/pango_markup.html Pango markup], e.g.: <syntaxhighlight lang="bash"> pango-view \ --font="Verdana 24" \ --markup \ --text 'In the same text: ΕΕ£(en) and <span lang="ro">ΕΕ£(ro).</span>' </syntaxhighlight> Since 1.37.1, Pango added more attributes to provide complete support for processing OpenType feature.<ref>{{cite web | url = https://ftp.gnome.org/pub/GNOME/sources/pango/1.37/pango-1.37.1.news | title = Overview of changes between 1.37.0 and 1.37.1 | access-date = 18 August 2015}}</ref><ref>{{cite web | url = https://bugzilla.gnome.org/show_bug.cgi?id=738505 | title = Bug 738505 - Add fontfeatures support in PangoAttributes and markup | publisher = GNOME Bugzilla | access-date = 18 August 2015}}</ref><ref>{{cite web | url = http://tavmjong.free.fr/blog/?p=1442 | title = Font Features Land in Inkscape Trunk | publisher = Tavmjong Bah's Blog | date = 23 June 2015 | access-date = 18 August 2015}}</ref> The official showcase of Pango's script-aware features is [https://www.pango.org/ScriptGallery here].
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)