⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pango-engines.html

📁 GTK+-2.0源码之pango-1.15.6.tar.gz
💻 HTML
字号:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"><title>Engines</title><meta name="generator" content="DocBook XSL Stylesheets V1.69.1"><link rel="start" href="index.html" title="Pango Reference Manual"><link rel="up" href="lowlevel.html" title="Low Level Functionality"><link rel="prev" href="pango-Coverage-Maps.html" title="Coverage Maps"><link rel="next" href="PangoEngineLang.html" title="PangoEngineLang"><meta name="generator" content="GTK-Doc V1.6 (XML mode)"><link rel="stylesheet" href="style.css" type="text/css"><link rel="chapter" href="pango.html" title="Basic Pango Interfaces"><link rel="chapter" href="rendering.html" title="Rendering with Pango"><link rel="chapter" href="lowlevel.html" title="Low Level Functionality"><link rel="chapter" href="tools.html" title="Pango Tools"><link rel="index" href="ix01.html" title="Index"><link rel="index" href="ix02.html" title="Index of deprecated symbols"><link rel="index" href="ix03.html" title="Index of new symbols in 1.2"><link rel="index" href="ix04.html" title="Index of new symbols in 1.4"><link rel="index" href="ix05.html" title="Index of new symbols in 1.6"><link rel="index" href="ix06.html" title="Index of new symbols in 1.8"><link rel="index" href="ix07.html" title="Index of new symbols in 1.10"><link rel="index" href="ix08.html" title="Index of new symbols in 1.12"><link rel="index" href="ix09.html" title="Index of new symbols in 1.14"><link rel="index" href="ix10.html" title="Index of new symbols in 1.16"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle"><td><a accesskey="p" href="pango-Coverage-Maps.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td><td><a accesskey="u" href="lowlevel.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td><td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td><th width="100%" align="center">Pango Reference Manual</th><td><a accesskey="n" href="PangoEngineLang.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td></tr><tr><td colspan="5" class="shortcuts"><nobr><a href="#top_of_page" class="shortcut">Top</a>                  &#160;|&#160;                  <a href="#desc" class="shortcut">Description</a>                  &#160;|&#160;                  <a href="#object_hierarchy" class="shortcut">Object Hierarchy</a></nobr></td></tr></table><div class="refentry" lang="en"><a name="pango-Engines"></a><div class="titlepage"></div><div class="refnamediv"><table width="100%"><tr><td valign="top"><h2><span class="refentrytitle"><a name="top_of_page"></a>Engines</span></h2><p>Engines &#8212; Language-specific and rendering-system-specific processing</p></td><td valign="top" align="right"></td></tr></table></div><div class="refsynopsisdiv"><a name="synopsis"></a><h2>Synopsis</h2><a name="PangoEngine"></a><pre class="synopsis">            <a href="pango-Engines.html#PangoEngineInfo">PangoEngineInfo</a>;            <a href="pango-Engines.html#PangoEngineScriptInfo">PangoEngineScriptInfo</a>;            <a href="pango-Engines.html#PangoEngine-struct">PangoEngine</a>;            <a href="pango-Engines.html#PangoEngineClass">PangoEngineClass</a>;#define     <a href="pango-Engines.html#PANGO-RENDER-TYPE-NONE:CAPS">PANGO_RENDER_TYPE_NONE</a>void        <a href="pango-Engines.html#script-engine-list">script_engine_list</a>              (<a href="pango-Engines.html#PangoEngineInfo">PangoEngineInfo</a> **engines,                                             int *n_engines);void        <a href="pango-Engines.html#script-engine-init">script_engine_init</a>              (<ahref="../gobject/GTypeModule.html">GTypeModule</a> *module);void        <a href="pango-Engines.html#script-engine-exit">script_engine_exit</a>              (void);<a href="pango-Engines.html#PangoEngine">PangoEngine</a>* <a href="pango-Engines.html#script-engine-create">script_engine_create</a>           (const char *id);</pre></div><div class="refsect1" lang="en"><a name="object_hierarchy"></a><h2>Object Hierarchy</h2><pre class="synopsis">  <ahref="../gobject/gobject-The-Base-Object-Type.html#GObject">GObject</a>   +----PangoEngine         +----<a href="PangoEngineLang.html" title="PangoEngineLang">PangoEngineLang</a>         +----<a href="PangoEngineShape.html" title="PangoEngineShape">PangoEngineShape</a></pre></div><div class="refsect1" lang="en"><a name="desc"></a><h2>Description</h2><p>Pango utilizes a module architecture in which the language-specificand render-system-specific components are provided by loadablemodules. Each loadable module supplies one or more<em class="firstterm">engines</em>.  Each <em class="firstterm">engine</em>has an associated <em class="firstterm">engine type</em> and<em class="firstterm">render type</em>. These two types are represented bystrings.</p><p>Each dynamically-loaded module exports several functions which providethe public API. These functions are <a href="pango-Engines.html#script-engine-list"><code class="function">script_engine_list()</code></a>,<a href="pango-Engines.html#script-engine-init"><code class="function">script_engine_init()</code></a> and script_engine_exit, and<a href="pango-Engines.html#script-engine-create"><code class="function">script_engine_create()</code></a>. The latter three functions are used whencreating engines from the module at run time, while the firstfunction is used when building a catalog of all available modules.</p></div><div class="refsect1" lang="en"><a name="details"></a><h2>Details</h2><div class="refsect2" lang="en"><a name="id2936131"></a><h3><a name="PangoEngineInfo"></a>PangoEngineInfo</h3><a class="indexterm" name="id2936142"></a><pre class="programlisting">typedef struct {  const gchar *id;  const gchar *engine_type;  const gchar *render_type;  PangoEngineScriptInfo *scripts;  gint n_scripts;} PangoEngineInfo;</pre><p>The <a href="pango-Engines.html#PangoEngineInfo"><span class="type">PangoEngineInfo</span></a> structure contains information about a particularengine. It contains the following fields:</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term">const&#160;<ahref="../glib/glib-Basic-Types.html#gchar">gchar</a>&#160;*<em class="structfield"><code>id</code></em>;</span></td><td>a unique string ID for the engine.</td></tr><tr><td><span class="term">const&#160;<ahref="../glib/glib-Basic-Types.html#gchar">gchar</a>&#160;*<em class="structfield"><code>engine_type</code></em>;</span></td><td>a string identifying the engine type.</td></tr><tr><td><span class="term">const&#160;<ahref="../glib/glib-Basic-Types.html#gchar">gchar</a>&#160;*<em class="structfield"><code>render_type</code></em>;</span></td><td>a string identifying the render type.</td></tr><tr><td><span class="term"><a href="pango-Engines.html#PangoEngineScriptInfo">PangoEngineScriptInfo</a>&#160;*<em class="structfield"><code>scripts</code></em>;</span></td><td>array of scripts this engine supports.</td></tr><tr><td><span class="term"><ahref="../glib/glib-Basic-Types.html#gint">gint</a>&#160;<em class="structfield"><code>n_scripts</code></em>;</span></td><td>number of items in <em class="parameter"><code>scripts</code></em>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2936288"></a><h3><a name="PangoEngineScriptInfo"></a>PangoEngineScriptInfo</h3><a class="indexterm" name="id2936302"></a><pre class="programlisting">typedef struct {  PangoScript script;  const gchar *langs;} PangoEngineScriptInfo;</pre><p>The <a href="pango-Engines.html#PangoEngineScriptInfo"><span class="type">PangoEngineScriptInfo</span></a> structure containsinformation about how the shaper covers a particularscript.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><a href="pango-Scripts.html#PangoScript">PangoScript</a>&#160;<em class="structfield"><code>script</code></em>;</span></td><td>a <a href="pango-Scripts.html#PangoScript"><span class="type">PangoScript</span></a>. The value <a href="pango-Scripts.html#PANGO-SCRIPT-COMMON:CAPS"><code class="literal">PANGO_SCRIPT_COMMON</code></a> has        the special meaning here of "all scripts"</td></tr><tr><td><span class="term">const&#160;<ahref="../glib/glib-Basic-Types.html#gchar">gchar</a>&#160;*<em class="structfield"><code>langs</code></em>;</span></td><td>a semicolon separated list of languages that this        engine handles for this script. This may be empty,         in which case the engine is saying that it is a        fallback choice for all languages for this range,        but should not be used if another engine         indicates that it is specific for the language for        a given code point. An entry in this list of "*"        indicates that this engine is specific to all        languages for this range.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2936404"></a><h3><a name="PangoEngine-struct"></a>PangoEngine</h3><a class="indexterm" name="id2936416"></a><pre class="programlisting">typedef struct _PangoEngine PangoEngine;</pre><p><a href="pango-Engines.html#PangoEngine"><span class="type">PangoEngine</span></a> is the base class for all types of language andscript specific engines. It has no functionality by itself.</p><p></p></div><hr><div class="refsect2" lang="en"><a name="id2936444"></a><h3><a name="PangoEngineClass"></a>PangoEngineClass</h3><a class="indexterm" name="id2936457"></a><pre class="programlisting">typedef struct {} PangoEngineClass;</pre><p>Class structure for <a href="pango-Engines.html#PangoEngine"><span class="type">PangoEngine</span></a></p><p></p></div><hr><div class="refsect2" lang="en"><a name="id2936483"></a><h3><a name="PANGO-RENDER-TYPE-NONE:CAPS"></a>PANGO_RENDER_TYPE_NONE</h3><a class="indexterm" name="id2936496"></a><pre class="programlisting">#define PANGO_RENDER_TYPE_NONE "PangoRenderNone"</pre><p>A string constant defining the render typefor engines that are not rendering-system specific.</p></div><hr><div class="refsect2" lang="en"><a name="id2936514"></a><h3><a name="script-engine-list"></a>script_engine_list ()</h3><a class="indexterm" name="id2936527"></a><pre class="programlisting">void        script_engine_list              (<a href="pango-Engines.html#PangoEngineInfo">PangoEngineInfo</a> **engines,                                             int *n_engines);</pre><p>Function to be provided by a module to list the engines that themodule supplies. The function stores a pointer to an arrayof <a href="pango-Engines.html#PangoEngineInfo"><span class="type">PangoEngineInfo</span></a> structures and the length of that array inthe given location.</p><p>Note that <a href="pango-Engines.html#script-engine-init"><code class="function">script_engine_init()</code></a> will not be called before thisfunction.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>engines</code></em>&#160;:</span></td><td> location to store a pointer to an array of engines.</td></tr><tr><td><span class="term"><em class="parameter"><code>n_engines</code></em>&#160;:</span></td><td> location to store the number of elements in <em class="parameter"><code>engines</code></em>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2936632"></a><h3><a name="script-engine-init"></a>script_engine_init ()</h3><a class="indexterm" name="id2936645"></a><pre class="programlisting">void        script_engine_init              (<ahref="../gobject/GTypeModule.html">GTypeModule</a> *module);</pre><p>Function to be provided by a module to register anyGObject types in the module.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>module</code></em>&#160;:</span></td><td> a <ahref="../gobject/GTypeModule.html"><span class="type">GTypeModule</span></a> structure used to associate any GObject types created in this module with the module.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2936704"></a><h3><a name="script-engine-exit"></a>script_engine_exit ()</h3><a class="indexterm" name="id2936718"></a><pre class="programlisting">void        script_engine_exit              (void);</pre><p>Function to be provided by the module that is calledwhen the module is unloading. Frequently does nothing.</p><p></p></div><hr><div class="refsect2" lang="en"><a name="id2936744"></a><h3><a name="script-engine-create"></a>script_engine_create ()</h3><a class="indexterm" name="id2936757"></a><pre class="programlisting"><a href="pango-Engines.html#PangoEngine">PangoEngine</a>* script_engine_create           (const char *id);</pre><p>Function to be provided by the module to create an instanceof one of the engines implemented by the module.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>id</code></em>&#160;:</span></td><td> the ID of an engine as reported by script_engine_list.</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td><td> a newly created <a href="pango-Engines.html#PangoEngine"><span class="type">PangoEngine</span></a> of the specified type, or <ahref="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> if an error occurred. (In normal operation, a module should not return <ahref="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a>. A <ahref="../glib/glib-Standard-Macros.html#NULL:CAPS"><code class="literal">NULL</code></a> return is only acceptable in the case where system misconfiguration or bugs in the driver routine are encountered.)</td></tr></tbody></table></div></div></div></div></body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -