Shaun McCance
shaunm@gnome.org 2011–2012

This work is licensed under a Creative Commons Attribution-Share Alike 3.0 United States License.

As a special exception, the copyright holders give you permission to copy, modify, and distribute the example code contained in this document under the terms of your choosing, without restriction.

International text rendering with full Unicode support

# Pango

Pango is the core text and font handling library in the GNOME platform. It is responsible for laying out and rendering text, and is used throughout GTK.

Le moteur de mise en page Pango peut être utilisé avec différents moteurs de polices et de dessin. Sur la plupart des systèmes GNOME, Pango utilise FreeType, fontconfig et Cairo pour accéder aux polices et produire du texte. Sur d'autres systèmes, Pango utilise les systèmes de polices natifs, tels que Uniscribe sur Microsoft Windows et ATSUI sur MacOS.

Pango has extensive support for the various writing systems used throughout the world. Many of the writing systems used for languages have complex rules for laying out glyphs and composing characters. With Pango, nearly all languages can be written and displayed correctly, allowing users everywhere to view text in their native languages. Pango's support for multiple writing systems is automatic; application developers do not have to write any special code to support other languages.

Pango supports the kind of text styling used in typical documents and interfaces, including italics, font weights, and underlines. Pango uses a simple XML-like vocabulary called PangoMarkup which enables you to set font size, color, styles, and other text attributes. Using PangoMarkup, you can specify inline styles without manually iterating over text blocks. PangoMarkup can be used directly from GTK, enabling you to style text in your graphical interfaces easily.

You should use Pango directly whenever you need to lay text out on the screen or on a different medium. Using Pango will allow your text layout to work seamlessly with GTK and the rest of the GNOME platform. It will help you create portable code, and most importantly, it will ensure that your application can render text correctly in hundreds of different languages.

Pango Reference Manual

The Pango web site