📄 gdk-bitmaps-and-pixmaps.html
字号:
</table></div></div><hr><div class="refsect2" lang="en"><a name="id3122097"></a><h3><a name="gdk-pixmap-create-from-xpm-d"></a>gdk_pixmap_create_from_xpm_d ()</h3><a class="indexterm" name="id3122111"></a><pre class="programlisting"><a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkPixmap">GdkPixmap</a>* gdk_pixmap_create_from_xpm_d (<a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable">GdkDrawable</a> *drawable, <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkBitmap">GdkBitmap</a> **mask, const <a class="link" href="gdk-Colormaps-and-Colors.html#GdkColor">GdkColor</a> *transparent_color, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> **data);</pre><p>Create a pixmap from data in XPM format.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td><td>a <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a>, used to determine default valuesfor the new pixmap.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>mask</code></em> :</span></p></td><td>Pointer to a place to store a bitmap representingthe transparency mask of the XPM file. Can be <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>,in which case transparency will be ignored.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>transparent_color</code></em> :</span></p></td><td>This color will be used for the pixelsthat are transparent in the input file. Can be <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>in which case a default color will be used.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td><td>Pointer to a string containing the XPM data.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>the <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkPixmap"><span class="type">GdkPixmap</span></a></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3122276"></a><h3><a name="gdk-pixmap-colormap-create-from-xpm-d"></a>gdk_pixmap_colormap_create_from_xpm_d ()</h3><a class="indexterm" name="id3122290"></a><pre class="programlisting"><a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkPixmap">GdkPixmap</a>* gdk_pixmap_colormap_create_from_xpm_d (<a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable">GdkDrawable</a> *drawable, <a class="link" href="gdk-Colormaps-and-Colors.html#GdkColormap">GdkColormap</a> *colormap, <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkBitmap">GdkBitmap</a> **mask, const <a class="link" href="gdk-Colormaps-and-Colors.html#GdkColor">GdkColor</a> *transparent_color, <ahref="/usr/share/gtk-doc/html/glib/glib-Basic-Types.html#gchar">gchar</a> **data);</pre><p>Create a pixmap from data in XPM format using a particularcolormap.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><em class="parameter"><code>drawable</code></em> :</span></p></td><td>a <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a>, used to determine default valuesfor the new pixmap. Can be <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a> if <em class="parameter"><code>colormap</code></em> is given.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>colormap</code></em> :</span></p></td><td>the <a class="link" href="gdk-Colormaps-and-Colors.html#GdkColormap"><span class="type">GdkColormap</span></a> that the new pixmap will be use. If omitted, the colormap for <em class="parameter"><code>window</code></em> will be used.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>mask</code></em> :</span></p></td><td>a pointer to a place to store a bitmap representingthe transparency mask of the XPM file. Can be <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>,in which case transparency will be ignored.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>transparent_color</code></em> :</span></p></td><td>the color to be used for the pixelsthat are transparent in the input file. Can be <ahref="/usr/share/gtk-doc/html/liboil/liboil-liboiljunk.html#NULL:CAPS"><code class="literal">NULL</code></a>,in which case a default color will be used.</td></tr><tr><td><p><span class="term"><em class="parameter"><code>data</code></em> :</span></p></td><td>Pointer to a string containing the XPM data.</td></tr><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td>the <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkPixmap"><span class="type">GdkPixmap</span></a>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3122510"></a><h3><a name="gdk-pixmap-ref"></a>gdk_pixmap_ref</h3><a class="indexterm" name="id3122524"></a><pre class="programlisting">#define gdk_pixmap_ref gdk_drawable_ref</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">gdk_pixmap_ref</code> is deprecated and should not be used in newly-written code.</p></div><p>Deprecated equivalent of <ahref="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-ref"><code class="function">g_object_ref()</code></a>.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><em class="parameter"><code>pixmap</code></em></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3122583"></a><h3><a name="gdk-pixmap-unref"></a>gdk_pixmap_unref</h3><a class="indexterm" name="id3122598"></a><pre class="programlisting">#define gdk_pixmap_unref gdk_drawable_unref</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">gdk_pixmap_unref</code> is deprecated and should not be used in newly-written code.</p></div><p>Deprecated equivalent of <ahref="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.</p></div><hr><div class="refsect2" lang="en"><a name="id3122637"></a><h3><a name="GdkBitmap"></a>GdkBitmap</h3><a class="indexterm" name="id3122649"></a><pre class="programlisting">typedef struct _GdkDrawable GdkBitmap;</pre><p>An opaque structure representing an offscreen drawable of depth1. Pointers to structures of type <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkPixmap"><span class="type">GdkPixmap</span></a>, <a class="link" href="gdk-Bitmaps-and-Pixmaps.html#GdkBitmap"><span class="type">GdkBitmap</span></a>, and<a class="link" href="gdk-Windows.html#GdkWindow"><span class="type">GdkWindow</span></a>, can often be used interchangeably. The type <a class="link" href="gdk-Drawing-Primitives.html#GdkDrawable"><span class="type">GdkDrawable</span></a>refers generically to any of these types.</p></div><hr><div class="refsect2" lang="en"><a name="id3122699"></a><h3><a name="gdk-bitmap-ref"></a>gdk_bitmap_ref</h3><a class="indexterm" name="id3122714"></a><pre class="programlisting">#define gdk_bitmap_ref gdk_drawable_ref</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">gdk_bitmap_ref</code> is deprecated and should not be used in newly-written code.</p></div><p>Deprecated equivalent of <ahref="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-ref"><code class="function">g_object_ref()</code></a>.</p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><p><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></p></td><td><em class="parameter"><code>pixmap</code></em></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id3122772"></a><h3><a name="gdk-bitmap-unref"></a>gdk_bitmap_unref</h3><a class="indexterm" name="id3122788"></a><pre class="programlisting">#define gdk_bitmap_unref gdk_drawable_unref</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">gdk_bitmap_unref</code> is deprecated and should not be used in newly-written code.</p></div><p>Deprecated equivalent of <ahref="/usr/share/gtk-doc/html/gobject/gobject-The-Base-Object-Type.html#g-object-unref"><code class="function">g_object_unref()</code></a>.</p></div></div><div class="refsect1" lang="en"><a name="id3122828"></a><div class="refsect2" lang="en"><a name="id3122829"></a></div><hr><div class="refsect2" lang="en"><a name="id3122830"></a></div></div></div></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -