Question in using gdk_pixbuf_get_from_drawable()

2008-03-20 Thread ying lcs
Hi, I have a question of using gdk_pixbuf_get_from_drawable(). I have the following code which save the gdk window to a png file. But something I get something which is totally not what is displayed on the window. Can you please tell me what am I missing? GdkWindow *window ; if (window != NULL)

Re: Whether the application is active?

2008-03-20 Thread v4r4n
I'm unsure if this is a viable solution, but since 2.10 this function appears to solve the problem? http://library.gnome.org/devel/gdk/stable/GdkScreen.html#gdk-screen-get-active-window You can get your GdkScreen from a GtkWidget and using gdk_screen_get_active_window() find your GdkWindow. On

Re: How does one overlay one image on top of another ?

2008-03-20 Thread Bob Murphy
I found gdk_draw_drawable(), but don't really understand GdkDrawables. I'd REALLY like to draw an image on a different layer such that I can move/remove it w/o having to redraw the original. Failing that, I'll settle for learning how to overlay one image on top of another. I recently

Getting a colormap...

2008-03-20 Thread Michael
I'm using giflib to create a GIF image from raw GdkPixbuf pixel data. Everything works... except the colors are really screwey. I'm using a default, 16-color color map from the source of a utility in the giflib code. I assume that's the problem. When I save the pixbuf as another format using

Re: Question in using gdk_pixbuf_get_from_drawable()

2008-03-20 Thread Luis Menina
Hi, where does your window object come from ? Could you please give us the code where you initilized it ? I've tried to adapt your code in a simple example, and it just works... I get a screenshot of what is in the window, without the window decoration. Cheers, Luis ying lcs a écrit : Hi,