Re: Persistence with GDK



On 7 Jun 2000, Havoc Pennington wrote:

> When you say "draw the preview" are you using gdk_draw_ functions? If
> so, you should be using a drawing area as in the "scribble" example in
> the tutorial.
> 
> If you're writing RGB data to the preview, I thought GtkPreview
> already kept that around for you.

Both, actually.  GtkPreview does keep the RGB data around, but then the
annotations and such I draw on top of it (by getting the GdkDrawable from
the Preview widget) go away when the window is hidden and re-exposed.

I'm looking at using a backing pixmap for the stuff on top (a la the
Scribble example). However, to do this, I need to be able to copy the
pixmap on to the window with a transparent color (so that the underlying
image written to the GtkPreview doesn't get overwritten with the pixmap's 
background color), but I haven't figured out how to do this.

-Rob





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