Re: g_object_set and threads



abel schie wrote:
[...]
My question is: how can I force g_object_set() to instantly redraw the
cell renderer? My first thought was: use gdk_threads_enter() and
gdk_threads_leave() also within cell_func(). But when I do that, I get
a lock while constructing the treeview, therefore the app
hangs. Putting the routine creating the treeview in a separate thread
as well didn't result in anything good.

    I'm really no treeview grokker, but I came across some similar
behaviour; I was using a pixbuf cell renderer and in some cases I
couldn't find the appropriate pixbuf resource, in this case I found
that the cell renderer would default to a pixbuf found in the same
column but from a different row, but only when I would mouse over it.

If you are experiencing some obscure bug in GTK+, the above info might
help you fix it :)

In any case, I really doubt that this has anything to do with
using threads.

A naive guess of mine would be to suggest you try putting
gtk_widget_queue_draw (treeview) in your timeout function after
treeview manipulation (ofcourse it doesn't really make sence
that you would have to).

Cheers,
                                   -Tristan



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