[MonoDevelop] How to Change the Mouse Cursor?

Adam Tauno Williams adamtaunowilliams at gmail.com
Mon Sep 10 06:26:51 EDT 2007

> I am now in the troublesome situation to use custom cursors in my application. 
> I have already found out that I need to use the Gdk.Cursor and Gdk.CursorType 
> class...but how shall I get the cursor instance associated with my 
> application resp. window conveniently? Even if there's no way to do this in 
> MD directly, there should be some "hand-coded" .NET solution available. 
> The "default solution", however (see: 
> http://www.geekpedia.com/Question37_How-do-I-change-the-mouse-cursor-to-a-hourglass.html), 
> turned out to be unusable in Mono & Gtk#. :-(

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

Adam Tauno Williams, Network & Systems Administrator
Consultant - http://www.whitemiceconsulting.com
Developer - http://www.opengroupware.org

More information about the Monodevelop-list mailing list