multiple gtk_image



Hi all.

I've a set of gtk_image created like that : 

image1 = gtk_image_new (gdk_image_new (GDK_IMAGE_FASTEST,
gdk_visual_get_system (), 256, 256), NULL);

(with image1, image2, etc)

They appear ok, then I want to draw something in it.

  gdk_draw_rgb_image
((GdkDrawable*)image4->window,image4->style->fg_gc[GTK_STATE_NORMAL],
		      0, 0, width, height,
		      GDK_RGB_DITHER_NORMAL, (guchar*)buffer,  width * 3);


that's for image4 as you saw.
he problem is ... that it'll draw the image in the first image.
Same if I put image2 or image3, it'll be drawn in the first one.
I was wondering if the IMAGE->window was the same everywhere, I mean,
the window is the same, so how can gtk determine on which image to draw,
as I never pass image structure to it.

Thanks a lot


-- 
Jean-Yves Lamoureux
jylam lnxscene org
http://www.lnxscene.org




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