📄 opentype.xml
字号:
</simpara></listitem></varlistentry><varlistentry><term><parameter>required_feature_index</parameter> :</term><listitem><simpara> location to store the required feature index of the language, or <link linkend="NULL:CAPS"><literal>NULL</literal></link>.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if the language was found.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-ot-info-find-feature" role="function"><title>pango_ot_info_find_feature ()</title><indexterm zone="pango-ot-info-find-feature"><primary>pango_ot_info_find_feature</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link> pango_ot_info_find_feature (<link linkend="PangoOTInfo">PangoOTInfo</link> *info, <link linkend="PangoOTTableType">PangoOTTableType</link> table_type, <link linkend="PangoOTTag">PangoOTTag</link> feature_tag, <link linkend="guint">guint</link> script_index, <link linkend="guint">guint</link> language_index, <link linkend="guint">guint</link> *feature_index);</programlisting><para>Finds the index of a feature. If the feature is not found, sets<parameter>feature_index</parameter> to PANGO_OT_NO_FEATURE, which is safe to pass to<link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> and similar functions.</para><para>In the future, this may set <parameter>feature_index</parameter> to an special value that if usedin <link linkend="pango-ot-ruleset-add-feature"><function>pango_ot_ruleset_add_feature()</function></link> will ask Pango to synthesize therequested feature based on Unicode properties and data. However, thisfunction will still return <link linkend="FALSE:CAPS"><literal>FALSE</literal></link> in those cases. So, users may want toignore the return value of this function in certain cases.</para><para></para><variablelist role="params"><varlistentry><term><parameter>info</parameter> :</term><listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>table_type</parameter> :</term><listitem><simpara> the table type to obtain information about.</simpara></listitem></varlistentry><varlistentry><term><parameter>feature_tag</parameter> :</term><listitem><simpara> the tag of the feature to find.</simpara></listitem></varlistentry><varlistentry><term><parameter>script_index</parameter> :</term><listitem><simpara> the index of the script.</simpara></listitem></varlistentry><varlistentry><term><parameter>language_index</parameter> :</term><listitem><simpara> the index of the language whose features are searched, or <link linkend="PANGO-OT-DEFAULT-LANGUAGE:CAPS"><literal>PANGO_OT_DEFAULT_LANGUAGE</literal></link> to use the default language of the script.</simpara></listitem></varlistentry><varlistentry><term><parameter>feature_index</parameter> :</term><listitem><simpara> location to store the index of the feature, or <link linkend="NULL:CAPS"><literal>NULL</literal></link>.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if the feature was found.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-ot-info-list-scripts" role="function"><title>pango_ot_info_list_scripts ()</title><indexterm zone="pango-ot-info-list-scripts"><primary>pango_ot_info_list_scripts</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link>* pango_ot_info_list_scripts (<link linkend="PangoOTInfo">PangoOTInfo</link> *info, <link linkend="PangoOTTableType">PangoOTTableType</link> table_type);</programlisting><para>Obtains the list of available scripts.</para><para></para><variablelist role="params"><varlistentry><term><parameter>info</parameter> :</term><listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>table_type</parameter> :</term><listitem><simpara> the table type to obtain information about.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of the available scripts. Should be freed using <link linkend="g-free"><function>g_free()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-ot-info-list-languages" role="function"><title>pango_ot_info_list_languages ()</title><indexterm zone="pango-ot-info-list-languages"><primary>pango_ot_info_list_languages</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link>* pango_ot_info_list_languages (<link linkend="PangoOTInfo">PangoOTInfo</link> *info, <link linkend="PangoOTTableType">PangoOTTableType</link> table_type, <link linkend="guint">guint</link> script_index, <link linkend="PangoOTTag">PangoOTTag</link> language_tag);</programlisting><para>Obtains the list of available languages for a given script.</para><para></para><variablelist role="params"><varlistentry><term><parameter>info</parameter> :</term><listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>table_type</parameter> :</term><listitem><simpara> the table type to obtain information about.</simpara></listitem></varlistentry><varlistentry><term><parameter>script_index</parameter> :</term><listitem><simpara> the index of the script to list languages for.</simpara></listitem></varlistentry><varlistentry><term><parameter>language_tag</parameter> :</term><listitem><simpara> unused parameter.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of the available languages. Should be freed using <link linkend="g-free"><function>g_free()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-ot-info-list-features" role="function"><title>pango_ot_info_list_features ()</title><indexterm zone="pango-ot-info-list-features"><primary>pango_ot_info_list_features</primary></indexterm><programlisting><link linkend="PangoOTTag">PangoOTTag</link>* pango_ot_info_list_features (<link linkend="PangoOTInfo">PangoOTInfo</link> *info, <link linkend="PangoOTTableType">PangoOTTableType</link> table_type, <link linkend="PangoOTTag">PangoOTTag</link> tag, <link linkend="guint">guint</link> script_index, <link linkend="guint">guint</link> language_index);</programlisting><para>Obtains the list of features for the given language of the given script.</para><para></para><variablelist role="params"><varlistentry><term><parameter>info</parameter> :</term><listitem><simpara> a <link linkend="PangoOTInfo"><type>PangoOTInfo</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>table_type</parameter> :</term><listitem><simpara> the table type to obtain information about.</simpara></listitem></varlistentry><varlistentry><term><parameter>tag</parameter> :</term><listitem><simpara> unused parameter.</simpara></listitem></varlistentry><varlistentry><term><parameter>script_index</parameter> :</term><listitem><simpara> the index of the script to obtain information about.</simpara></listitem></varlistentry><varlistentry><term><parameter>language_index</parameter> :</term><listitem><simpara> the index of the language to list features for, or <link linkend="PANGO-OT-DEFAULT-LANGUAGE:CAPS"><literal>PANGO_OT_DEFAULT_LANGUAGE</literal></link>, to list features for the default language of the script.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> a newly-allocated zero-terminated array containing the tags of theavailable features. Should be freed using <link linkend="g-free"><function>g_free()</function></link>.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-ot-buffer-new" role="function" condition="since:1.4"><title>pango_ot_buffer_new ()</title><indexterm zone="pango-ot-buffer-new" role="1.4"><primary>pango_ot_buffer_new</primary></indexterm><programlisting><link linkend="PangoOTBuffer">PangoOTBuffer</link>* pango_ot_buffer_new (<link linkend="PangoFcFont">PangoFcFont</link> *font);</programlisting><para>Creates a new <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> for the given OpenType font.</para><para></para><variablelist role="params"><varlistentry><term><parameter>font</parameter> :</term><listitem><simpara> a <link linkend="PangoFcFont"><type>PangoFcFont</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis> :</term><listitem><simpara> the newly allocated <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, which should be freed with <link linkend="pango-ot-buffer-destroy"><function>pango_ot_buffer_destroy()</function></link>.</simpara></listitem></varlistentry></variablelist><para role="since">Since 1.4</para></refsect2><refsect2 id="pango-ot-buffer-destroy" role="function" condition="since:1.4"><title>pango_ot_buffer_destroy ()</title><indexterm zone="pango-ot-buffer-destroy" role="1.4"><primary>pango_ot_buffer_destroy</primary></indexterm><programlisting><link linkend="void">void</link> pango_ot_buffer_destroy (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting><para>Destroys a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link> and free all associated memory.</para><para></para><variablelist role="params"><varlistentry><term><parameter>buffer</parameter> :</term><listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link></simpara></listitem></varlistentry></variablelist><para role="since">Since 1.4</para></refsect2><refsect2 id="pango-ot-buffer-clear" role="function" condition="since:1.4"><title>pango_ot_buffer_clear ()</title><indexterm zone="pango-ot-buffer-clear" role="1.4"><primary>pango_ot_buffer_clear</primary></indexterm><programlisting><link linkend="void">void</link> pango_ot_buffer_clear (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer);</programlisting><para>Empties a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, make it ready to add glyphs to.</para><para></para><variablelist role="params"><varlistentry><term><parameter>buffer</parameter> :</term><listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link></simpara></listitem></varlistentry></variablelist><para role="since">Since 1.4</para></refsect2><refsect2 id="pango-ot-buffer-add-glyph" role="function" condition="since:1.4"><title>pango_ot_buffer_add_glyph ()</title><indexterm zone="pango-ot-buffer-add-glyph" role="1.4"><primary>pango_ot_buffer_add_glyph</primary></indexterm><programlisting><link linkend="void">void</link> pango_ot_buffer_add_glyph (<link linkend="PangoOTBuffer">PangoOTBuffer</link> *buffer, <link linkend="guint">guint</link> glyph, <link linkend="guint">guint</link> properties, <link linkend="guint">guint</link> cluster);</programlisting><para>Appends a glyph to a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link>, with <parameter>properties</parameter> identifying whichfeatures should be applied on this glyph. See <link linkend="pango-ruleset-add-feature"><function>pango_ruleset_add_feature()</function></link>.</para><para></para><variablelist role="params"><varlistentry><term><parameter>buffer</parameter> :</term><listitem><simpara> a <link linkend="PangoOTBuffer"><type>PangoOTBuffer</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>glyph</parameter> :</term><listitem><simpara> the glyph index to add, like a <link linkend="PangoGlyph"><type>PangoGlyph</type></link>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -