From: Paul Davis <[EMAIL PROTECTED]>
>
> yes, it is common to more or less all GUI toolkits, regardless of OS
> platform.
>
> >Isn't there a way to shortly stop calculations (for a necessary minimum
> >of time) and let the GUI gather possible events? Could this work
> >this way somehow? Any suggestions?
>
> somewhere inside your calculations, call this reasonably often:
>
> while (gtk_events_pending()) {
> gtk_main_iteration();
> }
>
> that will update the GUI while your calculations proceed.
Or, better, do:
while(g_main_iteration(FALSE)); /* No body */
which skips the gtk wrappers around the glib main loop.
In 2.0, you'll want to do:
while(g_main_context_iteration(NULL, FALSE)); /* No body */
since g_main_context_iteration() is deprecated in 2.0 (the API changed
a bit when they added support for multiple main loops).
Ron Steinke
_______________________________________________
gtk-list mailing list
[EMAIL PROTECTED]
http://mail.gnome.org/mailman/listinfo/gtk-list