<refentry id="GnomePixmap">
<refmeta>
<refentrytitle role="top_of_page" id="GnomePixmap.top_of_page">GnomePixmap</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>LIBGNOMEUI Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>GnomePixmap</refname>
<refpurpose></refpurpose>
</refnamediv>

<refsynopsisdiv id="GnomePixmap.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>

#include &lt;libgnomeui/libgnomeui.h&gt;

                    <link linkend="GnomePixmapPrivate">GnomePixmapPrivate</link>;
                    <link linkend="GnomePixmap-struct">GnomePixmap</link>;
<link linkend="GtkWidget">GtkWidget</link> *         <link linkend="gnome-pixmap-new-from-file">gnome_pixmap_new_from_file</link>          (const <link linkend="gchar">gchar</link> *filename);
<link linkend="GtkWidget">GtkWidget</link> *         <link linkend="gnome-pixmap-new-from-file-at-size">gnome_pixmap_new_from_file_at_size</link>  (const <link linkend="gchar">gchar</link> *filename,
                                                         <link linkend="gint">gint</link> width,
                                                         <link linkend="gint">gint</link> height);
<link linkend="GtkWidget">GtkWidget</link> *         <link linkend="gnome-pixmap-new-from-xpm-d">gnome_pixmap_new_from_xpm_d</link>         (const <link linkend="gchar">gchar</link> **xpm_data);
<link linkend="GtkWidget">GtkWidget</link> *         <link linkend="gnome-pixmap-new-from-xpm-d-at-size">gnome_pixmap_new_from_xpm_d_at_size</link> (const <link linkend="gchar">gchar</link> **xpm_data,
                                                         <link linkend="gint">gint</link> width,
                                                         <link linkend="gint">gint</link> height);
<link linkend="GtkWidget">GtkWidget</link> *         <link linkend="gnome-pixmap-new-from-gnome-pixmap">gnome_pixmap_new_from_gnome_pixmap</link>  (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap);
<link linkend="void">void</link>                <link linkend="gnome-pixmap-load-file">gnome_pixmap_load_file</link>              (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> *filename);
<link linkend="void">void</link>                <link linkend="gnome-pixmap-load-file-at-size">gnome_pixmap_load_file_at_size</link>      (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> *filename,
                                                         <link linkend="int">int</link> width,
                                                         <link linkend="int">int</link> height);
<link linkend="void">void</link>                <link linkend="gnome-pixmap-load-xpm-d">gnome_pixmap_load_xpm_d</link>             (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> **xpm_data);
<link linkend="void">void</link>                <link linkend="gnome-pixmap-load-xpm-d-at-size">gnome_pixmap_load_xpm_d_at_size</link>     (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> **xpm_data,
                                                         <link linkend="int">int</link> width,
                                                         <link linkend="int">int</link> height);
</synopsis>
</refsynopsisdiv>

<refsect1 id="GnomePixmap.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<synopsis>
  <link linkend="GObject">GObject</link>
   +----<link linkend="GInitiallyUnowned">GInitiallyUnowned</link>
         +----<link linkend="GtkObject">GtkObject</link>
               +----<link linkend="GtkWidget">GtkWidget</link>
                     +----<link linkend="GtkMisc">GtkMisc</link>
                           +----<link linkend="GtkImage">GtkImage</link>
                                 +----GnomePixmap
</synopsis>
</refsect1>



<refsect1 id="GnomePixmap.implemented-interfaces" role="impl_interfaces">
<title role="impl_interfaces.title">Implemented Interfaces</title>
<para>
GnomePixmap implements
 <link linkend="GtkBuildable">GtkBuildable</link> and  <link linkend="AtkImplementorIface">AtkImplementorIface</link>.</para>
</refsect1>





<refsect1 id="GnomePixmap.description" role="desc">
<title role="desc.title">Description</title>
<para>
</para>
</refsect1>

