?? gtk-themeable-stock-images.html
字號:
or make the icon look insensitive/prelighted.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>pixbuf</code></em> :</span></p></td><td> a <ahref="/usr/share/gtk-doc/html/gdk-pixbuf/gdk-pixbuf-gdk-pixbuf.html#GdkPixbuf"><span class="type">GdkPixbuf</span></a></td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td> a new <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet"><span class="type">GtkIconSet</span></a></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3223403"></a><h3><a name="gtk-icon-set-ref"></a>gtk_icon_set_ref ()</h3><a class="indexterm" name="id3223416"></a><pre class="programlisting"><a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet">GtkIconSet</a>* gtk_icon_set_ref (<a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet">GtkIconSet</a> *icon_set);</pre><p>Increments the reference count on <em class="parameter"><code>icon_set</code></em>.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>icon_set</code></em> :</span></p></td><td> a <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet"><span class="type">GtkIconSet</span></a>.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td> <em class="parameter"><code>icon_set</code></em>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3223495"></a><h3><a name="gtk-icon-set-render-icon"></a>gtk_icon_set_render_icon ()</h3><a class="indexterm" name="id3223508"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/gdk-pixbuf/gdk-pixbuf-gdk-pixbuf.html#GdkPixbuf">GdkPixbuf</a>* gtk_icon_set_render_icon (<a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet">GtkIconSet</a> *icon_set, <a class="link" href="GtkStyle.html" title="Styles">GtkStyle</a> *style, <a class="link" href="GtkWidget.html#GtkTextDirection">GtkTextDirection</a> direction, <a class="link" href="gtk-Standard-Enumerations.html#GtkStateType">GtkStateType</a> state, <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSize">GtkIconSize</a> size, <a class="link" href="GtkWidget.html" title="GtkWidget">GtkWidget</a> *widget, const char *detail);</pre><p>Renders an icon using <a class="link" href="GtkStyle.html#gtk-style-render-icon"><code class="function">gtk_style_render_icon()</code></a>. In most cases,<a class="link" href="GtkWidget.html#gtk-widget-render-icon"><code class="function">gtk_widget_render_icon()</code></a> is better, since it automatically providesmost of the arguments from the current widget settings. Thisfunction never returns <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>; if the icon can't be rendered(perhaps because an image file fails to load), a default "missingimage" icon will be returned instead.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>icon_set</code></em> :</span></p></td><td> a <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet"><span class="type">GtkIconSet</span></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>style</code></em> :</span></p></td><td> a <a class="link" href="GtkStyle.html" title="Styles"><span class="type">GtkStyle</span></a> associated with <em class="parameter"><code>widget</code></em>, or <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a></td></tr><tr><td><p><span class="term"><em class="parameter"><code>direction</code></em> :</span></p></td><td> text direction</td></tr><tr><td><p><span class="term"><em class="parameter"><code>state</code></em> :</span></p></td><td> widget state</td></tr><tr><td><p><span class="term"><em class="parameter"><code>size</code></em> :</span></p></td><td> icon size. A size of (GtkIconSize)-1 means render at the size of the source and don't scale.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>widget</code></em> :</span></p></td><td> widget that will display the icon, or <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. The only use that is typically made of this is to determine the appropriate <ahref="/usr/share/gtk-doc/html/gdk/GdkScreen.html"><span class="type">GdkScreen</span></a>.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>detail</code></em> :</span></p></td><td> detail to pass to the theme engine, or <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>. Note that passing a detail of anything but <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> will disable caching.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td> a <ahref="/usr/share/gtk-doc/html/gdk-pixbuf/gdk-pixbuf-gdk-pixbuf.html#GdkPixbuf"><span class="type">GdkPixbuf</span></a> to be displayed</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3223821"></a><h3><a name="gtk-icon-set-unref"></a>gtk_icon_set_unref ()</h3><a class="indexterm" name="id3223835"></a><pre class="programlisting">void gtk_icon_set_unref (<a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet">GtkIconSet</a> *icon_set);</pre><p>Decrements the reference count on <em class="parameter"><code>icon_set</code></em>, and frees memoryif the reference count reaches 0.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>icon_set</code></em> :</span></p></td><td> a <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSet"><span class="type">GtkIconSet</span></a></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3223899"></a><h3><a name="gtk-icon-size-lookup"></a>gtk_icon_size_lookup ()</h3><a class="indexterm" name="id3223912"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean">gboolean</a> gtk_icon_size_lookup (<a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSize">GtkIconSize</a> size, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> *width, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> *height);</pre><p>Obtains the pixel size of a semantic icon size, possiblymodified by user preferences for the default <a class="link" href="GtkSettings.html" title="Settings"><span class="type">GtkSettings</span></a>.(See <a class="link" href="gtk-Themeable-Stock-Images.html#gtk-icon-size-lookup-for-settings"><code class="function">gtk_icon_size_lookup_for_settings()</code></a>.)Normally <em class="parameter"><code>size</code></em> would be<span class="type">GTK_ICON_SIZE_MENU</span>, <span class="type">GTK_ICON_SIZE_BUTTON</span>, etc. This functionisn't normally needed, <a class="link" href="GtkWidget.html#gtk-widget-render-icon"><code class="function">gtk_widget_render_icon()</code></a> is the usualway to get an icon for rendering, then just look at the size ofthe rendered pixbuf. The rendered pixbuf may not even correspond tothe width/height returned by <a class="link" href="gtk-Themeable-Stock-Images.html#gtk-icon-size-lookup"><code class="function">gtk_icon_size_lookup()</code></a>, because themesare free to render the pixbuf however they like, including changingthe usual size.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>size</code></em> :</span></p></td><td> an icon size</td></tr><tr><td><p><span class="term"><em class="parameter"><code>width</code></em> :</span></p></td><td> location to store icon width</td></tr><tr><td><p><span class="term"><em class="parameter"><code>height</code></em> :</span></p></td><td> location to store icon height</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td> <ahref="/usr/share/gtk-doc/html/glib/glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if <em class="parameter"><code>size</code></em> was a valid size</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3224107"></a><h3><a name="gtk-icon-size-lookup-for-settings"></a>gtk_icon_size_lookup_for_settings ()</h3><a class="indexterm" name="id3224124"></a><pre class="programlisting"><ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gboolean">gboolean</a> gtk_icon_size_lookup_for_settings (<a class="link" href="GtkSettings.html" title="Settings">GtkSettings</a> *settings, <a class="link" href="gtk-Themeable-Stock-Images.html#GtkIconSize">GtkIconSize</a> size, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> *width, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gint">gint</a> *height);</pre><p>Obtains the pixel size of a semantic icon size, possiblymodified by user preferences for a particular
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -