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

📄 text-attributes.xml

📁 linux
💻 XML
📖 第 1 页 / 共 5 页
字号:
                                                         <link linkend="GError">GError</link> **error);</programlisting><para>Parses marked-up text (see<link linkend="PangoMarkupFormat">markup format</link>) to createa plain-text string and an attribute list.</para><para>If <parameter>accel_marker</parameter> is nonzero, the given character will mark thecharacter following it as an accelerator. For example, <parameter>accel_marker</parameter>might be an ampersand or underscore. All characters markedas an accelerator will receive a <link linkend="PANGO-UNDERLINE-LOW:CAPS"><literal>PANGO_UNDERLINE_LOW</literal></link> attribute,and the first character so marked will be returned in <parameter>accel_char</parameter>.Two <parameter>accel_marker</parameter> characters following each other produce a singleliteral <parameter>accel_marker</parameter> character.</para><para>If any error happens, none of the output arguments are touched exceptfor <parameter>error</parameter>.</para><para></para><variablelist role="params"><varlistentry><term><parameter>markup_text</parameter>&nbsp;:</term><listitem><simpara> markup to parse (see <link linkend="PangoMarkupFormat">markup format</link>)</simpara></listitem></varlistentry><varlistentry><term><parameter>length</parameter>&nbsp;:</term><listitem><simpara> length of <parameter>markup_text</parameter>, or -1 if nul-terminated</simpara></listitem></varlistentry><varlistentry><term><parameter>accel_marker</parameter>&nbsp;:</term><listitem><simpara> character that precedes an accelerator, or 0 for none</simpara></listitem></varlistentry><varlistentry><term><parameter>attr_list</parameter>&nbsp;:</term><listitem><simpara> address of return location for a <link linkend="PangoAttrList"><type>PangoAttrList</type></link>, or <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry><varlistentry><term><parameter>text</parameter>&nbsp;:</term><listitem><simpara> address of return location for text with tags stripped, or <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry><varlistentry><term><parameter>accel_char</parameter>&nbsp;:</term><listitem><simpara> address of return location for accelerator char, or <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry><varlistentry><term><parameter>error</parameter>&nbsp;:</term><listitem><simpara> address of return location for errors, or <link linkend="NULL:CAPS"><literal>NULL</literal></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> <link linkend="FALSE:CAPS"><literal>FALSE</literal></link> if <parameter>error</parameter> is set, otherwise <link linkend="TRUE:CAPS"><literal>TRUE</literal></link></simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-type-register" role="function"/>pango_attr_type_register ()</title><indexterm><primary>pango_attr_type_register</primary></indexterm><programlisting><link linkend="PangoAttrType">PangoAttrType</link>       pango_attr_type_register            (const <link linkend="gchar">gchar</link> *name);</programlisting><para>Allocate a new attribute type ID.</para><para></para><variablelist role="params"><varlistentry><term><parameter>name</parameter>&nbsp;:</term><listitem><simpara> an identifier for the type (currently unused.)</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the new type ID.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attribute-copy" role="function"/>pango_attribute_copy ()</title><indexterm><primary>pango_attribute_copy</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attribute_copy                (const <link linkend="PangoAttribute">PangoAttribute</link> *attr);</programlisting><para>Make a copy of an attribute.</para><para></para><variablelist role="params"><varlistentry><term><parameter>attr</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoAttribute"><type>PangoAttribute</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attribute-equal" role="function"/>pango_attribute_equal ()</title><indexterm><primary>pango_attribute_equal</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_attribute_equal               (const <link linkend="PangoAttribute">PangoAttribute</link> *attr1,                                                         const <link linkend="PangoAttribute">PangoAttribute</link> *attr2);</programlisting><para>Compare two attributes for equality. This compares only theactual value of the two attributes and not the ranges that theattributes apply to.</para><para></para><variablelist role="params"><varlistentry><term><parameter>attr1</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoAttribute"><type>PangoAttribute</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>attr2</parameter>&nbsp;:</term><listitem><simpara> another <link linkend="PangoAttribute"><type>PangoAttribute</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if the two attributes have the same value.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attribute-destroy" role="function"/>pango_attribute_destroy ()</title><indexterm><primary>pango_attribute_destroy</primary></indexterm><programlisting><link linkend="void">void</link>                pango_attribute_destroy             (<link linkend="PangoAttribute">PangoAttribute</link> *attr);</programlisting><para>Destroy a <link linkend="PangoAttribute"><type>PangoAttribute</type></link> and free all associated memory.</para><para></para><variablelist role="params"><varlistentry><term><parameter>attr</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoAttribute"><type>PangoAttribute</type></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-language-new" role="function"/>pango_attr_language_new ()</title><indexterm><primary>pango_attr_language_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_language_new             (<link linkend="PangoLanguage">PangoLanguage</link> *language);</programlisting><para>Create a new language tag attribute.</para><para></para><variablelist role="params"><varlistentry><term><parameter>language</parameter>&nbsp;:</term><listitem><simpara> language tag</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-family-new" role="function"/>pango_attr_family_new ()</title><indexterm><primary>pango_attr_family_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_family_new               (const <link linkend="char">char</link> *family);</programlisting><para>Create a new font family attribute.</para><para></para><variablelist role="params"><varlistentry><term><parameter>family</parameter>&nbsp;:</term><listitem><simpara> the family or comma separated list of families</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-style-new" role="function"/>pango_attr_style_new ()</title><indexterm><primary>pango_attr_style_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_style_new                (<link linkend="PangoStyle">PangoStyle</link> style);</programlisting><para>Create a new font slant style attribute.</para><para></para><variablelist role="params"><varlistentry><term><parameter>style</parameter>&nbsp;:</term><listitem><simpara> the slant style</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-variant-new" role="function"/>pango_attr_variant_new ()</title><indexterm><primary>pango_attr_variant_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_variant_new              (<link linkend="PangoVariant">PangoVariant</link> variant);</programlisting><para>Create a new font variant attribute (normal or small caps)</para><para></para><variablelist role="params"><varlistentry><term><parameter>variant</parameter>&nbsp;:</term><listitem><simpara> the variant</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-stretch-new" role="function"/>pango_attr_stretch_new ()</title><indexterm><primary>pango_attr_stretch_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_stretch_new              (<link linkend="PangoStretch">PangoStretch</link> stretch);</programlisting><para>Create a new font stretch attribute</para><para></para><variablelist role="params"><varlistentry><term><parameter>stretch</parameter>&nbsp;:</term><listitem><simpara> the stretch</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-weight-new" role="function"/>pango_attr_weight_new ()</title><indexterm><primary>pango_attr_weight_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_weight_new               (<link linkend="PangoWeight">PangoWeight</link> weight);</programlisting><para>Create a new font weight attribute.</para><para></para><variablelist role="params"><varlistentry><term><parameter>weight</parameter>&nbsp;:</term><listitem><simpara> the weight</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be              freed with <link linkend="pango-attribute-destroy"><function>pango_attribute_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2><title><anchor id="pango-attr-size-new" role="function"/>pango_attr_size_new ()</title><indexterm><primary>pango_attr_size_new</primary></indexterm><programlisting><link linkend="PangoAttribute">PangoAttribute</link>*     pango_attr_size_new                 (<link linkend="int">int</link> size);</programlisting><para>Create a new font-size attribute in fractional points.</para><para></para><variablelist role="params"><varlistentry><term><parameter>size</parameter>&nbsp;:</term><listitem><simpara> the font size, in <link linkend="PANGO-SCALE:CAPS"><literal>PANGO_SCALE</literal></link><!-- -->ths of a point.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the newly allocated <link linkend="PangoAttribute"><type>PangoAttribute</type></link>, which should be

⌨️ 快捷键说明

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