<refsect1 id="GnomePixmap.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="GnomePixmapPrivate" role="struct" condition="deprecated:">
<title>GnomePixmapPrivate</title>
<indexterm zone="GnomePixmapPrivate" role="deprecated"><primary sortas="GnomePixmapPrivate">GnomePixmapPrivate</primary></indexterm><programlisting>typedef struct _GnomePixmapPrivate GnomePixmapPrivate;</programlisting>
<warning><para><literal>GnomePixmapPrivate</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para></refsect2>
<refsect2 id="GnomePixmap-struct" role="struct">
<title>GnomePixmap</title>
<indexterm zone="GnomePixmap-struct" role="deprecated"><primary sortas="GnomePixmap">GnomePixmap</primary></indexterm><programlisting>typedef struct _GnomePixmap GnomePixmap;</programlisting>
<warning><para><literal>GnomePixmap</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para></refsect2>
<refsect2 id="gnome-pixmap-new-from-file" role="function" condition="deprecated:">
<title>gnome_pixmap_new_from_file ()</title>
<indexterm zone="gnome-pixmap-new-from-file" role="deprecated"><primary sortas="gnome_pixmap_new_from_file">gnome_pixmap_new_from_file</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link> *         gnome_pixmap_new_from_file          (const <link linkend="gchar">gchar</link> *filename);</programlisting>
<warning><para><literal>gnome_pixmap_new_from_file</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
Note that the new_from_file functions give you no way to detect errors;
if the file isn't found/loaded, you get an empty widget.
to detect errors just do:
</para>
<para>
&lt;programlisting&gt;
pixbuf = gdk_pixbuf_new_from_file (filename);
if (pixbuf != NULL) {
        gpixmap = gtk_image_new_from_pixbuf (pixbuf);
} else {
        // handle your error...
}
&lt;/programlisting&gt;</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>filename</parameter>&#160;:</term>
<listitem><simpara> The filename of the file to be loaded.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> A newly allocated <parameter>GnomePixmap</parameter> with the file at <parameter>filename</parameter> loaded.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-new-from-file-at-size" role="function" condition="deprecated:">
<title>gnome_pixmap_new_from_file_at_size ()</title>
<indexterm zone="gnome-pixmap-new-from-file-at-size" role="deprecated"><primary sortas="gnome_pixmap_new_from_file_at_size">gnome_pixmap_new_from_file_at_size</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link> *         gnome_pixmap_new_from_file_at_size  (const <link linkend="gchar">gchar</link> *filename,
                                                         <link linkend="gint">gint</link> width,
                                                         <link linkend="gint">gint</link> height);</programlisting>
<warning><para><literal>gnome_pixmap_new_from_file_at_size</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
Loads a new <parameter>GnomePixmap</parameter> from a file, and scales it (if necessary) to the
size indicated by <parameter>height</parameter> and <parameter>width</parameter>.  If either are set to -1, then the
"natural" dimension of the image is used in place.  See
<parameter>gnome_pixmap_new_from_file</parameter> for information on error handling.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>filename</parameter>&#160;:</term>
<listitem><simpara> The filename of the file to be loaded.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>width</parameter>&#160;:</term>
<listitem><simpara> The width to scale the image to.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>height</parameter>&#160;:</term>
<listitem><simpara> The height to scale the image to.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> value: A newly allocated <parameter>GnomePixmap</parameter> with the file at <parameter>filename</parameter> loaded.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-new-from-xpm-d" role="function" condition="deprecated:">
<title>gnome_pixmap_new_from_xpm_d ()</title>
<indexterm zone="gnome-pixmap-new-from-xpm-d" role="deprecated"><primary sortas="gnome_pixmap_new_from_xpm_d">gnome_pixmap_new_from_xpm_d</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link> *         gnome_pixmap_new_from_xpm_d         (const <link linkend="gchar">gchar</link> **xpm_data);</programlisting>
<warning><para><literal>gnome_pixmap_new_from_xpm_d</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
Loads a new <parameter>GnomePixmap</parameter> from the <parameter>xpm_data</parameter>, and scales it (if necessary) to
the size indicated by <parameter>height</parameter> and <parameter>width</parameter>.  If either are set to -1, then the
"natural" dimension of the image is used in place.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>xpm_data</parameter>&#160;:</term>
<listitem><simpara> The xpm data to be loaded.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> value: A newly allocated <parameter>GnomePixmap</parameter> with the image from <parameter>xpm_data</parameter> loaded.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-new-from-xpm-d-at-size" role="function" condition="deprecated:">
<title>gnome_pixmap_new_from_xpm_d_at_size ()</title>
<indexterm zone="gnome-pixmap-new-from-xpm-d-at-size" role="deprecated"><primary sortas="gnome_pixmap_new_from_xpm_d_at_size">gnome_pixmap_new_from_xpm_d_at_size</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link> *         gnome_pixmap_new_from_xpm_d_at_size (const <link linkend="gchar">gchar</link> **xpm_data,
                                                         <link linkend="gint">gint</link> width,
                                                         <link linkend="gint">gint</link> height);</programlisting>
