Git init
[external/pango1.0.git] / docs / html / pango-Modules.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <title>Modules</title>
6 <meta name="generator" content="DocBook XSL Stylesheets V1.74.3">
7 <link rel="home" href="index.html" title="Pango Reference Manual">
8 <link rel="up" href="lowlevel.html" title="Low Level Functionality">
9 <link rel="prev" href="PangoEngineShape.html" title="PangoEngineShape">
10 <link rel="next" href="pango-Miscellaneous-Utilities.html" title="Miscellaneous Utilities">
11 <meta name="generator" content="GTK-Doc V1.11 (XML mode)">
12 <link rel="stylesheet" href="style.css" type="text/css">
13 <link rel="chapter" href="pango.html" title="Basic Pango Interfaces">
14 <link rel="chapter" href="rendering.html" title="Rendering with Pango">
15 <link rel="chapter" href="lowlevel.html" title="Low Level Functionality">
16 <link rel="chapter" href="tools.html" title="Pango Tools">
17 <link rel="chapter" href="pango-hierarchy.html" title="Object Hierarchy">
18 <link rel="index" href="index-all.html" title="Index">
19 <link rel="index" href="index-deprecated.html" title="Index of deprecated symbols">
20 <link rel="index" href="index-1.2.html" title="Index of new symbols in 1.2">
21 <link rel="index" href="index-1.4.html" title="Index of new symbols in 1.4">
22 <link rel="index" href="index-1.6.html" title="Index of new symbols in 1.6">
23 <link rel="index" href="index-1.8.html" title="Index of new symbols in 1.8">
24 <link rel="index" href="index-1.10.html" title="Index of new symbols in 1.10">
25 <link rel="index" href="index-1.12.html" title="Index of new symbols in 1.12">
26 <link rel="index" href="index-1.14.html" title="Index of new symbols in 1.14">
27 <link rel="index" href="index-1.16.html" title="Index of new symbols in 1.16">
28 <link rel="index" href="index-1.18.html" title="Index of new symbols in 1.18">
29 <link rel="index" href="index-1.20.html" title="Index of new symbols in 1.20">
30 <link rel="index" href="index-1.22.html" title="Index of new symbols in 1.22">
31 <link rel="index" href="index-1.24.html" title="Index of new symbols in 1.24">
32 <link rel="index" href="index-1.26.html" title="Index of new symbols in 1.26">
33 </head>
34 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
35 <table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2">
36 <tr valign="middle">
37 <td><a accesskey="p" href="PangoEngineShape.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
38 <td><a accesskey="u" href="lowlevel.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
39 <td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
40 <th width="100%" align="center">Pango Reference Manual</th>
41 <td><a accesskey="n" href="pango-Miscellaneous-Utilities.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
42 </tr>
43 <tr><td colspan="5" class="shortcuts">
44 <a href="#pango-Modules.synopsis" class="shortcut">Top</a>
45                  | 
46                 <a href="#pango-Modules.description" class="shortcut">Description</a>
47 </td></tr>
48 </table>
49 <div class="refentry" lang="en">
50 <a name="pango-Modules"></a><div class="titlepage"></div>
51 <div class="refnamediv"><table width="100%"><tr>
52 <td valign="top">
53 <h2><span class="refentrytitle"><a name="pango-Modules.top_of_page"></a>Modules</span></h2>
54 <p>Modules — Support for loadable modules</p>
55 </td>
56 <td valign="top" align="right"></td>
57 </tr></table></div>
58 <div class="refsynopsisdiv">
59 <a name="pango-Modules.synopsis"></a><h2>Synopsis</h2>
60 <pre class="synopsis">
61                     <a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule">PangoIncludedModule</a>;
62                     <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a>;
63                     <a class="link" href="pango-Modules.html#PangoMapEntry" title="PangoMapEntry">PangoMapEntry</a>;
64 <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *          <a class="link" href="pango-Modules.html#pango-find-map" title="pango_find_map ()">pango_find_map</a>                      (<a class="link" href="pango-Scripts-and-Languages.html#PangoLanguage" title="PangoLanguage">PangoLanguage</a> *language,
65                                                          <a
66 href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"
67 >guint</a> engine_type_id,
68                                                          <a
69 href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"
70 >guint</a> render_type_id);
71 <a class="link" href="pango-Engines.html#PangoEngine">PangoEngine</a> *       <a class="link" href="pango-Modules.html#pango-map-get-engine" title="pango_map_get_engine ()">pango_map_get_engine</a>                (<a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *map,
72                                                          <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript">PangoScript</a> script);
73 void                <a class="link" href="pango-Modules.html#pango-map-get-engines" title="pango_map_get_engines ()">pango_map_get_engines</a>               (<a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *map,
74                                                          <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript">PangoScript</a> script,
75                                                          <a
76 href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"
77 >GSList</a> **exact_engines,
78                                                          <a
79 href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"
80 >GSList</a> **fallback_engines);
81 void                <a class="link" href="pango-Modules.html#pango-module-register" title="pango_module_register ()">pango_module_register</a>               (<a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule">PangoIncludedModule</a> *module);
82 </pre>
83 </div>
84 <div class="refsect1" lang="en">
85 <a name="pango-Modules.description"></a><h2>Description</h2>
86 <p>
87 Functions and macros in this section are used to support loading dynamic
88 modules that add engines to Pango at run time.
89 </p>
90 </div>
91 <div class="refsect1" lang="en">
92 <a name="pango-Modules.details"></a><h2>Details</h2>
93 <div class="refsect2" lang="en">
94 <a name="PangoIncludedModule"></a><h3>PangoIncludedModule</h3>
95 <pre class="programlisting">typedef struct {
96   void (*list) (PangoEngineInfo **engines,
97                 int              *n_engines);
98   void (*init) (GTypeModule      *module);
99   void (*exit) (void);
100   PangoEngine *(*create) (const char       *id);
101 } PangoIncludedModule;
102 </pre>
103 <p>
104 The <a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule"><span class="type">PangoIncludedModule</span></a> structure for a statically linked module
105 contains the functions that would otherwise be loaded from a dynamically
106 loaded module.
107 </p>
108 <div class="variablelist"><table border="0">
109 <col align="left" valign="top">
110 <tbody>
111 <tr>
112 <td><p><span class="term"><em class="structfield"><code>list</code></em> ()</span></p></td>
113 <td>a function that lists the engines defined in this module.
114 </td>
115 </tr>
116 <tr>
117 <td><p><span class="term"><em class="structfield"><code>init</code></em> ()</span></p></td>
118 <td>a function to initialize the module.
119 </td>
120 </tr>
121 <tr>
122 <td><p><span class="term"><em class="structfield"><code>exit</code></em> ()</span></p></td>
123 <td>a function to finalize the module.
124 </td>
125 </tr>
126 <tr>
127 <td><p><span class="term"><em class="structfield"><code>create</code></em> ()</span></p></td>
128 <td>a function to create an engine, given the engine name.
129 </td>
130 </tr>
131 </tbody>
132 </table></div>
133 </div>
134 <hr>
135 <div class="refsect2" lang="en">
136 <a name="PangoMap"></a><h3>PangoMap</h3>
137 <pre class="programlisting">typedef struct _PangoMap PangoMap;</pre>
138 <p>
139 A <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap"><span class="type">PangoMap</span></a> structure can be used to determine the engine to
140 use for each character.
141 </p>
142 </div>
143 <hr>
144 <div class="refsect2" lang="en">
145 <a name="PangoMapEntry"></a><h3>PangoMapEntry</h3>
146 <pre class="programlisting">typedef struct _PangoMapEntry PangoMapEntry;</pre>
147 <p>
148 A <a class="link" href="pango-Modules.html#PangoMapEntry" title="PangoMapEntry"><span class="type">PangoMapEntry</span></a> contains information about the engine that should be used
149 for the codepoint to which this entry belongs and also whether the engine
150 matches the language tag for this entry's map exactly or just approximately.
151 </p>
152 </div>
153 <hr>
154 <div class="refsect2" lang="en">
155 <a name="pango-find-map"></a><h3>pango_find_map ()</h3>
156 <pre class="programlisting"><a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *          pango_find_map                      (<a class="link" href="pango-Scripts-and-Languages.html#PangoLanguage" title="PangoLanguage">PangoLanguage</a> *language,
157                                                          <a
158 href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"
159 >guint</a> engine_type_id,
160                                                          <a
161 href="http://library.gnome.org/devel/glib/unstable/glib-Basic-Types.html#guint"
162 >guint</a> render_type_id);</pre>
163 <p>
164 Locate a <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap"><span class="type">PangoMap</span></a> for a particular engine type and render
165 type. The resulting map can be used to determine the engine
166 for each character.</p>
167 <p>
168 </p>
169 <div class="variablelist"><table border="0">
170 <col align="left" valign="top">
171 <tbody>
172 <tr>
173 <td><p><span class="term"><em class="parameter"><code>language</code></em> :</span></p></td>
174 <td> the language tag for which to find the map
175 </td>
176 </tr>
177 <tr>
178 <td><p><span class="term"><em class="parameter"><code>engine_type_id</code></em> :</span></p></td>
179 <td> the engine type for the map to find
180 </td>
181 </tr>
182 <tr>
183 <td><p><span class="term"><em class="parameter"><code>render_type_id</code></em> :</span></p></td>
184 <td> the render type for the map to find
185 </td>
186 </tr>
187 <tr>
188 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
189 <td> the suitable <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap"><span class="type">PangoMap</span></a>.
190 </td>
191 </tr>
192 </tbody>
193 </table></div>
194 </div>
195 <hr>
196 <div class="refsect2" lang="en">
197 <a name="pango-map-get-engine"></a><h3>pango_map_get_engine ()</h3>
198 <pre class="programlisting"><a class="link" href="pango-Engines.html#PangoEngine">PangoEngine</a> *       pango_map_get_engine                (<a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *map,
199                                                          <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript">PangoScript</a> script);</pre>
200 <p>
201 Returns the best engine listed in the map for a given script</p>
202 <p>
203 </p>
204 <div class="variablelist"><table border="0">
205 <col align="left" valign="top">
206 <tbody>
207 <tr>
208 <td><p><span class="term"><em class="parameter"><code>map</code></em> :</span></p></td>
209 <td> a <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap"><span class="type">PangoMap</span></a>
210 </td>
211 </tr>
212 <tr>
213 <td><p><span class="term"><em class="parameter"><code>script</code></em> :</span></p></td>
214 <td> a <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript"><span class="type">PangoScript</span></a>
215 </td>
216 </tr>
217 <tr>
218 <td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td>
219 <td> the best engine, if one is listed for the script,
220    or <a
221 href="http://library.gnome.org/devel/glib/unstable/glib-Standard-Macros.html#NULL--CAPS"
222 ><code class="literal">NULL</code></a>. The lookup may cause the engine to be loaded;
223    once an engine is loaded, it won't be unloaded. If multiple
224    engines are exact for the script, the choice of which is
225    returned is arbitrary.
226 </td>
227 </tr>
228 </tbody>
229 </table></div>
230 </div>
231 <hr>
232 <div class="refsect2" lang="en">
233 <a name="pango-map-get-engines"></a><h3>pango_map_get_engines ()</h3>
234 <pre class="programlisting">void                pango_map_get_engines               (<a class="link" href="pango-Modules.html#PangoMap" title="PangoMap">PangoMap</a> *map,
235                                                          <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript">PangoScript</a> script,
236                                                          <a
237 href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"
238 >GSList</a> **exact_engines,
239                                                          <a
240 href="http://library.gnome.org/devel/glib/unstable/glib-Singly-Linked-Lists.html#GSList"
241 >GSList</a> **fallback_engines);</pre>
242 <p>
243 Finds engines in the map that handle the given script. The returned
244 lists should be freed with g_slist_free, but the engines in the
245 lists are owned by GLib and will be kept around permanently, so
246 they should not be unref'ed.</p>
247 <p>
248 </p>
249 <div class="variablelist"><table border="0">
250 <col align="left" valign="top">
251 <tbody>
252 <tr>
253 <td><p><span class="term"><em class="parameter"><code>map</code></em> :</span></p></td>
254 <td> a <a class="link" href="pango-Modules.html#PangoMap" title="PangoMap"><span class="type">PangoMap</span></a>
255 </td>
256 </tr>
257 <tr>
258 <td><p><span class="term"><em class="parameter"><code>script</code></em> :</span></p></td>
259 <td> a <a class="link" href="pango-Scripts-and-Languages.html#PangoScript" title="enum PangoScript"><span class="type">PangoScript</span></a>
260 </td>
261 </tr>
262 <tr>
263 <td><p><span class="term"><em class="parameter"><code>exact_engines</code></em> :</span></p></td>
264 <td> location to store list of engines that exactly
265  handle this script.
266 </td>
267 </tr>
268 <tr>
269 <td><p><span class="term"><em class="parameter"><code>fallback_engines</code></em> :</span></p></td>
270 <td> location to store list of engines that approximately
271  handle this script.
272 </td>
273 </tr>
274 </tbody>
275 </table></div>
276 <p class="since">Since 1.4</p>
277 </div>
278 <hr>
279 <div class="refsect2" lang="en">
280 <a name="pango-module-register"></a><h3>pango_module_register ()</h3>
281 <pre class="programlisting">void                pango_module_register               (<a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule">PangoIncludedModule</a> *module);</pre>
282 <p>
283 Registers a statically linked module with Pango. The
284 <a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule"><span class="type">PangoIncludedModule</span></a> structure that is passed in contains the
285 functions that would otherwise be loaded from a dynamically loaded
286 module.</p>
287 <p>
288 </p>
289 <div class="variablelist"><table border="0">
290 <col align="left" valign="top">
291 <tbody><tr>
292 <td><p><span class="term"><em class="parameter"><code>module</code></em> :</span></p></td>
293 <td> a <a class="link" href="pango-Modules.html#PangoIncludedModule" title="PangoIncludedModule"><span class="type">PangoIncludedModule</span></a>
294 </td>
295 </tr></tbody>
296 </table></div>
297 </div>
298 </div>
299 </div>
300 <div class="footer">
301 <hr>
302           Generated by GTK-Doc V1.11</div>
303 </body>
304 </html>