Re: global cursor setting?



> Does anyone know how to go about setting a window containing multple widgets
> to have a single cursor?  I am currently trying to modify the gtkfilesel.c
> file to change the cursor to a GDK_WATCH regardless of which widget the
> cursor is over while performing filename completion stuff using;
> 
> gdk_window_set_cursor(GTK_WIDGET(fs)->window, gdk_cursor_new(GDK_WATCH));

Firstly you should use a struct for yer window.

mywin->busy_cursor = gdk_cursor_new(...);
mywin->toplevel = gtk_window_new(...);

Now somewhere after initialization...

gdk_window_set_cursor(
	GTK_WIDGET(mywin->toplevel)->window,
	mywin->busy_cursor
);
gdk_flush();


The above works for my programs.




--
Sincerely,                  ,"-_                         \|/
-Capt. Taura M.             ,   O=__                    --X--
..__                         ,_JNMNNEO=_                 /|\
OMNOUMmnne.                  {OMMNNNEEEEOO=_
UOOOBIOOOEOMMn.               'LONMMMMNNEEEOOO=.__..,,..
UUOOEUUOOOOOOOObe              '"=OMMMMWNEEEOOOOO,"=OEEEOO=,._
OOUUUIEEIOONNOIUbe.                "7OMMMMNNNNNWWEEEEOOOOOO"   "'.
EEBNNMMMNWNWWEEIMMNe.             __  7EMMMNNNNNWWWEEEEEEEOO.     " .
NNMMMMWWWMMMWEINMMMNn            "=BBEEEEMMMMMMMMNNNWWWEEOOOOO=._     .
                  http://furry.ao.net/~learfox/





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