<warning><para><literal>gnome_pixmap_new_from_xpm_d_at_size</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
Loads a new <parameter>GnomePixmap</parameter> from the <parameter>xpm_data</parameter>, and scales it (if necessary) to
the size indicated by <parameter>height</parameter> and <parameter>width</parameter>.  If either are set to -1, then the
"natural" dimension of the image is used in place.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>xpm_data</parameter>&#160;:</term>
<listitem><simpara> The xpm data to be loaded.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>width</parameter>&#160;:</term>
<listitem><simpara> The width to scale the image to.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>height</parameter>&#160;:</term>
<listitem><simpara> The height to scale the image to.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> value: A newly allocated <parameter>GnomePixmap</parameter> with the image from <parameter>xpm_data</parameter> loaded.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-new-from-gnome-pixmap" role="function" condition="deprecated:">
<title>gnome_pixmap_new_from_gnome_pixmap ()</title>
<indexterm zone="gnome-pixmap-new-from-gnome-pixmap" role="deprecated"><primary sortas="gnome_pixmap_new_from_gnome_pixmap">gnome_pixmap_new_from_gnome_pixmap</primary></indexterm><programlisting><link linkend="GtkWidget">GtkWidget</link> *         gnome_pixmap_new_from_gnome_pixmap  (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap);</programlisting>
<warning><para><literal>gnome_pixmap_new_from_gnome_pixmap</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>gpixmap</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-load-file" role="function" condition="deprecated:">
<title>gnome_pixmap_load_file ()</title>
<indexterm zone="gnome-pixmap-load-file" role="deprecated"><primary sortas="gnome_pixmap_load_file">gnome_pixmap_load_file</primary></indexterm><programlisting><link linkend="void">void</link>                gnome_pixmap_load_file              (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> *filename);</programlisting>
<warning><para><literal>gnome_pixmap_load_file</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>gpixmap</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>filename</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-load-file-at-size" role="function" condition="deprecated:">
<title>gnome_pixmap_load_file_at_size ()</title>
<indexterm zone="gnome-pixmap-load-file-at-size" role="deprecated"><primary sortas="gnome_pixmap_load_file_at_size">gnome_pixmap_load_file_at_size</primary></indexterm><programlisting><link linkend="void">void</link>                gnome_pixmap_load_file_at_size      (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> *filename,
                                                         <link linkend="int">int</link> width,
                                                         <link linkend="int">int</link> height);</programlisting>
<warning><para><literal>gnome_pixmap_load_file_at_size</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>gpixmap</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>filename</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>width</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>height</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-load-xpm-d" role="function" condition="deprecated:">
<title>gnome_pixmap_load_xpm_d ()</title>
<indexterm zone="gnome-pixmap-load-xpm-d" role="deprecated"><primary sortas="gnome_pixmap_load_xpm_d">gnome_pixmap_load_xpm_d</primary></indexterm><programlisting><link linkend="void">void</link>                gnome_pixmap_load_xpm_d             (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> **xpm_data);</programlisting>
<warning><para><literal>gnome_pixmap_load_xpm_d</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>gpixmap</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>xpm_data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="gnome-pixmap-load-xpm-d-at-size" role="function" condition="deprecated:">
<title>gnome_pixmap_load_xpm_d_at_size ()</title>
<indexterm zone="gnome-pixmap-load-xpm-d-at-size" role="deprecated"><primary sortas="gnome_pixmap_load_xpm_d_at_size">gnome_pixmap_load_xpm_d_at_size</primary></indexterm><programlisting><link linkend="void">void</link>                gnome_pixmap_load_xpm_d_at_size     (<link linkend="GnomePixmap">GnomePixmap</link> *gpixmap,
                                                         const <link linkend="char">char</link> **xpm_data,
                                                         <link linkend="int">int</link> width,
                                                         <link linkend="int">int</link> height);</programlisting>
<warning><para><literal>gnome_pixmap_load_xpm_d_at_size</literal> is deprecated and should not be used in newly-written code.</para></warning>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>gpixmap</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>xpm_data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>width</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>height</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
