1 #ifndef __GDK_PIXMAP_H__
2 #define __GDK_PIXMAP_H__
4 #include <gdk/gdktypes.h>
5 #include <gdk/gdkdrawable.h>
9 #endif /* __cplusplus */
11 typedef struct _GdkPixmapObject GdkPixmapObject;
12 typedef struct _GdkPixmapObjectClass GdkPixmapObjectClass;
14 #define GDK_TYPE_PIXMAP (gdk_pixmap_get_type ())
15 #define GDK_PIXMAP(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GDK_TYPE_PIXMAP, GdkPixmap))
16 #define GDK_PIXMAP_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_PIXMAP, GdkPixmapObjectClass))
17 #define GDK_IS_PIXMAP(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GDK_TYPE_PIXMAP))
18 #define GDK_IS_PIXMAP_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_PIXMAP))
19 #define GDK_PIXMAP_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GDK_TYPE_PIXMAP, GdkPixmapObjectClass))
20 #define GDK_PIXMAP_OBJECT(object) ((GdkPixmapObject *) GDK_PIXMAP (object))
22 struct _GdkPixmapObject
24 GdkDrawable parent_instance;
26 GdkDrawable *impl; /* window-system-specific delegate object */
31 struct _GdkPixmapObjectClass
33 GdkDrawableClass parent_class;
37 GType gdk_pixmap_get_type (void) G_GNUC_CONST;
41 GdkPixmap* gdk_pixmap_new (GdkDrawable *drawable,
45 GdkBitmap* gdk_bitmap_create_from_data (GdkDrawable *drawable,
49 GdkPixmap* gdk_pixmap_create_from_data (GdkDrawable *drawable,
57 GdkPixmap* gdk_pixmap_create_from_xpm (GdkDrawable *drawable,
59 GdkColor *transparent_color,
60 const gchar *filename);
61 GdkPixmap* gdk_pixmap_colormap_create_from_xpm (GdkDrawable *drawable,
62 GdkColormap *colormap,
64 GdkColor *transparent_color,
65 const gchar *filename);
66 GdkPixmap* gdk_pixmap_create_from_xpm_d (GdkDrawable *drawable,
68 GdkColor *transparent_color,
70 GdkPixmap* gdk_pixmap_colormap_create_from_xpm_d (GdkDrawable *drawable,
71 GdkColormap *colormap,
73 GdkColor *transparent_color,
76 /* Functions to create/lookup pixmaps from their native equivalents
78 #ifndef GDK_MULTIHEAD_SAFE
79 GdkPixmap* gdk_pixmap_foreign_new (GdkNativeWindow anid);
80 GdkPixmap* gdk_pixmap_lookup (GdkNativeWindow anid);
81 #endif /* GDK_MULTIHEAD_SAFE */
83 GdkPixmap* gdk_pixmap_foreign_new_for_display (GdkDisplay *display,
84 GdkNativeWindow anid);
85 GdkPixmap* gdk_pixmap_lookup_for_display (GdkDisplay *display,
86 GdkNativeWindow anid);
88 #ifndef GDK_DISABLE_DEPRECATED
89 #define gdk_bitmap_ref gdk_drawable_ref
90 #define gdk_bitmap_unref gdk_drawable_unref
91 #define gdk_pixmap_ref gdk_drawable_ref
92 #define gdk_pixmap_unref gdk_drawable_unref
93 #endif /* GDK_DISABLE_DEPRECATED */
97 #endif /* __cplusplus */
99 #endif /* __GDK_PIXMAP_H__ */