Re: force drawing area expose on button click



Oh wow, I feel dumb.  I had my

gtk_drawing_area_new();

below the

g_signal_connect_after();

Thanks, it works great now.

Tristan Van Berkom wrote:

Scott Rubin wrote:
> Ok, I tried doing that before.  It doesn't work.  I get a runtime
> error.  Apparently the pointers act funny and the functions doesn't
> believe that it's actually a Widget.
> (oglbb:7399): Gtk-CRITICAL **: file gtkwidget.c: line 2176
> (gtk_widget_queue_draw): assertion `GTK_IS_WIDGET (widget)' failed


So when you make this call:
>>        g_signal_connect (G_OBJECT (button), "clicked",
>>                          G_CALLBACK (redraw), drawing_area);

does `drawing_area' point to a GtkWidget
(that is already created at this point) ?

Maybe an isolated piece of code that reproduces this could be of help ?

Cheers,
                -Tristan





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