Re: gtk_drawing_area: what am i missing?




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 ]



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