Re: gtk_drawing_area: what am i missing?



On Tue, May 05, 1998 at 07:08:10PM -0400, Owen Taylor wrote:
> Andy Kahn <kahn@zk3.dec.com> writes:
> > hi all,
> > 
> > i'm trying to use gtk_drawing_area_new() to create a new drawing area,
> > and then manually using gdk_draw_string() to draw a text string inside
> > of it.  however, all i get is a blank window.  the code is as follows:
> 
>   gtk_widget_set_events (drawing_area, GDK_EXPOSURE_MASK);
> 
> It has been proposed to make GDK_EXPOSURE_MASK always set for
> drawing_area widgets, since it is wanted 95% of the time, and
> doesn't exact much of a penalty otherwise. I've never gotten
> around to doing it though.
>                                         Owen
> 
> [ There is a general principle here, which always applies -
>   just connecting to the event signals is not enough, you
>   must also set the event mask with gdk_widget_set_events ]

adding this line after creating the widget didn't have any
visible effect (i still get a blank window).  any other ideas?
--andy



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