?? Setting Hotspot on Custom Cursor ??

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

This is driving me nuts -- I create a cursor at runtime from an Image. The
problem is that the Hotspot is always the center of the resulting cursor.
There is a Hotspot property on the Cursor class but it's read only.

Is there anyway to set the Hotspot of a dynamically created cursor?

Thanks!
 
The basic problem is that you do not actually have a cursor. You have an
icon. The hotspot of an icon is always in the middle and you can't do
anything about that. The solution is a hack that I am particularly proud
of - make your icon big enough so that its middle hotspot resides where
you'd like to have the custom cursor's be.

For example, assume that you want to make a custom cursor from a standard
arrow. Define your actual custom icon to be big enough so that the arrow's
hot spot is in the middle of the icon. When the custom cursor draws, the
user will only see your arrow and the remaining 3/4's is all blank.
 
Well, I think I *do* have a cursor, not an icon. I am calling the Cursor's
c'tor. What's more, since when do icons have hotspots?

I appreciate the response but I was looking for less of a hack.
 
Back
Top