[MonoDevelop] How to Change the Mouse Cursor?

Jacek Ruzyczka ruzyczka at versanet.de
Mon Sep 10 15:37:05 EDT 2007

> this.GdkWindow.Cursor = new Gdk.Cursor(Gdk.CursorType.Watch); where
> "this" is the window whose cursor type you want to change.
> Gtk# related questions are probably better asked on the gtk-sharp
> mailing list - http://lists.ximian.com/mailman/listinfo/gtk-sharp-list
Thanks...I've just solved my problem by defining the following property:

		///true, if this form is locked and the cursor has the
		///shape of an hourglass (Windows) or watch (Linux).
		public bool Hourglass {

			set {
				if (value == true) {
					this.GdkWindow.Cursor = new Cursor
				else {
					this.GdkWindow.Cursor = new Cursor

You can use it for all Gtk objects providing a GdkWindow property.


More information about the Monodevelop-list mailing list