Re: Problem using Gtk 2.2.1 on WinXP



Daniel K. O. writes:
But it doesn't run under WinXP. It just freezes in the gtk_main. Is 
there something wrong with this code?

Comparing to the sample program at
http://developer.gnome.org/doc/API/2.0/gdk/gdk-Threads.html , it seems
that you should surround the call to gtk_main() with
gdk_threads_enter() and gdk_threads_leave(). Indeed, with this
addition your test program works.

(I don't know why it works as such on Win9x.)

*But*, if you are writing a multi-threaded GTK program, please note
that in general multi-threaded GTK use doesn't work on Windows (yet,
and don't hold your breath waiting for it to be fixed).

See
http://mail.gnome.org/archives/gtk-devel-list/2001-November/msg00227.html
and http://bugzilla.gnome.org/show_bug.cgi?id=60620 .

--tml





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