[Mono-list] Change Cursor in Gtk.Window
Eskil Bylund
eskil.bylund at gmail.com
Tue Aug 28 04:53:10 EDT 2007
> I am having a lot of trouble trying to figure out how to do this in a Gtk
> Window. I have searched google and looked through the documentation and seen
> that the Gtk.Window class doesn't have a Cursor associated with it. The
> closest I found was:
>
> this.GdkWindow.Cursor = new Gdk.Cursor(Gdk.CursorType.Watch)
>
Using the Cursor property on the Gdk.Window is the correct way to do
it. Note that the Gdk.Window won't be created until the window has
been shown or a call to Realize() has been made.
Window w = new Window("Cursor Test");
w.Show();//w.Realize();
w.GdkWindow.Cursor = new Gdk.Cursor(Gdk.CursorType.Watch);
Eskil
More information about the Mono-list
mailing list