Magnifier WebCursor?

I’d like the cursor when hovering above a WebCanvas to be a magnifying glass with a + when the command key is down, a magnifying glass with a - when the shift key is also pressed, and an ordinary arrow pointer otherwise. Such cursors do not appear on the WebCursors list, so it looks like I would need to do a custom cursor somehow. Anyone know how to do this?

List of CSS cursors

Thanks, Tim. Yeah, zoom-in and zoom-out is what I want. So how do I assign these to the WebCanvas cursor? These don’t appear to be on the WebCursor list of defined cursors.


I’m sorry I am so dense. I know Xojo, but not a lot of CSS or HTML (using Xojo partly to avoid all of that). Do I have to insert some CSS or HTML code somewhere, somehow? I am basically a newbie with regard to these things. Thanks for any help.

It’s a little bit of JavaScript/CSS manipulation.

I just tried to implement a demo for you, but Xojo uses KeyPressed which doesn’t trigger until a key is released. You would have to use WebSDK to create a custom control that can track KeyDown for you. If you were to make an event handler in ExecuteJavascript it gets sent as an anonymous function and cannot be removed (removeEventListener)

I can see if I can get to it for you, but it might not be right away.
I am available privately by email if this is a priority issue

Dear Tim, thank you so much for your help. I am curious about how to do it, but this is not a hugely urgent item (I have plenty of other things to work on). I really appreciate your thoughts on this, though.

Dear Tim, Thank you for your help and effort. I’ve decided that this is not the right user interface for this project anyway, so don’t waste you time constructing an example. I really appreciate your willingness to help, though.