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

📄 pangofc-decoder.xml

📁 Pango is a library for layout and rendering of text, with an emphasis on internationalization. Pang
💻 XML
字号:
<refentry id="PangoFcDecoder"><refmeta><refentrytitle role="top_of_page" id="PangoFcDecoder.top_of_page">PangoFcDecoder</refentrytitle><manvolnum>3</manvolnum><refmiscinfo>PANGO Library</refmiscinfo></refmeta><refnamediv><refname>PangoFcDecoder</refname><refpurpose>Custom font encoding handling</refpurpose><!--[<xref linkend="desc" endterm="desc.title"/>]--></refnamediv><refsynopsisdiv id="PangoFcDecoder.synopsis" role="synopsis"><title role="synopsis.title">Synopsis</title><synopsis>                    <link linkend="PangoFcDecoder-struct">PangoFcDecoder</link>;                    <link linkend="PangoFcDecoderClass">PangoFcDecoderClass</link>;<link linkend="FcCharSet">FcCharSet</link>*          <link linkend="pango-fc-decoder-get-charset">pango_fc_decoder_get_charset</link>        (<link linkend="PangoFcDecoder">PangoFcDecoder</link> *decoder,                                                         <link linkend="PangoFcFont">PangoFcFont</link> *fcfont);<link linkend="PangoGlyph">PangoGlyph</link>          <link linkend="pango-fc-decoder-get-glyph">pango_fc_decoder_get_glyph</link>          (<link linkend="PangoFcDecoder">PangoFcDecoder</link> *decoder,                                                         <link linkend="PangoFcFont">PangoFcFont</link> *fcfont,                                                         <link linkend="guint32">guint32</link> wc);</synopsis></refsynopsisdiv><refsect1 id="PangoFcDecoder.object-hierarchy" role="object_hierarchy"><title role="object_hierarchy.title">Object Hierarchy</title><synopsis>  <link linkend="GObject">GObject</link>   +----PangoFcDecoder</synopsis></refsect1><refsect1 id="PangoFcDecoder.description" role="desc"><title role="desc.title">Description</title><para>PangoFcDecoder represents a decoder that an application providesfor handling a font that is encoded in a custom way.</para></refsect1><refsect1 id="PangoFcDecoder.details" role="details"><title role="details.title">Details</title><refsect2 id="PangoFcDecoder-struct" role="struct"><title>PangoFcDecoder</title><indexterm zone="PangoFcDecoder-struct" role="1.6"><primary>PangoFcDecoder</primary></indexterm><programlisting>typedef struct _PangoFcDecoder PangoFcDecoder;</programlisting><para><link linkend="PangoFcDecoder"><type>PangoFcDecoder</type></link> is a virtual base class that implementations willinherit from.  It's the interface that is used to define a customencoding for a font.  These objects are created in your code from afunction callback that was originally registered with<link linkend="pango-fc-font-map-add-decoder-find-func"><function>pango_fc_font_map_add_decoder_find_func()</function></link>.  Pango requiresinformation about the supported charset for a font as well as theindividual character to glyph conversions.  Pango gets thatinformation via the <link linkend="get-charset"><type>get_charset</type></link> and <link linkend="get-glyph"><type>get_glyph</type></link> callbacks into yourobject implementation.</para><para></para><para role="since">Since  1.6</para></refsect2><refsect2 id="PangoFcDecoderClass" role="struct" condition="since:1.6"><title>PangoFcDecoderClass</title><indexterm zone="PangoFcDecoderClass" role="1.6"><primary>PangoFcDecoderClass</primary></indexterm><programlisting>typedef struct {  FcCharSet  *(*get_charset) (PangoFcDecoder *decoder,			      PangoFcFont    *fcfont);  PangoGlyph  (*get_glyph)   (PangoFcDecoder *decoder,			      PangoFcFont    *fcfont,			      guint32         wc);} PangoFcDecoderClass;</programlisting><para>Class structure for <link linkend="PangoFcDecoder"><type>PangoFcDecoder</type></link>.</para><para></para><variablelist role="struct"><varlistentry><term><structfield>get_charset</structfield>&nbsp;()</term><listitem><simpara> This returns an <link linkend="FcCharset"><type>FcCharset</type></link> given a <link linkend="PangoFcFont"><type>PangoFcFont</type></link> that includes a list of supported characters in the font.  The <link linkend="FcCharSet"><type>FcCharSet</type></link> that is returned should be an internal reference to your code.  Pango will not free this structure.  It is important that you make this callback fast because this callback is called separately for each character to determine Unicode coverage.</simpara></listitem></varlistentry><varlistentry><term><structfield>get_glyph</structfield>&nbsp;()</term><listitem><simpara> This returns a single <link linkend="PangoGlyph"><type>PangoGlyph</type></link> for a given Unicode code point.</simpara></listitem></varlistentry></variablelist><para role="since">Since  1.6</para></refsect2><refsect2 id="pango-fc-decoder-get-charset" role="function" condition="since:1.6"><title>pango_fc_decoder_get_charset ()</title><indexterm zone="pango-fc-decoder-get-charset" role="1.6"><primary>pango_fc_decoder_get_charset</primary></indexterm><programlisting><link linkend="FcCharSet">FcCharSet</link>*          pango_fc_decoder_get_charset        (<link linkend="PangoFcDecoder">PangoFcDecoder</link> *decoder,                                                         <link linkend="PangoFcFont">PangoFcFont</link> *fcfont);</programlisting><para>Generates an <link linkend="FcCharSet"><type>FcCharSet</type></link> of supported characters for the fcfontgiven.  The returned <link linkend="FcCharSet"><type>FcCharSet</type></link> will be a reference to aninternal value stored by the <link linkend="PangoFcDecoder"><type>PangoFcDecoder</type></link> and must notbe modified or freed.</para><para></para><variablelist role="params"><varlistentry><term><parameter>decoder</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoFcDecoder"><type>PangoFcDecoder</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>fcfont</parameter>&nbsp;:</term><listitem><simpara> the <link linkend="PangoFcFont"><type>PangoFcFont</type></link> to query.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the <link linkend="FcCharset"><type>FcCharset</type></link> for <parameter>fcfont</parameter>; must not be modified  or freed.</simpara></listitem></varlistentry></variablelist><para role="since">Since  1.6</para></refsect2><refsect2 id="pango-fc-decoder-get-glyph" role="function" condition="since:1.6"><title>pango_fc_decoder_get_glyph ()</title><indexterm zone="pango-fc-decoder-get-glyph" role="1.6"><primary>pango_fc_decoder_get_glyph</primary></indexterm><programlisting><link linkend="PangoGlyph">PangoGlyph</link>          pango_fc_decoder_get_glyph          (<link linkend="PangoFcDecoder">PangoFcDecoder</link> *decoder,                                                         <link linkend="PangoFcFont">PangoFcFont</link> *fcfont,                                                         <link linkend="guint32">guint32</link> wc);</programlisting><para>Generates a <link linkend="PangoGlyph"><type>PangoGlyph</type></link> for the given Unicode point using thecustom decoder. For complex scripts where there can be multipleglyphs for a single character, the decoder will return whateverglyph is most convenient for it. (Usually whatever glyph is directlyin the fonts character map table.)</para><para></para><variablelist role="params"><varlistentry><term><parameter>decoder</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoFcDecoder"><type>PangoFcDecoder</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>fcfont</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoFcFont"><type>PangoFcFont</type></link> to query.</simpara></listitem></varlistentry><varlistentry><term><parameter>wc</parameter>&nbsp;:</term><listitem><simpara> the Unicode code point to convert to a single <link linkend="PangoGlyph"><type>PangoGlyph</type></link>.</simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the glyph index, or 0 if the glyph isn'tcovered by the font.</simpara></listitem></varlistentry></variablelist><para role="since">Since  1.6</para></refsect2></refsect1></refentry>

⌨️ 快捷键说明

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