📄 glyphs.xml
字号:
</para></refsect2><refsect2 id="PangoGlyphVisAttr" role="struct"><title>PangoGlyphVisAttr</title><indexterm zone="PangoGlyphVisAttr"><primary>PangoGlyphVisAttr</primary></indexterm><programlisting>typedef struct { guint is_cluster_start : 1;} PangoGlyphVisAttr;</programlisting><para>The PangoGlyphVisAttr is used to communicate information betweenthe shaping phase and the rendering phase. More attributes may beadded in the future.</para><variablelist role="struct"><varlistentry><term><link linkend="guint">guint</link> <structfield>is_cluster_start</structfield> : 1;</term><listitem><simpara>set for the first logical glyph in each cluster. (Clusters are stored in visual order, within the cluster, glyphs are always ordered in logical order, since visual order is meaningless; that is, in Arabic text, accent glyphs follow the glyphs for the base character.)</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="PangoGlyphString" role="struct"><title>PangoGlyphString</title><indexterm zone="PangoGlyphString"><primary>PangoGlyphString</primary></indexterm><programlisting>typedef struct { gint num_glyphs; PangoGlyphInfo *glyphs; /* This is a memory inefficient way of representing the information * here - each value gives the byte index within the text * corresponding to the glyph string of the start of the cluster to * which the glyph belongs. */ gint *log_clusters;} PangoGlyphString;</programlisting><para>The <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link> structure is used to store stringsof glyphs with geometry and visual attribute information.The storage for the glyph information is ownedby the structure which simplifies memory management.</para><variablelist role="struct"><varlistentry><term><link linkend="gint">gint</link> <structfield>num_glyphs</structfield>;</term><listitem><simpara>the number of glyphs in the string.</simpara></listitem></varlistentry><varlistentry><term><link linkend="PangoGlyphInfo">PangoGlyphInfo</link> *<structfield>glyphs</structfield>;</term><listitem><simpara>an array of <link linkend="PangoGlyphInfo"><type>PangoGlyphInfo</type></link> structures of length <structfield>num_glyphs</structfield>.</simpara></listitem></varlistentry><varlistentry><term><link linkend="gint">gint</link> *<structfield>log_clusters</structfield>;</term><listitem><simpara>for each glyph, byte index of the starting character for thecluster. The indices are relative to the start of the textcorresponding to the PangoGlyphString.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="PangoGlyphItem" role="struct"><title>PangoGlyphItem</title><indexterm zone="PangoGlyphItem"><primary>PangoGlyphItem</primary></indexterm><programlisting>typedef struct { PangoItem *item; PangoGlyphString *glyphs;} PangoGlyphItem;</programlisting><para>A <link linkend="PangoGlyphItem"><type>PangoGlyphItem</type></link> is a pair of a <link linkend="PangoItem"><type>PangoItem</type></link> and the glyphsresulting from shaping the text corresponding to an item.As an example of the usage of <link linkend="PangoGlyphItem"><type>PangoGlyphItem</type></link>, the resultsof shaping text with <link linkend="PangoLayout"><type>PangoLayout</type></link> is a list of <link linkend="PangoLayoutLine"><type>PangoLayoutLine</type></link>,each of which contains a list of <link linkend="PangoGlyphItem"><type>PangoGlyphItem</type></link>.</para><variablelist role="struct"><varlistentry><term><link linkend="PangoItem">PangoItem</link> *<structfield>item</structfield>;</term><listitem><simpara>a <link linkend="PangoItem"><type>PangoItem</type></link> structure that provides information about a segment of text.</simpara></listitem></varlistentry><varlistentry><term><link linkend="PangoGlyphString">PangoGlyphString</link> *<structfield>glyphs</structfield>;</term><listitem><simpara>the glyphs obtained by shaping the text corresponding to <parameter>item</parameter>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="PANGO-TYPE-GLYPH-STRING:CAPS" role="macro"><title>PANGO_TYPE_GLYPH_STRING</title><indexterm zone="PANGO-TYPE-GLYPH-STRING:CAPS"><primary>PANGO_TYPE_GLYPH_STRING</primary></indexterm><programlisting>#define PANGO_TYPE_GLYPH_STRING (pango_glyph_string_get_type ())</programlisting><para>The <link linkend="GObject"><type>GObject</type></link> type for <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>.</para></refsect2><refsect2 id="pango-glyph-string-new" role="function"><title>pango_glyph_string_new ()</title><indexterm zone="pango-glyph-string-new"><primary>pango_glyph_string_new</primary></indexterm><programlisting><link linkend="PangoGlyphString">PangoGlyphString</link>* pango_glyph_string_new (void);</programlisting><para>Create a new <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>.</para><para></para><variablelist role="params"><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the newly allocated <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>, which should be freed with <link linkend="pango-glyph-string-free"><function>pango_glyph_string_free()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-glyph-string-copy" role="function"><title>pango_glyph_string_copy ()</title><indexterm zone="pango-glyph-string-copy"><primary>pango_glyph_string_copy</primary></indexterm><programlisting><link linkend="PangoGlyphString">PangoGlyphString</link>* pango_glyph_string_copy (<link linkend="PangoGlyphString">PangoGlyphString</link> *string);</programlisting><para>Copy a glyph string and associated storage.</para><para></para><variablelist role="params"><varlistentry><term><parameter>string</parameter> :</term><listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>, may be <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the newly allocated <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>, which should be freed with <link linkend="pango-glyph-string-free"><function>pango_glyph_string_free()</function></link>, or <link linkend="NULL:CAPS"><literal>NULL</literal></link> if <parameter>string</parameter> was <link linkend="NULL:CAPS"><literal>NULL</literal></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-glyph-string-set-size" role="function"><title>pango_glyph_string_set_size ()</title><indexterm zone="pango-glyph-string-set-size"><primary>pango_glyph_string_set_size</primary></indexterm><programlisting><link linkend="void">void</link> pango_glyph_string_set_size (<link linkend="PangoGlyphString">PangoGlyphString</link> *string, <link linkend="gint">gint</link> new_len);</programlisting><para>Resize a glyph string to the given length.</para><para></para><variablelist role="params"><varlistentry><term><parameter>string</parameter> :</term><listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>new_len</parameter> :</term><listitem><simpara> the new length of the string.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-glyph-string-free" role="function"><title>pango_glyph_string_free ()</title><indexterm zone="pango-glyph-string-free"><primary>pango_glyph_string_free</primary></indexterm><programlisting><link linkend="void">void</link> pango_glyph_string_free (<link linkend="PangoGlyphString">PangoGlyphString</link> *string);</programlisting><para>Free a glyph string and associated storage.</para><para></para><variablelist role="params"><varlistentry><term><parameter>string</parameter> :</term><listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link>, may be <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-glyph-string-extents" role="function"><title>pango_glyph_string_extents ()</title><indexterm zone="pango-glyph-string-extents"><primary>pango_glyph_string_extents</primary></indexterm><programlisting><link linkend="void">void</link> pango_glyph_string_extents (<link linkend="PangoGlyphString">PangoGlyphString</link> *glyphs, <link linkend="PangoFont">PangoFont</link> *font, <link linkend="PangoRectangle">PangoRectangle</link> *ink_rect, <link linkend="PangoRectangle">PangoRectangle</link> *logical_rect);</programlisting><para>Compute the logical and ink extents of a glyph string. See the documentationfor <link linkend="pango-font-get-glyph-extents"><function>pango_font_get_glyph_extents()</function></link> for details about the interpretationof the rectangles.</para><para></para><variablelist role="params"><varlistentry><term><parameter>glyphs</parameter> :</term><listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>font</parameter> :</term><listitem><simpara> a <link linkend="PangoFont"><type>PangoFont</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>ink_rect</parameter> :</term><listitem><simpara> rectangle used to store the extents of the glyph string as drawn or <link linkend="NULL:CAPS"><literal>NULL</literal></link> to indicate that the result is not needed.</simpara></listitem></varlistentry><varlistentry><term><parameter>logical_rect</parameter> :</term><listitem><simpara> rectangle used to store the logical extents of the glyph string or <link linkend="NULL:CAPS"><literal>NULL</literal></link> to indicate that the result is not needed.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-glyph-string-extents-range" role="function"><title>pango_glyph_string_extents_range ()</title><indexterm zone="pango-glyph-string-extents-range"><primary>pango_glyph_string_extents_range</primary></indexterm><programlisting><link linkend="void">void</link> pango_glyph_string_extents_range (<link linkend="PangoGlyphString">PangoGlyphString</link> *glyphs, <link linkend="int">int</link> start, <link linkend="int">int</link> end, <link linkend="PangoFont">PangoFont</link> *font, <link linkend="PangoRectangle">PangoRectangle</link> *ink_rect, <link linkend="PangoRectangle">PangoRectangle</link> *logical_rect);</programlisting><para>Computes the extents of a sub-portion of a glyph string. The extents arerelative to the start of the glyph string range (the origin of theircoordinate system is at the start of the range, not at the start of the entireglyph string).</para><para></para><variablelist role="params"><varlistentry><term><parameter>glyphs</parameter> :</term><listitem><simpara> a <link linkend="PangoGlyphString"><type>PangoGlyphString</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>start</parameter> :</term><listitem><simpara> start index</simpara></listitem></varlistentry><varlistentry><term><parameter>end</parameter> :</term><listitem><simpara> end index (the range is the set of bytes with indices such that start <= index < end)</simpara></listitem></varlistentry><varlistentry><term><parameter>font</parameter> :</term><listitem><simpara> a <link linkend="PangoFont"><type>PangoFont</type></link></simpara></lis
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -