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

📄 layout.xml

📁 Pango is a library for layout and rendering of text, with an emphasis on internationalization. Pang
💻 XML
📖 第 1 页 / 共 5 页
字号:
Depending on the ellipsization mode <parameter>ellipsize</parameter> text isremoved from the start, middle, or end of text so theyfit within the width and height of layout set with<link linkend="pango-layout-set-width"><function>pango_layout_set_width()</function></link> and <link linkend="pango-layout-set-height"><function>pango_layout_set_height()</function></link>.</para><para>If the layout contains characters such as newlines thatforce it to be layed out in multiple paragraphs, then whethereach paragraph is ellipsized separately or the entire layoutis ellipsized as a whole depends on the set height of the layout.See <link linkend="pango-layout-set-height"><function>pango_layout_set_height()</function></link> for details.</para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link></simpara></listitem></varlistentry><varlistentry><term><parameter>ellipsize</parameter>&nbsp;:</term><listitem><simpara> the new ellipsization mode for <parameter>layout</parameter></simpara></listitem></varlistentry></variablelist><para role="since">Since  1.6</para></refsect2><refsect2 id="pango-layout-get-ellipsize" role="function" condition="since:1.6"><title>pango_layout_get_ellipsize ()</title><indexterm zone="pango-layout-get-ellipsize" role="1.6"><primary>pango_layout_get_ellipsize</primary></indexterm><programlisting><link linkend="PangoEllipsizeMode">PangoEllipsizeMode</link>  pango_layout_get_ellipsize          (<link linkend="PangoLayout">PangoLayout</link> *layout);</programlisting><para>Gets the type of ellipsization being performed for <parameter>layout</parameter>.See <link linkend="pango-layout-set-ellipsize"><function>pango_layout_set_ellipsize()</function></link></para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the current ellipsization mode for <parameter>layout</parameter>.Use <link linkend="pango-layout-is-ellipsized"><function>pango_layout_is_ellipsized()</function></link> to query whether any paragraphswere actually ellipsized.</simpara></listitem></varlistentry></variablelist><para role="since">Since  1.6</para></refsect2><refsect2 id="pango-layout-is-ellipsized" role="function" condition="since:1.16"><title>pango_layout_is_ellipsized ()</title><indexterm zone="pango-layout-is-ellipsized" role="1.16"><primary>pango_layout_is_ellipsized</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            pango_layout_is_ellipsized          (<link linkend="PangoLayout">PangoLayout</link> *layout);</programlisting><para>Queries whether the layout had to ellipsize any paragraphs.</para><para>This returns <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if the ellipsization mode for <parameter>layout</parameter>is not <link linkend="PANGO-ELLIPSIZE-NONE:CAPS"><literal>PANGO_ELLIPSIZE_NONE</literal></link>, a positive width is set on <parameter>layout</parameter>,and there are paragraphs exceeding that width that have to beellipsized.</para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if any paragraphs had to be ellipsized, <link linkend="FALSE:CAPS"><literal>FALSE</literal></link>otherwise.</simpara></listitem></varlistentry></variablelist><para role="since">Since  1.16</para></refsect2><refsect2 id="PangoEllipsizeMode" role="enum"><title>enum PangoEllipsizeMode</title><indexterm zone="PangoEllipsizeMode"><primary>PangoEllipsizeMode</primary></indexterm><programlisting>typedef enum {  PANGO_ELLIPSIZE_NONE,  PANGO_ELLIPSIZE_START,  PANGO_ELLIPSIZE_MIDDLE,  PANGO_ELLIPSIZE_END} PangoEllipsizeMode;</programlisting><para>The <link linkend="PangoEllipsizeMode"><type>PangoEllipsizeMode</type></link> type describes what sort of (if any)ellipsization should be applied to a line of text. Inthe ellipsization process characters are removed from thetext in order to make it fit to a given width and replacedwith an ellipsis.</para><para></para><variablelist role="enum"><varlistentry id="PANGO-ELLIPSIZE-NONE:CAPS" role="constant"><term><literal>PANGO_ELLIPSIZE_NONE</literal></term><listitem><simpara> No ellipsization</simpara></listitem></varlistentry><varlistentry id="PANGO-ELLIPSIZE-START:CAPS" role="constant"><term><literal>PANGO_ELLIPSIZE_START</literal></term><listitem><simpara> Omit characters at the start of the text</simpara></listitem></varlistentry><varlistentry id="PANGO-ELLIPSIZE-MIDDLE:CAPS" role="constant"><term><literal>PANGO_ELLIPSIZE_MIDDLE</literal></term><listitem><simpara> Omit characters in the middle of the text</simpara></listitem></varlistentry><varlistentry id="PANGO-ELLIPSIZE-END:CAPS" role="constant"><term><literal>PANGO_ELLIPSIZE_END</literal></term><listitem><simpara> Omit characters at the end of the text</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="PANGO-TYPE-ELLIPSIZE-MODE:CAPS" role="macro"><title>PANGO_TYPE_ELLIPSIZE_MODE</title><indexterm zone="PANGO-TYPE-ELLIPSIZE-MODE:CAPS"><primary>PANGO_TYPE_ELLIPSIZE_MODE</primary></indexterm><programlisting>#define PANGO_TYPE_ELLIPSIZE_MODE (pango_ellipsize_mode_get_type())</programlisting><para>The <link linkend="GObject"><type>GObject</type></link> type for <link linkend="PangoEllipsizeMode"><type>PangoEllipsizeMode</type></link>.</para></refsect2><refsect2 id="pango-layout-set-indent" role="function"><title>pango_layout_set_indent ()</title><indexterm zone="pango-layout-set-indent"><primary>pango_layout_set_indent</primary></indexterm><programlisting><link linkend="void">void</link>                pango_layout_set_indent             (<link linkend="PangoLayout">PangoLayout</link> *layout,                                                         <link linkend="int">int</link> indent);</programlisting><para>Sets the width in Pango units to indent each paragraph. A negative valueof <parameter>indent</parameter> will produce a hanging indentation. That is, the first line willhave the full width, and subsequent lines will be indented by theabsolute value of <parameter>indent</parameter>.</para><para>The indent setting is ignored if layout alignment is set to<link linkend="PANGO-ALIGN-CENTER:CAPS"><literal>PANGO_ALIGN_CENTER</literal></link>.</para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link>.</simpara></listitem></varlistentry><varlistentry><term><parameter>indent</parameter>&nbsp;:</term><listitem><simpara> the amount by which to indent.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-layout-get-indent" role="function"><title>pango_layout_get_indent ()</title><indexterm zone="pango-layout-get-indent"><primary>pango_layout_get_indent</primary></indexterm><programlisting><link linkend="int">int</link>                 pango_layout_get_indent             (<link linkend="PangoLayout">PangoLayout</link> *layout);</programlisting><para>Gets the paragraph indent width in Pango units. A negative valueindicates a hanging indentation.</para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the indent in Pango units.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-layout-get-spacing" role="function"><title>pango_layout_get_spacing ()</title><indexterm zone="pango-layout-get-spacing"><primary>pango_layout_get_spacing</primary></indexterm><programlisting><link linkend="int">int</link>                 pango_layout_get_spacing            (<link linkend="PangoLayout">PangoLayout</link> *layout);</programlisting><para>Gets the amount of spacing between the lines of the layout.</para><para></para><variablelist role="params"><varlistentry><term><parameter>layout</parameter>&nbsp;:</term><listitem><simpara> a <link linkend="PangoLayout"><type>PangoLayout</type></link></simpara></listitem></varlistentry><varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the spacing in Pango units.</simpara></listitem></varlistentry></variablelist></refsect2><refsect2 id="pango-layout-set-spacing" role="function"><title>pango_layout_set_spacing ()</title><indexterm zone="pango-layout-set-spacing"><primary>pango_layout_set_spacing</primary></indexterm><programlisting><link linkend="void">void</link>                pango_layout_set_spacing            (<link linkend="PangoLayout">PangoLayout</link> *layout,                                                         <link linkend="int">int</link> spacing);</programlisting><para>Sets the amount of spacing in Pango unit between the lines of thelayout.</para><para></para><variable

⌨️ 快捷键说明

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