RE: Saving a GdkDrawable/GdkPixmap to a picture file

Thanks. The gkd/gtkx.h helped with the display, but I still don't see how to
get an X Pixmap from a GdkPixmap. I see GdkPixmap *gdk_pixmap_foreign_new()
to go from X Pixmap to GdkPixmap, but I'd like to go the other way so that I
can use XpmWriteFileFromPixmap() to write it. Using a GdkPixmap causes a bad
drawable error. Is there something I'm overlooking? (I'm figuring the likely
answer is 'yes.')

Thanks again.


-----Original Message-----
From: Havoc Pennington [mailto:hp redhat com]
Sent: Wednesday, April 25, 2001 1:52 PM
To: Tanikella, Rajanikanth
Subject: Re: Saving a GdkDrawable/GdkPixmap to a picture file

"Tanikella, Rajanikanth" <Rajanikanth Tanikella scr siemens com> writes:

Along these same lines, is it possible to save the pixmap to a file? I
not found a GTK/GDK call that wraps or resembles

      Display *display,
      char *filename,
      Pixmap pixmap,
      Pixmap shapemask,
      XpmAttributes *attributes

Is there a way to access the Display structure and the Pixmap structure
GTK+? They seem well hidden by GTK+. The GdkPixmap, for example, is just a
struct containing a single gpointer. Is there an X Pixmap in there that I
can access?

See gdk/gdkx.h.


Rajanikanth Tanikella             Phone: +1 (609) 734-6529
Siemens Corporate Research, Inc.  Fax: +1 (609) 734-6565
755 College Road East             Email:
rajanikanth tanikella scr siemens com
Princeton, NJ 08540, USA

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]