R – Change hotspot of mouse cursor on a web page

cursor

I would like to change the hotspot of a mouse pointer, which we've changed the icon using a .cur file, to be in the bottom right of the image, rather then the top left.

Pretty much like an inverted arrow cursor, the designers/boss have come up with a nice design which almost requires this.

Is it possible to change the hotspot of a mouse cursor on a web page?

Best Answer

I have not tested it, got it from developer.mozilla.org:

Support for the CSS3 syntax for cursor values got added in Gecko 1.8beta3; it therefore works in Firefox 1.5. It allows specifying the coordinates of the cursor's hotspot, which will be clamped to the boundaries of the cursor image. If none are specified, the coordinates of the hotspot are read from the file itself (for CUR and XBM files) or are set to the top left corner of the image. An example of the CSS3 syntax is:

cursor: url(foo.png) 4 12, auto;

Link to CCS3 cursor