Git init
[external/pango1.0.git] / docs / xml / opentype.xml
1 <refentry id="pango-OpenType-Font-Handling">
2 <refmeta>
3 <refentrytitle role="top_of_page" id="pango-OpenType-Font-Handling.top_of_page">OpenType Font Handling</refentrytitle>
4 <manvolnum>3</manvolnum>
5 <refmiscinfo>PANGO Library</refmiscinfo>
6 </refmeta>
7
8 <refnamediv>
9 <refname>OpenType Font Handling</refname>
10 <refpurpose>Obtaining information from OpenType tables</refpurpose>
11 </refnamediv>
12 <refsect1 id="pango-OpenType-Font-Handling.stability-level">
13 <title>Stability Level</title>
14 Unstable, unless otherwise indicated
15 </refsect1>
16
17 <refsynopsisdiv id="pango-OpenType-Font-Handling.synopsis" role="synopsis">
18 <title role="synopsis.title">Synopsis</title>
19 <anchor id="PangoOTInfo"/><anchor id="PangoOTRuleset"/>
20 <synopsis>
21 typedef             <link linkend="PangoOTTag">PangoOTTag</link>;
22                     <link linkend="PangoOTInfo-struct">PangoOTInfo</link>;
23                     <link linkend="PangoOTBuffer">PangoOTBuffer</link>;
24                     <link linkend="PangoOTGlyph">PangoOTGlyph</link>;
25                     <link linkend="PangoOTRuleset-struct">PangoOTRuleset</link>;
26                     <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link>;
27 enum                <link linkend="PangoOTTableType">PangoOTTableType</link>;
28                     <link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link>;
29 #define             <link linkend="PANGO-OT-TAG-MAKE--CAPS">PANGO_OT_TAG_MAKE</link>                   (c1,c2,c3,c4)
30 #define             <link linkend="PANGO-OT-TAG-MAKE-FROM-STRING--CAPS">PANGO_OT_TAG_MAKE_FROM_STRING</link>       (s)
31 #define             <link linkend="PANGO-OT-ALL-GLYPHS--CAPS">PANGO_OT_ALL_GLYPHS</link>
32 #define             <link linkend="PANGO-OT-NO-FEATURE--CAPS">PANGO_OT_NO_FEATURE</link>
33 #define             <link linkend="PANGO-OT-NO-SCRIPT--CAPS">PANGO_OT_NO_SCRIPT</link>
34 #define             <link linkend="PANGO-OT-DEFAULT-LANGUAGE--CAPS">PANGO_OT_DEFAULT_LANGUAGE</link>
35 #define             <link linkend="PANGO-OT-TAG-DEFAULT-LANGUAGE--CAPS">PANGO_OT_TAG_DEFAULT_LANGUAGE</link>
36 #define             <link linkend="PANGO-OT-TAG-DEFAULT-SCRIPT--CAPS">PANGO_OT_TAG_DEFAULT_SCRIPT</link>
37 <link linkend="PangoOTInfo">PangoOTInfo</link> *       <link linkend="pango-ot-info-get">pango_ot_info_get</link>                   (<link linkend="FT-Face">FT_Face</link> face);
38 <link linkend="gboolean">gboolean</link>            <link linkend="pango-ot-info-find-script">pango_ot_info_find_script</link>           (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
39                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
40                                                          <link linkend="PangoOTTag">PangoOTTag</link> script_tag,
41                                                          <link linkend="guint">guint</link> *script_index);
42 <link linkend="gboolean">gboolean</link>            <link linkend="pango-ot-info-find-language">pango_ot_info_find_language</link>         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
43                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
44                                                          <link linkend="guint">guint</link> script_index,
45                                                          <link linkend="PangoOTTag">PangoOTTag</link> language_tag,
46                                                          <link linkend="guint">guint</link> *language_index,
47                                                          <link linkend="guint">guint</link> *required_feature_index);
48 <link linkend="gboolean">gboolean</link>            <link linkend="pango-ot-info-find-feature">pango_ot_info_find_feature</link>          (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
49                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
50                                                          <link linkend="PangoOTTag">PangoOTTag</link> feature_tag,
51                                                          <link linkend="guint">guint</link> script_index,
52                                                          <link linkend="guint">guint</link> language_index,
53                                                          <link linkend="guint">guint</link> *feature_index);
54 <link linkend="PangoOTTag">PangoOTTag</link> *        <link linkend="pango-ot-info-list-scripts">pango_ot_info_list_scripts</link>          (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
55                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type);
56 <link linkend="PangoOTTag">PangoOTTag</link> *        <link linkend="pango-ot-info-list-languages">pango_ot_info_list_languages</link>        (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
57                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
58                                                          <link linkend="guint">guint</link> script_index,
59                                                          <link linkend="PangoOTTag">PangoOTTag</link> language_tag);
60 <link linkend="PangoOTTag">PangoOTTag</link> *        <link linkend="pango-ot-info-list-features">pango_ot_info_list_features</link>         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
61                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
62                                                          <link linkend="PangoOTTag">PangoOTTag</link> tag,
63                                                          <link linkend="guint">guint</link> script_index,
64                                                          <link linkend="guint">guint</link> language_index);
65 <link linkend="PangoOTBuffer">PangoOTBuffer</link> *     <link linkend="pango-ot-buffer-new">pango_ot_buffer_new</link>                 (<link linkend="PangoFcFont">PangoFcFont</link> *font);
66 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-destroy">pango_ot_buffer_destroy</link>             (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);
67 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-clear">pango_ot_buffer_clear</link>               (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);
68 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-add-glyph">pango_ot_buffer_add_glyph</link>           (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
69                                                          <link linkend="guint">guint</link> glyph,
70                                                          <link linkend="guint">guint</link> properties,
71                                                          <link linkend="guint">guint</link> cluster);
72 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-set-rtl">pango_ot_buffer_set_rtl</link>             (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
73                                                          <link linkend="gboolean">gboolean</link> rtl);
74 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-set-zero-width-marks">pango_ot_buffer_set_zero_width_marks</link>
75                                                         (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
76                                                          <link linkend="gboolean">gboolean</link> zero_width_marks);
77 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-get-glyphs">pango_ot_buffer_get_glyphs</link>          (const <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
78                                                          <link linkend="PangoOTGlyph">PangoOTGlyph</link> **glyphs,
79                                                          <link linkend="int">int</link> *n_glyphs);
80 <link linkend="void">void</link>                <link linkend="pango-ot-buffer-output">pango_ot_buffer_output</link>              (const <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
81                                                          <link linkend="PangoGlyphString">PangoGlyphString</link> *glyphs);
82 const <link linkend="PangoOTRuleset">PangoOTRuleset</link> * <link linkend="pango-ot-ruleset-get-for-description">pango_ot_ruleset_get_for_description</link>
83                                                         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
84                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);
85 <link linkend="PangoOTRuleset">PangoOTRuleset</link> *    <link linkend="pango-ot-ruleset-new">pango_ot_ruleset_new</link>                (<link linkend="PangoOTInfo">PangoOTInfo</link> *info);
86 <link linkend="PangoOTRuleset">PangoOTRuleset</link> *    <link linkend="pango-ot-ruleset-new-for">pango_ot_ruleset_new_for</link>            (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
87                                                          <link linkend="PangoScript">PangoScript</link> script,
88                                                          <link linkend="PangoLanguage">PangoLanguage</link> *language);
89 <link linkend="PangoOTRuleset">PangoOTRuleset</link> *    <link linkend="pango-ot-ruleset-new-from-description">pango_ot_ruleset_new_from_description</link>
90                                                         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
91                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);
92 <link linkend="void">void</link>                <link linkend="pango-ot-ruleset-add-feature">pango_ot_ruleset_add_feature</link>        (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
93                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
94                                                          <link linkend="guint">guint</link> feature_index,
95                                                          <link linkend="gulong">gulong</link> property_bit);
96 <link linkend="gboolean">gboolean</link>            <link linkend="pango-ot-ruleset-maybe-add-feature">pango_ot_ruleset_maybe_add_feature</link>  (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
97                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
98                                                          <link linkend="PangoOTTag">PangoOTTag</link> feature_tag,
99                                                          <link linkend="gulong">gulong</link> property_bit);
100 <link linkend="guint">guint</link>               <link linkend="pango-ot-ruleset-maybe-add-features">pango_ot_ruleset_maybe_add_features</link> (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
101                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
102                                                          const <link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link> *features,
103                                                          <link linkend="guint">guint</link> n_features);
104 <link linkend="guint">guint</link>               <link linkend="pango-ot-ruleset-get-feature-count">pango_ot_ruleset_get_feature_count</link>  (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
105                                                          <link linkend="guint">guint</link> *n_gsub_features,
106                                                          <link linkend="guint">guint</link> *n_gpos_features);
107 <link linkend="void">void</link>                <link linkend="pango-ot-ruleset-substitute">pango_ot_ruleset_substitute</link>         (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
108                                                          <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);
109 <link linkend="void">void</link>                <link linkend="pango-ot-ruleset-position">pango_ot_ruleset_position</link>           (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
110                                                          <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);
111 <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> * <link linkend="pango-ot-ruleset-description-copy">pango_ot_ruleset_description_copy</link>
112                                                         (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);
113 <link linkend="gboolean">gboolean</link>            <link linkend="pango-ot-ruleset-description-equal">pango_ot_ruleset_description_equal</link>  (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc1,
114                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc2);
115 <link linkend="void">void</link>                <link linkend="pango-ot-ruleset-description-free">pango_ot_ruleset_description_free</link>   (<link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);
116 <link linkend="guint">guint</link>               <link linkend="pango-ot-ruleset-description-hash">pango_ot_ruleset_description_hash</link>   (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);
117 <link linkend="PangoOTTag">PangoOTTag</link>          <link linkend="pango-ot-tag-from-language">pango_ot_tag_from_language</link>          (<link linkend="PangoLanguage">PangoLanguage</link> *language);
118 <link linkend="PangoOTTag">PangoOTTag</link>          <link linkend="pango-ot-tag-from-script">pango_ot_tag_from_script</link>            (<link linkend="PangoScript">PangoScript</link> script);
119 <link linkend="PangoLanguage">PangoLanguage</link> *     <link linkend="pango-ot-tag-to-language">pango_ot_tag_to_language</link>            (<link linkend="PangoOTTag">PangoOTTag</link> language_tag);
120 <link linkend="PangoScript">PangoScript</link>         <link linkend="pango-ot-tag-to-script">pango_ot_tag_to_script</link>              (<link linkend="PangoOTTag">PangoOTTag</link> script_tag);
121 </synopsis>
122 </refsynopsisdiv>
123
124 <refsect1 id="pango-OpenType-Font-Handling.object-hierarchy" role="object_hierarchy">
125 <title role="object_hierarchy.title">Object Hierarchy</title>
126 <synopsis>
127   <link linkend="GObject">GObject</link>
128    +----PangoOTInfo
129 </synopsis>
130 <synopsis>
131   <link linkend="GObject">GObject</link>
132    +----PangoOTRuleset
133 </synopsis>
134 </refsect1>
135
136
137
138
139
140
141
142
143 <refsect1 id="pango-OpenType-Font-Handling.description" role="desc">
144 <title role="desc.title">Description</title>
145 <para>
146 Functions and macros in this section are used to implement the OpenType Layout
147 features and algorithms.  These are mostly useful when writing Fontconfig-based
148 shaping engines
149 </para>
150 </refsect1>
151
152 <refsect1 id="pango-OpenType-Font-Handling.details" role="details">
153 <title role="details.title">Details</title>
154 <refsect2 id="PangoOTTag" role="typedef">
155 <title>PangoOTTag</title>
156 <indexterm zone="PangoOTTag"><primary sortas="PangoOTTag">PangoOTTag</primary></indexterm><programlisting>typedef guint32 PangoOTTag;
157 </programlisting>
158 <para>
159 The <type>PangoOTTag</type> typedef is used to represent TrueType and OpenType
160 four letter tags inside Pango. Use <link linkend="PANGO-OT-TAG-MAKE--CAPS"><function>PANGO_OT_TAG_MAKE()</function></link>
161 or <link linkend="PANGO-OT-TAG-MAKE-FROM-STRING--CAPS"><function>PANGO_OT_TAG_MAKE_FROM_STRING()</function></link> macros to create <type>PangoOTTag</type>s manually.
162 </para></refsect2>
163 <refsect2 id="PangoOTInfo-struct" role="struct">
164 <title>PangoOTInfo</title>
165 <indexterm zone="PangoOTInfo-struct"><primary sortas="PangoOTInfo">PangoOTInfo</primary></indexterm><programlisting>typedef struct _PangoOTInfo PangoOTInfo;</programlisting>
166 <para>
167 The <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link> struct contains the various
168 tables associated with an OpenType font. It contains only private fields and
169 should only be accessed via the <function>pango_ot_info_*</function> functions
170 which are documented below. To obtain a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>,
171 use <link linkend="pango-ot-info-new"><function>pango_ot_info_new()</function></link>.
172 </para></refsect2>
173 <refsect2 id="PangoOTBuffer" role="struct">
174 <title>PangoOTBuffer</title>
175 <indexterm zone="PangoOTBuffer"><primary sortas="PangoOTBuffer">PangoOTBuffer</primary></indexterm><programlisting>typedef struct _PangoOTBuffer PangoOTBuffer;</programlisting>
176 <para>
177 The <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> structure is used to store strings of glyphs associated
178 with a <link linkend="PangoFcFont"><type>PangoFcFont</type></link>, suitable for OpenType layout processing.  It contains
179 only private fields and should only be accessed via the
180 <function>pango_ot_buffer_*</function> functions which are documented below.
181 To obtain a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, use <link linkend="pango-ot-buffer-new"><function>pango_ot_buffer_new()</function></link>.
182 </para></refsect2>
183 <refsect2 id="PangoOTGlyph" role="struct">
184 <title>PangoOTGlyph</title>
185 <indexterm zone="PangoOTGlyph"><primary sortas="PangoOTGlyph">PangoOTGlyph</primary></indexterm><programlisting>typedef struct {
186   guint32  glyph;
187   guint    properties;
188   guint    cluster;
189   gushort  component;
190   gushort  ligID;
191
192   guint    internal;
193 } PangoOTGlyph;
194 </programlisting>
195 <para>
196 The <link linkend="PangoOTGlyph"><type>PangoOTGlyph</type></link> structure represents a single glyph together with
197 information used for OpenType layout processing of the glyph.
198 It contains the following fields.
199 </para><variablelist role="struct">
200 <varlistentry>
201 <term><link linkend="guint32">guint32</link>&#160;<structfield>glyph</structfield>;</term>
202 <listitem><simpara>the glyph itself.
203 </simpara></listitem>
204 </varlistentry>
205 <varlistentry>
206 <term><link linkend="guint">guint</link>&#160;<structfield>properties</structfield>;</term>
207 <listitem><simpara>the properties value, identifying which features should be
208              applied on this glyph.  See <link linkend="pango-ruleset-add-feature"><function>pango_ruleset_add_feature()</function></link>.
209 </simpara></listitem>
210 </varlistentry>
211 <varlistentry>
212 <term><link linkend="guint">guint</link>&#160;<structfield>cluster</structfield>;</term>
213 <listitem><simpara>the cluster that this glyph belongs to.
214 </simpara></listitem>
215 </varlistentry>
216 <varlistentry>
217 <term><link linkend="gushort">gushort</link>&#160;<structfield>component</structfield>;</term>
218 <listitem><simpara>a component value, set by the OpenType layout engine.
219 </simpara></listitem>
220 </varlistentry>
221 <varlistentry>
222 <term><link linkend="gushort">gushort</link>&#160;<structfield>ligID</structfield>;</term>
223 <listitem><simpara>a ligature index value, set by the OpenType layout engine.
224 </simpara></listitem>
225 </varlistentry>
226 <varlistentry>
227 <term><link linkend="guint">guint</link>&#160;<structfield>internal</structfield>;</term>
228 <listitem><simpara>for Pango internal use
229 </simpara></listitem>
230 </varlistentry>
231 </variablelist></refsect2>
232 <refsect2 id="PangoOTRuleset-struct" role="struct">
233 <title>PangoOTRuleset</title>
234 <indexterm zone="PangoOTRuleset-struct"><primary sortas="PangoOTRuleset">PangoOTRuleset</primary></indexterm><programlisting>typedef struct _PangoOTRuleset PangoOTRuleset;</programlisting>
235 <para>
236 The <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> structure holds a
237 set of features selected from the tables in an OpenType font.
238 (A feature is an operation such as adjusting glyph positioning
239 that should be applied to a text feature such as a certain
240 type of accent.) A <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>
241 is created with <link linkend="pango-ot-ruleset-new"><function>pango_ot_ruleset_new()</function></link>, features are added
242 to it with <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link>, then it is
243 applied to a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link> with <link linkend="pango-ot-ruleset-shape"><function>pango_ot_ruleset_shape()</function></link>.
244 </para></refsect2>
245 <refsect2 id="PangoOTRulesetDescription" role="struct" condition="since:1.18">
246 <title>PangoOTRulesetDescription</title>
247 <indexterm zone="PangoOTRulesetDescription" role="1.18"><primary sortas="PangoOTRulesetDescription">PangoOTRulesetDescription</primary></indexterm><programlisting>typedef struct {
248   PangoScript               script;
249   PangoLanguage            *language;
250   const PangoOTFeatureMap  *static_gsub_features;
251   guint                   n_static_gsub_features;
252   const PangoOTFeatureMap  *static_gpos_features;
253   guint                   n_static_gpos_features;
254   const PangoOTFeatureMap  *other_features;
255   guint                   n_other_features;
256 } PangoOTRulesetDescription;
257 </programlisting>
258 <para>
259 The <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> structure holds all the information needed
260 to build a complete <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> from an OpenType font.
261 The main use of this struct is to act as the key for a per-font
262 hash of rulesets.  The user populates a ruleset description and
263 gets the ruleset using <link linkend="pango-ot-ruleset-get-for-description"><function>pango_ot_ruleset_get_for_description()</function></link>
264 or create a new one using <link linkend="pango-ot-ruleset-new-from-description"><function>pango_ot_ruleset_new_from_description()</function></link>.
265 </para><variablelist role="struct">
266 <varlistentry>
267 <term><link linkend="PangoScript">PangoScript</link>&#160;<structfield>script</structfield>;</term>
268 <listitem><simpara>a <link linkend="PangoScript"><type>PangoScript</type></link>.
269 </simpara></listitem>
270 </varlistentry>
271 <varlistentry>
272 <term><link linkend="PangoLanguage">PangoLanguage</link>&#160;*<structfield>language</structfield>;</term>
273 <listitem><simpara>a <link linkend="PangoLanguage"><type>PangoLanguage</type></link>.
274 </simpara></listitem>
275 </varlistentry>
276 <varlistentry>
277 <term>const&#160;<link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link>&#160;*<structfield>static_gsub_features</structfield>;</term>
278 <listitem><simpara>static map of GSUB features, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
279 </simpara></listitem>
280 </varlistentry>
281 <varlistentry>
282 <term><link linkend="guint">guint</link>&#160;<structfield>n_static_gsub_features</structfield>;</term>
283 <listitem><simpara>length of <parameter>static_gsub_features</parameter>, or 0.
284 </simpara></listitem>
285 </varlistentry>
286 <varlistentry>
287 <term>const&#160;<link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link>&#160;*<structfield>static_gpos_features</structfield>;</term>
288 <listitem><simpara>static map of GPOS features, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
289 </simpara></listitem>
290 </varlistentry>
291 <varlistentry>
292 <term><link linkend="guint">guint</link>&#160;<structfield>n_static_gpos_features</structfield>;</term>
293 <listitem><simpara>length of <parameter>static_gpos_features</parameter>, or 0.
294 </simpara></listitem>
295 </varlistentry>
296 <varlistentry>
297 <term>const&#160;<link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link>&#160;*<structfield>other_features</structfield>;</term>
298 <listitem><simpara>map of extra features to add to both GSUB and GPOS, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
299                  Unlike the static maps, this pointer need not live beyond
300                  the life of function calls taking this struct.
301 </simpara></listitem>
302 </varlistentry>
303 <varlistentry>
304 <term><link linkend="guint">guint</link>&#160;<structfield>n_other_features</structfield>;</term>
305 <listitem><simpara>length of <parameter>other_features</parameter>, or 0.
306 </simpara></listitem>
307 </varlistentry>
308 </variablelist><para role="since">Since 1.18</para></refsect2>
309 <refsect2 id="PangoOTTableType" role="enum">
310 <title>enum PangoOTTableType</title>
311 <indexterm zone="PangoOTTableType"><primary sortas="PangoOTTableType">PangoOTTableType</primary></indexterm><programlisting>typedef enum
312 {
313   PANGO_OT_TABLE_GSUB,
314   PANGO_OT_TABLE_GPOS
315 } PangoOTTableType;
316 </programlisting>
317 <para>
318 The <type>PangoOTTableType</type> enumeration values are used to
319 identify the various OpenType tables in the
320 <function>pango_ot_info_*</function> functions.
321 </para><variablelist role="enum">
322 <varlistentry id="PANGO-OT-TABLE-GSUB--CAPS" role="constant">
323 <term><literal>PANGO_OT_TABLE_GSUB</literal></term>
324 <listitem><simpara>The GSUB table.
325 </simpara></listitem>
326 </varlistentry>
327 <varlistentry id="PANGO-OT-TABLE-GPOS--CAPS" role="constant">
328 <term><literal>PANGO_OT_TABLE_GPOS</literal></term>
329 <listitem><simpara>The GPOS table.
330 </simpara></listitem>
331 </varlistentry>
332 </variablelist></refsect2>
333 <refsect2 id="PangoOTFeatureMap" role="struct" condition="since:1.18">
334 <title>PangoOTFeatureMap</title>
335 <indexterm zone="PangoOTFeatureMap" role="1.18"><primary sortas="PangoOTFeatureMap">PangoOTFeatureMap</primary></indexterm><programlisting>typedef struct {
336   char     feature_name[5];
337   gulong   property_bit;
338 } PangoOTFeatureMap;
339 </programlisting>
340 <para>
341 The <type>PangoOTFeatureMap</type> typedef is used to represent an OpenType
342 feature with the property bit associated with it.  The feature tag is
343 represented as a char array instead of a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> for convenience.
344 </para><variablelist role="struct">
345 <varlistentry>
346 <term><link linkend="char">char</link>&#160;<structfield>feature_name</structfield>[5];</term>
347 <listitem><simpara>feature tag in represented as four-letter ASCII string.
348 </simpara></listitem>
349 </varlistentry>
350 <varlistentry>
351 <term><link linkend="gulong">gulong</link>&#160;<structfield>property_bit</structfield>;</term>
352 <listitem><simpara>the property bit to use for this feature.  See
353                <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> for details.
354 </simpara></listitem>
355 </varlistentry>
356 </variablelist><para role="since">Since 1.18</para></refsect2>
357 <refsect2 id="PANGO-OT-TAG-MAKE--CAPS" role="macro">
358 <title>PANGO_OT_TAG_MAKE()</title>
359 <indexterm zone="PANGO-OT-TAG-MAKE--CAPS"><primary sortas="PANGO_OT_TAG_MAKE">PANGO_OT_TAG_MAKE</primary></indexterm><programlisting>#define PANGO_OT_TAG_MAKE(c1,c2,c3,c4)             ((PangoOTTag) FT_MAKE_TAG (c1, c2, c3, c4))
360 </programlisting>
361 <para>
362 Creates a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> from four characters.  This is similar and
363 compatible with the <function><link linkend="FT-MAKE-TAG--CAPS"><function>FT_MAKE_TAG()</function></link></function> macro from
364 FreeType.
365 </para><variablelist role="params">
366 <varlistentry><term><parameter>c1</parameter>&#160;:</term>
367 <listitem><simpara>First character.
368 </simpara></listitem></varlistentry>
369 <varlistentry><term><parameter>c2</parameter>&#160;:</term>
370 <listitem><simpara>Second character.
371 </simpara></listitem></varlistentry>
372 <varlistentry><term><parameter>c3</parameter>&#160;:</term>
373 <listitem><simpara>Third character.
374 </simpara></listitem></varlistentry>
375 <varlistentry><term><parameter>c4</parameter>&#160;:</term>
376 <listitem><simpara>Fourth character.
377 </simpara></listitem></varlistentry>
378 </variablelist></refsect2>
379 <refsect2 id="PANGO-OT-TAG-MAKE-FROM-STRING--CAPS" role="macro">
380 <title>PANGO_OT_TAG_MAKE_FROM_STRING()</title>
381 <indexterm zone="PANGO-OT-TAG-MAKE-FROM-STRING--CAPS"><primary sortas="PANGO_OT_TAG_MAKE_FROM_STRING">PANGO_OT_TAG_MAKE_FROM_STRING</primary></indexterm><programlisting>#define             PANGO_OT_TAG_MAKE_FROM_STRING(s)</programlisting>
382 <para>
383 Creates a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> from a string. The string should be at least
384 four characters long (pad with space characters if needed), and need
385 not be nul-terminated.  This is a convenience wrapper around
386 <link linkend="PANGO-OT-TAG-MAKE--CAPS"><function>PANGO_OT_TAG_MAKE()</function></link>, but cannot be used in certain situations, for
387 example, as a switch expression, as it dereferences pointers.
388 </para><variablelist role="params">
389 <varlistentry><term><parameter>s</parameter>&#160;:</term>
390 <listitem><simpara>The string representation of the tag.
391 </simpara></listitem></varlistentry>
392 </variablelist></refsect2>
393 <refsect2 id="PANGO-OT-ALL-GLYPHS--CAPS" role="macro" condition="since:1.16">
394 <title>PANGO_OT_ALL_GLYPHS</title>
395 <indexterm zone="PANGO-OT-ALL-GLYPHS--CAPS" role="1.16"><primary sortas="PANGO_OT_ALL_GLYPHS">PANGO_OT_ALL_GLYPHS</primary></indexterm><programlisting>#define PANGO_OT_ALL_GLYPHS                      ((guint) 0xFFFF)
396 </programlisting>
397 <para>
398 This is used as the property bit in <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> when a
399 feature should be applied to all glyphs.
400 </para><para role="since">Since 1.16</para></refsect2>
401 <refsect2 id="PANGO-OT-NO-FEATURE--CAPS" role="macro" condition="since:1.18">
402 <title>PANGO_OT_NO_FEATURE</title>
403 <indexterm zone="PANGO-OT-NO-FEATURE--CAPS" role="1.18"><primary sortas="PANGO_OT_NO_FEATURE">PANGO_OT_NO_FEATURE</primary></indexterm><programlisting>#define PANGO_OT_NO_FEATURE                      ((guint) 0xFFFF)
404 </programlisting>
405 <para>
406 This is used as a feature index that represent no feature, that is, should be
407 skipped.  It may be returned as feature index by <link linkend="pango-ot-info-find-feature"><function>pango_ot_info_find_feature()</function></link>
408 if the feature is not found, and <link linkend="pango-ot-rulset-add-feature"><function>pango_ot_rulset_add_feature()</function></link> function
409 automatically skips this value, so no special handling is required by the
410 user.
411 </para><para role="since">Since 1.18</para></refsect2>
412 <refsect2 id="PANGO-OT-NO-SCRIPT--CAPS" role="macro" condition="since:1.18">
413 <title>PANGO_OT_NO_SCRIPT</title>
414 <indexterm zone="PANGO-OT-NO-SCRIPT--CAPS" role="1.18"><primary sortas="PANGO_OT_NO_SCRIPT">PANGO_OT_NO_SCRIPT</primary></indexterm><programlisting>#define PANGO_OT_NO_SCRIPT                  ((guint) 0xFFFF)
415 </programlisting>
416 <para>
417 This is used as a script index that represent no script, that is, when the
418 requested script was not found, and a default ('DFLT') script was not found
419 either.  It may be returned as script index by <link linkend="pango-ot-info-find-script"><function>pango_ot_info_find_script()</function></link>
420 if the script or a default script are not found, all other functions
421 taking a script index essentially return if the input script index is
422 this value, so no special handling is required by the user.
423 </para><para role="since">Since 1.18</para></refsect2>
424 <refsect2 id="PANGO-OT-DEFAULT-LANGUAGE--CAPS" role="macro" condition="since:1.16">
425 <title>PANGO_OT_DEFAULT_LANGUAGE</title>
426 <indexterm zone="PANGO-OT-DEFAULT-LANGUAGE--CAPS" role="1.16"><primary sortas="PANGO_OT_DEFAULT_LANGUAGE">PANGO_OT_DEFAULT_LANGUAGE</primary></indexterm><programlisting>#define PANGO_OT_DEFAULT_LANGUAGE              ((guint) 0xFFFF)
427 </programlisting>
428 <para>
429 This is used as the language index in <link linkend="pango-ot-info-find-feature"><function>pango_ot_info_find_feature()</function></link> when
430 the default language system of the script is desired.
431 It is also returned by <link linkend="pango-ot-info-find-language"><function>pango_ot_info_find_language()</function></link> if the requested language
432 is not found, or the requested language tag was PANGO_OT_TAG_DEFAULT_LANGUAGE.
433 The end result is that one can always call <link linkend="pango-ot-tag-from-language"><function>pango_ot_tag_from_language()</function></link>
434 followed by <link linkend="pango-ot-info-find-language"><function>pango_ot_info_find_language()</function></link> and pass the result to
435 <link linkend="pango-ot-info-find-feature"><function>pango_ot_info_find_feature()</function></link> without having to worry about falling back to
436 default language system explicitly.
437 </para><para role="since">Since 1.16</para></refsect2>
438 <refsect2 id="PANGO-OT-TAG-DEFAULT-LANGUAGE--CAPS" role="macro" condition="since:1.18">
439 <title>PANGO_OT_TAG_DEFAULT_LANGUAGE</title>
440 <indexterm zone="PANGO-OT-TAG-DEFAULT-LANGUAGE--CAPS" role="1.18"><primary sortas="PANGO_OT_TAG_DEFAULT_LANGUAGE">PANGO_OT_TAG_DEFAULT_LANGUAGE</primary></indexterm><programlisting>#define PANGO_OT_TAG_DEFAULT_LANGUAGE              PANGO_OT_TAG_MAKE ('d', 'f', 'l', 't')
441 </programlisting>
442 <para>
443 This is a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> representing a special language tag 'dflt'.  It is
444 returned as language tag by <link linkend="pango-ot-tag-from-language"><function>pango_ot_tag_from_language()</function></link> if the requested
445 language is not found.  It is safe to pass this value to
446 <link linkend="pango-ot-info-find-language"><function>pango_ot_info_find_language()</function></link> as that function falls back to returning default
447 language-system if the requested language tag is not found.
448 </para><para role="since">Since 1.18</para></refsect2>
449 <refsect2 id="PANGO-OT-TAG-DEFAULT-SCRIPT--CAPS" role="macro" condition="since:1.18">
450 <title>PANGO_OT_TAG_DEFAULT_SCRIPT</title>
451 <indexterm zone="PANGO-OT-TAG-DEFAULT-SCRIPT--CAPS" role="1.18"><primary sortas="PANGO_OT_TAG_DEFAULT_SCRIPT">PANGO_OT_TAG_DEFAULT_SCRIPT</primary></indexterm><programlisting>#define PANGO_OT_TAG_DEFAULT_SCRIPT              PANGO_OT_TAG_MAKE ('D', 'F', 'L', 'T')
452 </programlisting>
453 <para>
454 This is a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> representing the special script tag 'DFLT'.  It is
455 returned as script tag by <link linkend="pango-ot-tag-from-script"><function>pango_ot_tag_from_script()</function></link> if the requested script
456 is not found.
457 </para><para role="since">Since 1.18</para></refsect2>
458 <refsect2 id="pango-ot-info-get" role="function" condition="since:1.2">
459 <title>pango_ot_info_get ()</title>
460 <indexterm zone="pango-ot-info-get" role="1.2"><primary sortas="pango_ot_info_get">pango_ot_info_get</primary></indexterm><programlisting><link linkend="PangoOTInfo">PangoOTInfo</link> *       pango_ot_info_get                   (<link linkend="FT-Face">FT_Face</link> face);</programlisting>
461 <para>
462 Returns the <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link> structure for the given FreeType font face.</para>
463 <para>
464 </para><variablelist role="params">
465 <varlistentry><term><parameter>face</parameter>&#160;:</term>
466 <listitem><simpara> a <type>FT_Face</type>.
467 </simpara></listitem></varlistentry>
468 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link> for <parameter>face</parameter>. This object will have
469 the same lifetime as <parameter>face</parameter>.
470
471 </simpara></listitem></varlistentry>
472 </variablelist><para role="since">Since 1.2</para></refsect2>
473 <refsect2 id="pango-ot-info-find-script" role="function">
474 <title>pango_ot_info_find_script ()</title>
475 <indexterm zone="pango-ot-info-find-script"><primary sortas="pango_ot_info_find_script">pango_ot_info_find_script</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_ot_info_find_script           (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
476                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
477                                                          <link linkend="PangoOTTag">PangoOTTag</link> script_tag,
478                                                          <link linkend="guint">guint</link> *script_index);</programlisting>
479 <para>
480 Finds the index of a script.  If not found, tries to find the 'DFLT'
481 and then 'dflt' scripts and return the index of that in <parameter>script_index</parameter>.
482 If none of those is found either, <link linkend="PANGO-OT-NO-SCRIPT--CAPS"><literal>PANGO_OT_NO_SCRIPT</literal></link> is placed in
483 <parameter>script_index</parameter>.
484 </para>
485 <para>
486 All other functions taking an input script_index parameter know
487 how to handle <link linkend="PANGO-OT-NO-SCRIPT--CAPS"><literal>PANGO_OT_NO_SCRIPT</literal></link>, so one can ignore the return
488 value of this function completely and proceed, to enjoy the automatic
489 fallback to the 'DFLT'/'dflt' script.</para>
490 <para>
491 </para><variablelist role="params">
492 <varlistentry><term><parameter>info</parameter>&#160;:</term>
493 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
494 </simpara></listitem></varlistentry>
495 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
496 <listitem><simpara> the table type to obtain information about.
497 </simpara></listitem></varlistentry>
498 <varlistentry><term><parameter>script_tag</parameter>&#160;:</term>
499 <listitem><simpara> the tag of the script to find.
500 </simpara></listitem></varlistentry>
501 <varlistentry><term><parameter>script_index</parameter>&#160;:</term>
502 <listitem><simpara> location to store the index of the script, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
503 </simpara></listitem></varlistentry>
504 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the script was found.
505 </simpara></listitem></varlistentry>
506 </variablelist></refsect2>
507 <refsect2 id="pango-ot-info-find-language" role="function">
508 <title>pango_ot_info_find_language ()</title>
509 <indexterm zone="pango-ot-info-find-language"><primary sortas="pango_ot_info_find_language">pango_ot_info_find_language</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_ot_info_find_language         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
510                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
511                                                          <link linkend="guint">guint</link> script_index,
512                                                          <link linkend="PangoOTTag">PangoOTTag</link> language_tag,
513                                                          <link linkend="guint">guint</link> *language_index,
514                                                          <link linkend="guint">guint</link> *required_feature_index);</programlisting>
515 <para>
516 Finds the index of a language and its required feature index.
517 If the language is not found, sets <parameter>language_index</parameter> to
518 PANGO_OT_DEFAULT_LANGUAGE and the required feature of the default language
519 system is returned in required_feature_index.  For best compatibility with
520 some fonts, also searches the language system tag 'dflt' before falling
521 back to the default language system, but that is transparent to the user.
522 The user can simply ignore the return value of this function to
523 automatically fall back to the default language system.</para>
524 <para>
525 </para><variablelist role="params">
526 <varlistentry><term><parameter>info</parameter>&#160;:</term>
527 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
528 </simpara></listitem></varlistentry>
529 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
530 <listitem><simpara> the table type to obtain information about.
531 </simpara></listitem></varlistentry>
532 <varlistentry><term><parameter>script_index</parameter>&#160;:</term>
533 <listitem><simpara> the index of the script whose languages are searched.
534 </simpara></listitem></varlistentry>
535 <varlistentry><term><parameter>language_tag</parameter>&#160;:</term>
536 <listitem><simpara> the tag of the language to find.
537 </simpara></listitem></varlistentry>
538 <varlistentry><term><parameter>language_index</parameter>&#160;:</term>
539 <listitem><simpara> location to store the index of the language, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
540 </simpara></listitem></varlistentry>
541 <varlistentry><term><parameter>required_feature_index</parameter>&#160;:</term>
542 <listitem><simpara> location to store the required feature index of
543    the language, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
544 </simpara></listitem></varlistentry>
545 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the language was found.
546 </simpara></listitem></varlistentry>
547 </variablelist></refsect2>
548 <refsect2 id="pango-ot-info-find-feature" role="function">
549 <title>pango_ot_info_find_feature ()</title>
550 <indexterm zone="pango-ot-info-find-feature"><primary sortas="pango_ot_info_find_feature">pango_ot_info_find_feature</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_ot_info_find_feature          (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
551                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
552                                                          <link linkend="PangoOTTag">PangoOTTag</link> feature_tag,
553                                                          <link linkend="guint">guint</link> script_index,
554                                                          <link linkend="guint">guint</link> language_index,
555                                                          <link linkend="guint">guint</link> *feature_index);</programlisting>
556 <para>
557 Finds the index of a feature.  If the feature is not found, sets
558 <parameter>feature_index</parameter> to PANGO_OT_NO_FEATURE, which is safe to pass to
559 <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> and similar functions.
560 </para>
561 <para>
562 In the future, this may set <parameter>feature_index</parameter> to an special value that if used
563 in <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> will ask Pango to synthesize the
564 requested feature based on Unicode properties and data.  However, this
565 function will still return <link linkend="FALSE--CAPS"><literal>FALSE</literal></link> in those cases.  So, users may want to
566 ignore the return value of this function in certain cases.</para>
567 <para>
568 </para><variablelist role="params">
569 <varlistentry><term><parameter>info</parameter>&#160;:</term>
570 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
571 </simpara></listitem></varlistentry>
572 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
573 <listitem><simpara> the table type to obtain information about.
574 </simpara></listitem></varlistentry>
575 <varlistentry><term><parameter>feature_tag</parameter>&#160;:</term>
576 <listitem><simpara> the tag of the feature to find.
577 </simpara></listitem></varlistentry>
578 <varlistentry><term><parameter>script_index</parameter>&#160;:</term>
579 <listitem><simpara> the index of the script.
580 </simpara></listitem></varlistentry>
581 <varlistentry><term><parameter>language_index</parameter>&#160;:</term>
582 <listitem><simpara> the index of the language whose features are searched,
583     or <link linkend="PANGO-OT-DEFAULT-LANGUAGE--CAPS"><literal>PANGO_OT_DEFAULT_LANGUAGE</literal></link> to use the default language of the script.
584 </simpara></listitem></varlistentry>
585 <varlistentry><term><parameter>feature_index</parameter>&#160;:</term>
586 <listitem><simpara> location to store the index of the feature, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
587 </simpara></listitem></varlistentry>
588 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the feature was found.
589 </simpara></listitem></varlistentry>
590 </variablelist></refsect2>
591 <refsect2 id="pango-ot-info-list-scripts" role="function">
592 <title>pango_ot_info_list_scripts ()</title>
593 <indexterm zone="pango-ot-info-list-scripts"><primary sortas="pango_ot_info_list_scripts">pango_ot_info_list_scripts</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link> *        pango_ot_info_list_scripts          (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
594                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type);</programlisting>
595 <para>
596 Obtains the list of available scripts.</para>
597 <para>
598 </para><variablelist role="params">
599 <varlistentry><term><parameter>info</parameter>&#160;:</term>
600 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
601 </simpara></listitem></varlistentry>
602 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
603 <listitem><simpara> the table type to obtain information about.
604 </simpara></listitem></varlistentry>
605 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of the
606   available scripts.  Should be freed using <link linkend="g-free"><function>g_free()</function></link>.
607 </simpara></listitem></varlistentry>
608 </variablelist></refsect2>
609 <refsect2 id="pango-ot-info-list-languages" role="function">
610 <title>pango_ot_info_list_languages ()</title>
611 <indexterm zone="pango-ot-info-list-languages"><primary sortas="pango_ot_info_list_languages">pango_ot_info_list_languages</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link> *        pango_ot_info_list_languages        (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
612                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
613                                                          <link linkend="guint">guint</link> script_index,
614                                                          <link linkend="PangoOTTag">PangoOTTag</link> language_tag);</programlisting>
615 <para>
616 Obtains the list of available languages for a given script.</para>
617 <para>
618 </para><variablelist role="params">
619 <varlistentry><term><parameter>info</parameter>&#160;:</term>
620 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
621 </simpara></listitem></varlistentry>
622 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
623 <listitem><simpara> the table type to obtain information about.
624 </simpara></listitem></varlistentry>
625 <varlistentry><term><parameter>script_index</parameter>&#160;:</term>
626 <listitem><simpara> the index of the script to list languages for.
627 </simpara></listitem></varlistentry>
628 <varlistentry><term><parameter>language_tag</parameter>&#160;:</term>
629 <listitem><simpara> unused parameter.
630 </simpara></listitem></varlistentry>
631 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of the
632   available languages.  Should be freed using <link linkend="g-free"><function>g_free()</function></link>.
633 </simpara></listitem></varlistentry>
634 </variablelist></refsect2>
635 <refsect2 id="pango-ot-info-list-features" role="function">
636 <title>pango_ot_info_list_features ()</title>
637 <indexterm zone="pango-ot-info-list-features"><primary sortas="pango_ot_info_list_features">pango_ot_info_list_features</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link> *        pango_ot_info_list_features         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
638                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
639                                                          <link linkend="PangoOTTag">PangoOTTag</link> tag,
640                                                          <link linkend="guint">guint</link> script_index,
641                                                          <link linkend="guint">guint</link> language_index);</programlisting>
642 <para>
643 Obtains the list of features for the given language of the given script.</para>
644 <para>
645 </para><variablelist role="params">
646 <varlistentry><term><parameter>info</parameter>&#160;:</term>
647 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
648 </simpara></listitem></varlistentry>
649 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
650 <listitem><simpara> the table type to obtain information about.
651 </simpara></listitem></varlistentry>
652 <varlistentry><term><parameter>tag</parameter>&#160;:</term>
653 <listitem><simpara> unused parameter.
654 </simpara></listitem></varlistentry>
655 <varlistentry><term><parameter>script_index</parameter>&#160;:</term>
656 <listitem><simpara> the index of the script to obtain information about.
657 </simpara></listitem></varlistentry>
658 <varlistentry><term><parameter>language_index</parameter>&#160;:</term>
659 <listitem><simpara> the index of the language to list features for, or
660     <link linkend="PANGO-OT-DEFAULT-LANGUAGE--CAPS"><literal>PANGO_OT_DEFAULT_LANGUAGE</literal></link>, to list features for the default
661     language of the script.
662 </simpara></listitem></varlistentry>
663 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of the
664 available features.  Should be freed using <link linkend="g-free"><function>g_free()</function></link>.
665 </simpara></listitem></varlistentry>
666 </variablelist></refsect2>
667 <refsect2 id="pango-ot-buffer-new" role="function" condition="since:1.4">
668 <title>pango_ot_buffer_new ()</title>
669 <indexterm zone="pango-ot-buffer-new" role="1.4"><primary sortas="pango_ot_buffer_new">pango_ot_buffer_new</primary></indexterm><programlisting><link linkend="PangoOTBuffer">PangoOTBuffer</link> *     pango_ot_buffer_new                 (<link linkend="PangoFcFont">PangoFcFont</link> *font);</programlisting>
670 <para>
671 Creates a new <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> for the given OpenType font.</para>
672 <para>
673 </para><variablelist role="params">
674 <varlistentry><term><parameter>font</parameter>&#160;:</term>
675 <listitem><simpara> a <link linkend="PangoFcFont"><type>PangoFcFont</type></link>
676 </simpara></listitem></varlistentry>
677 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the newly allocated <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, which should
678               be freed with <link linkend="pango-ot-buffer-destroy"><function>pango_ot_buffer_destroy()</function></link>.
679
680 </simpara></listitem></varlistentry>
681 </variablelist><para role="since">Since 1.4</para></refsect2>
682 <refsect2 id="pango-ot-buffer-destroy" role="function" condition="since:1.4">
683 <title>pango_ot_buffer_destroy ()</title>
684 <indexterm zone="pango-ot-buffer-destroy" role="1.4"><primary sortas="pango_ot_buffer_destroy">pango_ot_buffer_destroy</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_destroy             (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting>
685 <para>
686 Destroys a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> and free all associated memory.</para>
687 <para>
688 </para><variablelist role="params">
689 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
690 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
691 </simpara></listitem></varlistentry>
692 </variablelist><para role="since">Since 1.4</para></refsect2>
693 <refsect2 id="pango-ot-buffer-clear" role="function" condition="since:1.4">
694 <title>pango_ot_buffer_clear ()</title>
695 <indexterm zone="pango-ot-buffer-clear" role="1.4"><primary sortas="pango_ot_buffer_clear">pango_ot_buffer_clear</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_clear               (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting>
696 <para>
697 Empties a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, make it ready to add glyphs to.</para>
698 <para>
699 </para><variablelist role="params">
700 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
701 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
702 </simpara></listitem></varlistentry>
703 </variablelist><para role="since">Since 1.4</para></refsect2>
704 <refsect2 id="pango-ot-buffer-add-glyph" role="function" condition="since:1.4">
705 <title>pango_ot_buffer_add_glyph ()</title>
706 <indexterm zone="pango-ot-buffer-add-glyph" role="1.4"><primary sortas="pango_ot_buffer_add_glyph">pango_ot_buffer_add_glyph</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_add_glyph           (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
707                                                          <link linkend="guint">guint</link> glyph,
708                                                          <link linkend="guint">guint</link> properties,
709                                                          <link linkend="guint">guint</link> cluster);</programlisting>
710 <para>
711 Appends a glyph to a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, with <parameter>properties</parameter> identifying which
712 features should be applied on this glyph.  See <link linkend="pango-ruleset-add-feature"><function>pango_ruleset_add_feature()</function></link>.</para>
713 <para>
714 </para><variablelist role="params">
715 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
716 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
717 </simpara></listitem></varlistentry>
718 <varlistentry><term><parameter>glyph</parameter>&#160;:</term>
719 <listitem><simpara> the glyph index to add, like a <link linkend="PangoGlyph"><type>PangoGlyph</type></link>
720 </simpara></listitem></varlistentry>
721 <varlistentry><term><parameter>properties</parameter>&#160;:</term>
722 <listitem><simpara> the glyph properties
723 </simpara></listitem></varlistentry>
724 <varlistentry><term><parameter>cluster</parameter>&#160;:</term>
725 <listitem><simpara> the cluster that this glyph belongs to
726 </simpara></listitem></varlistentry>
727 </variablelist><para role="since">Since 1.4</para></refsect2>
728 <refsect2 id="pango-ot-buffer-set-rtl" role="function" condition="since:1.4">
729 <title>pango_ot_buffer_set_rtl ()</title>
730 <indexterm zone="pango-ot-buffer-set-rtl" role="1.4"><primary sortas="pango_ot_buffer_set_rtl">pango_ot_buffer_set_rtl</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_set_rtl             (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
731                                                          <link linkend="gboolean">gboolean</link> rtl);</programlisting>
732 <para>
733 Sets whether glyphs will be rendered right-to-left.  This setting
734 is needed for proper horizontal positioning of right-to-left scripts.</para>
735 <para>
736 </para><variablelist role="params">
737 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
738 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
739 </simpara></listitem></varlistentry>
740 <varlistentry><term><parameter>rtl</parameter>&#160;:</term>
741 <listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> for right-to-left text
742 </simpara></listitem></varlistentry>
743 </variablelist><para role="since">Since 1.4</para></refsect2>
744 <refsect2 id="pango-ot-buffer-set-zero-width-marks" role="function" condition="since:1.6">
745 <title>pango_ot_buffer_set_zero_width_marks ()</title>
746 <indexterm zone="pango-ot-buffer-set-zero-width-marks" role="1.6"><primary sortas="pango_ot_buffer_set_zero_width_marks">pango_ot_buffer_set_zero_width_marks</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_set_zero_width_marks
747                                                         (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
748                                                          <link linkend="gboolean">gboolean</link> zero_width_marks);</programlisting>
749 <para>
750 Sets whether characters with a mark class should be forced to zero width.
751 This setting is needed for proper positioning of Arabic accents,
752 but will produce incorrect results with standard OpenType Indic
753 fonts.</para>
754 <para>
755 </para><variablelist role="params">
756 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
757 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
758 </simpara></listitem></varlistentry>
759 <varlistentry><term><parameter>zero_width_marks</parameter>&#160;:</term>
760 <listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if characters with a mark class should
761  be forced to zero width.
762 </simpara></listitem></varlistentry>
763 </variablelist><para role="since">Since 1.6</para></refsect2>
764 <refsect2 id="pango-ot-buffer-get-glyphs" role="function" condition="since:1.4">
765 <title>pango_ot_buffer_get_glyphs ()</title>
766 <indexterm zone="pango-ot-buffer-get-glyphs" role="1.4"><primary sortas="pango_ot_buffer_get_glyphs">pango_ot_buffer_get_glyphs</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_get_glyphs          (const <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
767                                                          <link linkend="PangoOTGlyph">PangoOTGlyph</link> **glyphs,
768                                                          <link linkend="int">int</link> *n_glyphs);</programlisting>
769 <para>
770 Gets the glyph array contained in a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>.  The glyphs are
771 owned by the buffer and should not be freed, and are only valid as long
772 as buffer is not modified.</para>
773 <para>
774 </para><variablelist role="params">
775 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
776 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
777 </simpara></listitem></varlistentry>
778 <varlistentry><term><parameter>glyphs</parameter>&#160;:</term>
779 <listitem><simpara> location to store the array of glyphs, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
780 </simpara></listitem></varlistentry>
781 <varlistentry><term><parameter>n_glyphs</parameter>&#160;:</term>
782 <listitem><simpara> location to store the number of glyphs, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
783 </simpara></listitem></varlistentry>
784 </variablelist><para role="since">Since 1.4</para></refsect2>
785 <refsect2 id="pango-ot-buffer-output" role="function" condition="since:1.4">
786 <title>pango_ot_buffer_output ()</title>
787 <indexterm zone="pango-ot-buffer-output" role="1.4"><primary sortas="pango_ot_buffer_output">pango_ot_buffer_output</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_buffer_output              (const <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer,
788                                                          <link linkend="PangoGlyphString">PangoGlyphString</link> *glyphs);</programlisting>
789 <para>
790 Exports the glyphs in a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> into a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>.  This is
791 typically used after the OpenType layout processing is over, to convert the
792 resulting glyphs into a generic Pango glyph string.</para>
793 <para>
794 </para><variablelist role="params">
795 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
796 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>
797 </simpara></listitem></varlistentry>
798 <varlistentry><term><parameter>glyphs</parameter>&#160;:</term>
799 <listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>
800 </simpara></listitem></varlistentry>
801 </variablelist><para role="since">Since 1.4</para></refsect2>
802 <refsect2 id="pango-ot-ruleset-get-for-description" role="function" condition="since:1.18">
803 <title>pango_ot_ruleset_get_for_description ()</title>
804 <indexterm zone="pango-ot-ruleset-get-for-description" role="1.18"><primary sortas="pango_ot_ruleset_get_for_description">pango_ot_ruleset_get_for_description</primary></indexterm><programlisting>const <link linkend="PangoOTRuleset">PangoOTRuleset</link> * pango_ot_ruleset_get_for_description
805                                                         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
806                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);</programlisting>
807 <para>
808 Returns a ruleset for the given OpenType info and ruleset
809 description.  Rulesets are created on demand using
810 <link linkend="pango-ot-ruleset-new-from-description"><function>pango_ot_ruleset_new_from_description()</function></link>.
811 The returned ruleset should not be modified or destroyed.
812 </para>
813 <para>
814 The static feature map members of <parameter>desc</parameter> should be alive as
815 long as <parameter>info</parameter> is.</para>
816 <para>
817 </para><variablelist role="params">
818 <varlistentry><term><parameter>info</parameter>&#160;:</term>
819 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
820 </simpara></listitem></varlistentry>
821 <varlistentry><term><parameter>desc</parameter>&#160;:</term>
822 <listitem><simpara> a <link linkend="PangoOTRulesetDescription"><type>PangoOTRulesetDescription</type></link>.
823 </simpara></listitem></varlistentry>
824 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> for <parameter>desc</parameter>. This object will have
825 the same lifetime as <parameter>info</parameter>.
826
827 </simpara></listitem></varlistentry>
828 </variablelist><para role="since">Since 1.18</para></refsect2>
829 <refsect2 id="pango-ot-ruleset-new" role="function">
830 <title>pango_ot_ruleset_new ()</title>
831 <indexterm zone="pango-ot-ruleset-new"><primary sortas="pango_ot_ruleset_new">pango_ot_ruleset_new</primary></indexterm><programlisting><link linkend="PangoOTRuleset">PangoOTRuleset</link> *    pango_ot_ruleset_new                (<link linkend="PangoOTInfo">PangoOTInfo</link> *info);</programlisting>
832 <para>
833 Creates a new <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> for the given OpenType info.</para>
834 <para>
835 </para><variablelist role="params">
836 <varlistentry><term><parameter>info</parameter>&#160;:</term>
837 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
838 </simpara></listitem></varlistentry>
839 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the newly allocated <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>, which
840               should be freed with <link linkend="g-object-unref"><function>g_object_unref()</function></link>.
841 </simpara></listitem></varlistentry>
842 </variablelist></refsect2>
843 <refsect2 id="pango-ot-ruleset-new-for" role="function" condition="since:1.18">
844 <title>pango_ot_ruleset_new_for ()</title>
845 <indexterm zone="pango-ot-ruleset-new-for" role="1.18"><primary sortas="pango_ot_ruleset_new_for">pango_ot_ruleset_new_for</primary></indexterm><programlisting><link linkend="PangoOTRuleset">PangoOTRuleset</link> *    pango_ot_ruleset_new_for            (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
846                                                          <link linkend="PangoScript">PangoScript</link> script,
847                                                          <link linkend="PangoLanguage">PangoLanguage</link> *language);</programlisting>
848 <para>
849 Creates a new <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> for the given OpenType info, script, and
850 language.
851 </para>
852 <para>
853 This function is part of a convenience scheme that highly simplifies
854 using a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> to represent features for a specific pair of script
855 and language.  So one can use this function passing in the script and
856 language of interest, and later try to add features to the ruleset by just
857 specifying the feature name or tag, without having to deal with finding
858 script, language, or feature indices manually.
859 </para>
860 <para>
861 In excess to what <link linkend="pango-ot-ruleset-new"><function>pango_ot_ruleset_new()</function></link> does, this function will:
862 <itemizedlist>
863   <listitem>
864   Find the <link linkend="PangoOTTag"><type>PangoOTTag</type></link> script and language tags associated with
865   <parameter>script</parameter> and <parameter>language</parameter> using <link linkend="pango-ot-tag-from-script"><function>pango_ot_tag_from_script()</function></link> and
866   <link linkend="pango-ot-tag-from-language"><function>pango_ot_tag_from_language()</function></link>,
867   </listitem>
868   <listitem>
869   For each of table types <link linkend="PANGO-OT-TABLE-GSUB--CAPS"><literal>PANGO_OT_TABLE_GSUB</literal></link> and <link linkend="PANGO-OT-TABLE-GPOS--CAPS"><literal>PANGO_OT_TABLE_GPOS</literal></link>,
870   find the script index of the script tag found and the language
871   system index of the language tag found in that script system, using
872   <link linkend="pango-ot-info-find-script"><function>pango_ot_info_find_script()</function></link> and <link linkend="pango-ot-info-find-language"><function>pango_ot_info_find_language()</function></link>,
873   </listitem>
874   <listitem>
875   For found language-systems, if they have required feature
876   index, add that feature to the ruleset using
877   <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link>,
878   </listitem>
879   <listitem>
880   Remember found script and language indices for both table types,
881   and use them in future <link linkend="pango-ot-ruleset-maybe-add-feature"><function>pango_ot_ruleset_maybe_add_feature()</function></link> and
882   <link linkend="pango-ot-ruleset-maybe-add-features"><function>pango_ot_ruleset_maybe_add_features()</function></link>.
883   </listitem>
884 </itemizedlist>
885 </para>
886 <para>
887 Because of the way return values of <link linkend="pango-ot-info-find-script"><function>pango_ot_info_find_script()</function></link> and
888 <link linkend="pango-ot-info-find-language"><function>pango_ot_info_find_language()</function></link> are ignored, this function automatically
889 finds and uses the 'DFLT' script and the default language-system.</para>
890 <para>
891 </para><variablelist role="params">
892 <varlistentry><term><parameter>info</parameter>&#160;:</term>
893 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
894 </simpara></listitem></varlistentry>
895 <varlistentry><term><parameter>script</parameter>&#160;:</term>
896 <listitem><simpara> a <link linkend="PangoScript"><type>PangoScript</type></link>.
897 </simpara></listitem></varlistentry>
898 <varlistentry><term><parameter>language</parameter>&#160;:</term>
899 <listitem><simpara> a <link linkend="PangoLanguage"><type>PangoLanguage</type></link>.
900 </simpara></listitem></varlistentry>
901 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the newly allocated <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>, which
902               should be freed with <link linkend="g-object-unref"><function>g_object_unref()</function></link>.
903
904 </simpara></listitem></varlistentry>
905 </variablelist><para role="since">Since 1.18</para></refsect2>
906 <refsect2 id="pango-ot-ruleset-new-from-description" role="function" condition="since:1.18">
907 <title>pango_ot_ruleset_new_from_description ()</title>
908 <indexterm zone="pango-ot-ruleset-new-from-description" role="1.18"><primary sortas="pango_ot_ruleset_new_from_description">pango_ot_ruleset_new_from_description</primary></indexterm><programlisting><link linkend="PangoOTRuleset">PangoOTRuleset</link> *    pango_ot_ruleset_new_from_description
909                                                         (<link linkend="PangoOTInfo">PangoOTInfo</link> *info,
910                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);</programlisting>
911 <para>
912 Creates a new <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link> for the given OpenType infor and
913 matching the given ruleset description.
914 </para>
915 <para>
916 This is a convenience function that calls <link linkend="pango-ot-ruleset-new-for"><function>pango_ot_ruleset_new_for()</function></link> and
917 adds the static GSUB/GPOS features to the resulting ruleset, followed by
918 adding other features to both GSUB and GPOS.
919 </para>
920 <para>
921 The static feature map members of <parameter>desc</parameter> should be alive as
922 long as <parameter>info</parameter> is.</para>
923 <para>
924 </para><variablelist role="params">
925 <varlistentry><term><parameter>info</parameter>&#160;:</term>
926 <listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.
927 </simpara></listitem></varlistentry>
928 <varlistentry><term><parameter>desc</parameter>&#160;:</term>
929 <listitem><simpara> a <link linkend="PangoOTRulesetDescription"><type>PangoOTRulesetDescription</type></link>.
930 </simpara></listitem></varlistentry>
931 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the newly allocated <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>, which
932               should be freed with <link linkend="g-object-unref"><function>g_object_unref()</function></link>.
933
934 </simpara></listitem></varlistentry>
935 </variablelist><para role="since">Since 1.18</para></refsect2>
936 <refsect2 id="pango-ot-ruleset-add-feature" role="function">
937 <title>pango_ot_ruleset_add_feature ()</title>
938 <indexterm zone="pango-ot-ruleset-add-feature"><primary sortas="pango_ot_ruleset_add_feature">pango_ot_ruleset_add_feature</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_ruleset_add_feature        (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
939                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
940                                                          <link linkend="guint">guint</link> feature_index,
941                                                          <link linkend="gulong">gulong</link> property_bit);</programlisting>
942 <para>
943 Adds a feature to the ruleset.</para>
944 <para>
945 </para><variablelist role="params">
946 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
947 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
948 </simpara></listitem></varlistentry>
949 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
950 <listitem><simpara> the table type to add a feature to.
951 </simpara></listitem></varlistentry>
952 <varlistentry><term><parameter>feature_index</parameter>&#160;:</term>
953 <listitem><simpara> the index of the feature to add.
954 </simpara></listitem></varlistentry>
955 <varlistentry><term><parameter>property_bit</parameter>&#160;:</term>
956 <listitem><simpara> the property bit to use for this feature. Used to identify
957                the glyphs that this feature should be applied to, or
958                <link linkend="PANGO-OT-ALL-GLYPHS--CAPS"><literal>PANGO_OT_ALL_GLYPHS</literal></link> if it should be applied to all glyphs.
959 </simpara></listitem></varlistentry>
960 </variablelist></refsect2>
961 <refsect2 id="pango-ot-ruleset-maybe-add-feature" role="function" condition="since:1.18">
962 <title>pango_ot_ruleset_maybe_add_feature ()</title>
963 <indexterm zone="pango-ot-ruleset-maybe-add-feature" role="1.18"><primary sortas="pango_ot_ruleset_maybe_add_feature">pango_ot_ruleset_maybe_add_feature</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_ot_ruleset_maybe_add_feature  (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
964                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
965                                                          <link linkend="PangoOTTag">PangoOTTag</link> feature_tag,
966                                                          <link linkend="gulong">gulong</link> property_bit);</programlisting>
967 <para>
968 This is a convenience function that first tries to find the feature
969 using <link linkend="pango-ot-info-find-feature"><function>pango_ot_info_find_feature()</function></link> and the ruleset script and language
970 passed to <link linkend="pango-ot-ruleset-new-for"><function>pango_ot_ruleset_new_for()</function></link>,
971 and if the feature is found, adds it to the ruleset.
972 </para>
973 <para>
974 If <parameter>ruleset</parameter> was not created using <link linkend="pango-ot-ruleset-new-for"><function>pango_ot_ruleset_new_for()</function></link>, this function
975 does nothing.</para>
976 <para>
977 </para><variablelist role="params">
978 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
979 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
980 </simpara></listitem></varlistentry>
981 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
982 <listitem><simpara> the table type to add a feature to.
983 </simpara></listitem></varlistentry>
984 <varlistentry><term><parameter>feature_tag</parameter>&#160;:</term>
985 <listitem><simpara> the tag of the feature to add.
986 </simpara></listitem></varlistentry>
987 <varlistentry><term><parameter>property_bit</parameter>&#160;:</term>
988 <listitem><simpara> the property bit to use for this feature. Used to identify
989                the glyphs that this feature should be applied to, or
990                <link linkend="PANGO-OT-ALL-GLYPHS--CAPS"><literal>PANGO_OT_ALL_GLYPHS</literal></link> if it should be applied to all glyphs.
991 </simpara></listitem></varlistentry>
992 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if the feature was found and added to ruleset,
993               <link linkend="FALSE--CAPS"><literal>FALSE</literal></link> otherwise.
994
995 </simpara></listitem></varlistentry>
996 </variablelist><para role="since">Since 1.18</para></refsect2>
997 <refsect2 id="pango-ot-ruleset-maybe-add-features" role="function" condition="since:1.18">
998 <title>pango_ot_ruleset_maybe_add_features ()</title>
999 <indexterm zone="pango-ot-ruleset-maybe-add-features" role="1.18"><primary sortas="pango_ot_ruleset_maybe_add_features">pango_ot_ruleset_maybe_add_features</primary></indexterm><programlisting><link linkend="guint">guint</link>               pango_ot_ruleset_maybe_add_features (<link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
1000                                                          <link linkend="PangoOTTableType">PangoOTTableType</link> table_type,
1001                                                          const <link linkend="PangoOTFeatureMap">PangoOTFeatureMap</link> *features,
1002                                                          <link linkend="guint">guint</link> n_features);</programlisting>
1003 <para>
1004 This is a convenience function that 
1005 for each feature in the feature map array <parameter>features</parameter>
1006 converts the feature name to a <link linkend="PangoOTTag"><type>PangoOTTag</type></link> feature tag using <link linkend="PANGO-OT-TAG-MAKE--CAPS"><function>PANGO_OT_TAG_MAKE()</function></link>
1007 and calls <link linkend="pango-ot-ruleset-maybe-add-feature"><function>pango_ot_ruleset_maybe_add_feature()</function></link> on it.</para>
1008 <para>
1009 </para><variablelist role="params">
1010 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
1011 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
1012 </simpara></listitem></varlistentry>
1013 <varlistentry><term><parameter>table_type</parameter>&#160;:</term>
1014 <listitem><simpara> the table type to add features to.
1015 </simpara></listitem></varlistentry>
1016 <varlistentry><term><parameter>features</parameter>&#160;:</term>
1017 <listitem><simpara> array of feature name and property bits to add.
1018 </simpara></listitem></varlistentry>
1019 <varlistentry><term><parameter>n_features</parameter>&#160;:</term>
1020 <listitem><simpara> number of feature records in <parameter>features</parameter> array.
1021 </simpara></listitem></varlistentry>
1022 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> The number of features in <parameter>features</parameter> that were found
1023               and added to <parameter>ruleset</parameter>.
1024
1025 </simpara></listitem></varlistentry>
1026 </variablelist><para role="since">Since 1.18</para></refsect2>
1027 <refsect2 id="pango-ot-ruleset-get-feature-count" role="function" condition="since:1.18">
1028 <title>pango_ot_ruleset_get_feature_count ()</title>
1029 <indexterm zone="pango-ot-ruleset-get-feature-count" role="1.18"><primary sortas="pango_ot_ruleset_get_feature_count">pango_ot_ruleset_get_feature_count</primary></indexterm><programlisting><link linkend="guint">guint</link>               pango_ot_ruleset_get_feature_count  (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
1030                                                          <link linkend="guint">guint</link> *n_gsub_features,
1031                                                          <link linkend="guint">guint</link> *n_gpos_features);</programlisting>
1032 <para>
1033 Gets the number of GSUB and GPOS features in the ruleset.</para>
1034 <para>
1035 </para><variablelist role="params">
1036 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
1037 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
1038 </simpara></listitem></varlistentry>
1039 <varlistentry><term><parameter>n_gsub_features</parameter>&#160;:</term>
1040 <listitem><simpara> location to store number of GSUB features, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
1041 </simpara></listitem></varlistentry>
1042 <varlistentry><term><parameter>n_gpos_features</parameter>&#160;:</term>
1043 <listitem><simpara> location to store number of GPOS features, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
1044 </simpara></listitem></varlistentry>
1045 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> Total number of features in the <parameter>ruleset</parameter>.
1046
1047 </simpara></listitem></varlistentry>
1048 </variablelist><para role="since">Since 1.18</para></refsect2>
1049 <refsect2 id="pango-ot-ruleset-substitute" role="function" condition="since:1.4">
1050 <title>pango_ot_ruleset_substitute ()</title>
1051 <indexterm zone="pango-ot-ruleset-substitute" role="1.4"><primary sortas="pango_ot_ruleset_substitute">pango_ot_ruleset_substitute</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_ruleset_substitute         (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
1052                                                          <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting>
1053 <para>
1054 Performs the OpenType GSUB substitution on <parameter>buffer</parameter> using the features
1055 in <parameter>ruleset</parameter></para>
1056 <para>
1057 </para><variablelist role="params">
1058 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
1059 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
1060 </simpara></listitem></varlistentry>
1061 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
1062 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>.
1063 </simpara></listitem></varlistentry>
1064 </variablelist><para role="since">Since 1.4</para></refsect2>
1065 <refsect2 id="pango-ot-ruleset-position" role="function" condition="since:1.4">
1066 <title>pango_ot_ruleset_position ()</title>
1067 <indexterm zone="pango-ot-ruleset-position" role="1.4"><primary sortas="pango_ot_ruleset_position">pango_ot_ruleset_position</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_ruleset_position           (const <link linkend="PangoOTRuleset">PangoOTRuleset</link> *ruleset,
1068                                                          <link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting>
1069 <para>
1070 Performs the OpenType GPOS positioning on <parameter>buffer</parameter> using the features
1071 in <parameter>ruleset</parameter></para>
1072 <para>
1073 </para><variablelist role="params">
1074 <varlistentry><term><parameter>ruleset</parameter>&#160;:</term>
1075 <listitem><simpara> a <link linkend="PangoOTRuleset"><type>PangoOTRuleset</type></link>.
1076 </simpara></listitem></varlistentry>
1077 <varlistentry><term><parameter>buffer</parameter>&#160;:</term>
1078 <listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>.
1079 </simpara></listitem></varlistentry>
1080 </variablelist><para role="since">Since 1.4</para></refsect2>
1081 <refsect2 id="pango-ot-ruleset-description-copy" role="function" condition="since:1.18">
1082 <title>pango_ot_ruleset_description_copy ()</title>
1083 <indexterm zone="pango-ot-ruleset-description-copy" role="1.18"><primary sortas="pango_ot_ruleset_description_copy">pango_ot_ruleset_description_copy</primary></indexterm><programlisting><link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> * pango_ot_ruleset_description_copy
1084                                                         (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);</programlisting>
1085 <para>
1086 Creates a copy of <parameter>desc</parameter>, which should be freed with
1087 <link linkend="pango-ot-ruleset-description-free"><function>pango_ot_ruleset_description_free()</function></link>. Primarily used internally
1088 by <link linkend="pango-ot-ruleset-get-for-description"><function>pango_ot_ruleset_get_for_description()</function></link> to cache rulesets for
1089 ruleset descriptions.</para>
1090 <para>
1091 </para><variablelist role="params">
1092 <varlistentry><term><parameter>desc</parameter>&#160;:</term>
1093 <listitem><simpara> ruleset description to copy
1094 </simpara></listitem></varlistentry>
1095 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the newly allocated <link linkend="PangoOTRulesetDescription"><type>PangoOTRulesetDescription</type></link>, which
1096               should be freed with <link linkend="pango-ot-ruleset-description-free"><function>pango_ot_ruleset_description_free()</function></link>.
1097
1098 </simpara></listitem></varlistentry>
1099 </variablelist><para role="since">Since 1.18</para></refsect2>
1100 <refsect2 id="pango-ot-ruleset-description-equal" role="function" condition="since:1.18">
1101 <title>pango_ot_ruleset_description_equal ()</title>
1102 <indexterm zone="pango-ot-ruleset-description-equal" role="1.18"><primary sortas="pango_ot_ruleset_description_equal">pango_ot_ruleset_description_equal</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_ot_ruleset_description_equal  (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc1,
1103                                                          const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc2);</programlisting>
1104 <para>
1105 Compares two ruleset descriptions for equality.
1106 Two ruleset descriptions are considered equal if the rulesets
1107 they describe are provably identical.  This means that their
1108 script, language, and all feature sets should be equal.  For static feature
1109 sets, the array addresses are compared directly, while for other
1110 features, the list of features is compared one by one.
1111 (Two ruleset descriptions may result in identical rulesets
1112 being created, but still compare <link linkend="FALSE--CAPS"><literal>FALSE</literal></link>.)</para>
1113 <para>
1114 </para><variablelist role="params">
1115 <varlistentry><term><parameter>desc1</parameter>&#160;:</term>
1116 <listitem><simpara> a ruleset description
1117 </simpara></listitem></varlistentry>
1118 <varlistentry><term><parameter>desc2</parameter>&#160;:</term>
1119 <listitem><simpara> a ruleset description
1120 </simpara></listitem></varlistentry>
1121 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if two ruleset descriptions are identical,
1122               <link linkend="FALSE--CAPS"><literal>FALSE</literal></link> otherwise.
1123
1124 </simpara></listitem></varlistentry>
1125 </variablelist><para role="since">Since 1.18</para></refsect2>
1126 <refsect2 id="pango-ot-ruleset-description-free" role="function" condition="since:1.18">
1127 <title>pango_ot_ruleset_description_free ()</title>
1128 <indexterm zone="pango-ot-ruleset-description-free" role="1.18"><primary sortas="pango_ot_ruleset_description_free">pango_ot_ruleset_description_free</primary></indexterm><programlisting><link linkend="void">void</link>                pango_ot_ruleset_description_free   (<link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);</programlisting>
1129 <para>
1130 Frees a ruleset description allocated by 
1131 <link linkend="pango-ot-ruleset-description-copy"><function>pango_ot_ruleset_description_copy()</function></link>.</para>
1132 <para>
1133 </para><variablelist role="params">
1134 <varlistentry><term><parameter>desc</parameter>&#160;:</term>
1135 <listitem><simpara> an allocated <link linkend="PangoOTRulesetDescription"><type>PangoOTRulesetDescription</type></link>
1136 </simpara></listitem></varlistentry>
1137 </variablelist><para role="since">Since 1.18</para></refsect2>
1138 <refsect2 id="pango-ot-ruleset-description-hash" role="function" condition="since:1.18">
1139 <title>pango_ot_ruleset_description_hash ()</title>
1140 <indexterm zone="pango-ot-ruleset-description-hash" role="1.18"><primary sortas="pango_ot_ruleset_description_hash">pango_ot_ruleset_description_hash</primary></indexterm><programlisting><link linkend="guint">guint</link>               pango_ot_ruleset_description_hash   (const <link linkend="PangoOTRulesetDescription">PangoOTRulesetDescription</link> *desc);</programlisting>
1141 <para>
1142 Computes a hash of a <link linkend="PangoOTRulesetDescription"><type>PangoOTRulesetDescription</type></link> structure suitable
1143 to be used, for example, as an argument to <link linkend="g-hash-table-new"><function>g_hash_table_new()</function></link>.</para>
1144 <para>
1145 </para><variablelist role="params">
1146 <varlistentry><term><parameter>desc</parameter>&#160;:</term>
1147 <listitem><simpara> a ruleset description
1148 </simpara></listitem></varlistentry>
1149 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the hash value.
1150
1151 </simpara></listitem></varlistentry>
1152 </variablelist><para role="since">Since 1.18</para></refsect2>
1153 <refsect2 id="pango-ot-tag-from-language" role="function" condition="since:1.18">
1154 <title>pango_ot_tag_from_language ()</title>
1155 <indexterm zone="pango-ot-tag-from-language" role="1.18"><primary sortas="pango_ot_tag_from_language">pango_ot_tag_from_language</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link>          pango_ot_tag_from_language          (<link linkend="PangoLanguage">PangoLanguage</link> *language);</programlisting>
1156 <para>
1157 Finds the OpenType language-system tag best describing <parameter>language</parameter>.</para>
1158 <para>
1159 </para><variablelist role="params">
1160 <varlistentry><term><parameter>language</parameter>&#160;:</term>
1161 <listitem><simpara> A <link linkend="PangoLanguage"><type>PangoLanguage</type></link>, or <link linkend="NULL--CAPS"><literal>NULL</literal></link>
1162 </simpara></listitem></varlistentry>
1163 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="PangoOTTag"><type>PangoOTTag</type></link> best matching <parameter>language</parameter> or
1164 <link linkend="PANGO-OT-TAG-DEFAULT-LANGUAGE--CAPS"><literal>PANGO_OT_TAG_DEFAULT_LANGUAGE</literal></link> if none found or if <parameter>language</parameter>
1165 is <link linkend="NULL--CAPS"><literal>NULL</literal></link>.
1166
1167 </simpara></listitem></varlistentry>
1168 </variablelist><para role="since">Since 1.18</para></refsect2>
1169 <refsect2 id="pango-ot-tag-from-script" role="function" condition="since:1.18">
1170 <title>pango_ot_tag_from_script ()</title>
1171 <indexterm zone="pango-ot-tag-from-script" role="1.18"><primary sortas="pango_ot_tag_from_script">pango_ot_tag_from_script</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link>          pango_ot_tag_from_script            (<link linkend="PangoScript">PangoScript</link> script);</programlisting>
1172 <para>
1173 Finds the OpenType script tag corresponding to <parameter>script</parameter>.
1174 </para>
1175 <para>
1176 The <link linkend="PANGO-SCRIPT-COMMON--CAPS"><literal>PANGO_SCRIPT_COMMON</literal></link>, <link linkend="PANGO-SCRIPT-INHERITED--CAPS"><literal>PANGO_SCRIPT_INHERITED</literal></link>, and
1177 <link linkend="PANGO-SCRIPT-UNKNOWN--CAPS"><literal>PANGO_SCRIPT_UNKNOWN</literal></link> scripts are mapped to the OpenType
1178 'DFLT' script tag that is also defined as
1179 <link linkend="PANGO-OT-TAG-DEFAULT-SCRIPT--CAPS"><literal>PANGO_OT_TAG_DEFAULT_SCRIPT</literal></link>.
1180 </para>
1181 <para>
1182 Note that multiple <link linkend="PangoScript"><type>PangoScript</type></link> values may map to the same
1183 OpenType script tag.  In particular, <link linkend="PANGO-SCRIPT-HIRAGANA--CAPS"><literal>PANGO_SCRIPT_HIRAGANA</literal></link>
1184 and <link linkend="PANGO-SCRIPT-KATAKANA--CAPS"><literal>PANGO_SCRIPT_KATAKANA</literal></link> both map to the OT tag 'kana'.</para>
1185 <para>
1186 </para><variablelist role="params">
1187 <varlistentry><term><parameter>script</parameter>&#160;:</term>
1188 <listitem><simpara> A <link linkend="PangoScript"><type>PangoScript</type></link>
1189 </simpara></listitem></varlistentry>
1190 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="PangoOTTag"><type>PangoOTTag</type></link> corresponding to <parameter>script</parameter> or
1191 <link linkend="PANGO-OT-TAG-DEFAULT-SCRIPT--CAPS"><literal>PANGO_OT_TAG_DEFAULT_SCRIPT</literal></link> if none found.
1192
1193 </simpara></listitem></varlistentry>
1194 </variablelist><para role="since">Since 1.18</para></refsect2>
1195 <refsect2 id="pango-ot-tag-to-language" role="function" condition="since:1.18">
1196 <title>pango_ot_tag_to_language ()</title>
1197 <indexterm zone="pango-ot-tag-to-language" role="1.18"><primary sortas="pango_ot_tag_to_language">pango_ot_tag_to_language</primary></indexterm><programlisting><link linkend="PangoLanguage">PangoLanguage</link> *     pango_ot_tag_to_language            (<link linkend="PangoOTTag">PangoOTTag</link> language_tag);</programlisting>
1198 <para>
1199 Finds a <link linkend="PangoLanguage"><type>PangoLanguage</type></link> corresponding to <parameter>language_tag</parameter>.</para>
1200 <para>
1201 </para><variablelist role="params">
1202 <varlistentry><term><parameter>language_tag</parameter>&#160;:</term>
1203 <listitem><simpara> A <link linkend="PangoOTTag"><type>PangoOTTag</type></link> OpenType language-system tag
1204 </simpara></listitem></varlistentry>
1205 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="PangoLanguage"><type>PangoLanguage</type></link> best matching <parameter>language_tag</parameter> or
1206 <link linkend="PangoLanguage"><type>PangoLanguage</type></link> corresponding to the string "xx" if none found.
1207
1208 </simpara></listitem></varlistentry>
1209 </variablelist><para role="since">Since 1.18</para></refsect2>
1210 <refsect2 id="pango-ot-tag-to-script" role="function" condition="since:1.18">
1211 <title>pango_ot_tag_to_script ()</title>
1212 <indexterm zone="pango-ot-tag-to-script" role="1.18"><primary sortas="pango_ot_tag_to_script">pango_ot_tag_to_script</primary></indexterm><programlisting><link linkend="PangoScript">PangoScript</link>         pango_ot_tag_to_script              (<link linkend="PangoOTTag">PangoOTTag</link> script_tag);</programlisting>
1213 <para>
1214 Finds the <link linkend="PangoScript"><type>PangoScript</type></link> corresponding to <parameter>script_tag</parameter>.
1215 </para>
1216 <para>
1217 The 'DFLT' script tag is mapped to <link linkend="PANGO-SCRIPT-COMMON--CAPS"><literal>PANGO_SCRIPT_COMMON</literal></link>.
1218 </para>
1219 <para>
1220 Note that an OpenType script tag may correspond to multiple
1221 <link linkend="PangoScript"><type>PangoScript</type></link> values.  In such cases, the <link linkend="PangoScript"><type>PangoScript</type></link> value
1222 with the smallest value is returned.
1223 In particular, <link linkend="PANGO-SCRIPT-HIRAGANA--CAPS"><literal>PANGO_SCRIPT_HIRAGANA</literal></link>
1224 and <link linkend="PANGO-SCRIPT-KATAKANA--CAPS"><literal>PANGO_SCRIPT_KATAKANA</literal></link> both map to the OT tag 'kana'.
1225 This function will return <link linkend="PANGO-SCRIPT-HIRAGANA--CAPS"><literal>PANGO_SCRIPT_HIRAGANA</literal></link> for
1226 'kana'.</para>
1227 <para>
1228 </para><variablelist role="params">
1229 <varlistentry><term><parameter>script_tag</parameter>&#160;:</term>
1230 <listitem><simpara> A <link linkend="PangoOTTag"><type>PangoOTTag</type></link> OpenType script tag
1231 </simpara></listitem></varlistentry>
1232 <varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="PangoScript"><type>PangoScript</type></link> corresponding to <parameter>script_tag</parameter> or
1233 <link linkend="PANGO-SCRIPT-UNKNOWN--CAPS"><literal>PANGO_SCRIPT_UNKNOWN</literal></link> if none found.
1234
1235 </simpara></listitem></varlistentry>
1236 </variablelist><para role="since">Since 1.18</para></refsect2>
1237
1238 </refsect1>
1239
1240
1241
1242
1243 </refentry>