Skip to content

native/macos: Added support for CursorIcon::NESWResize and CursorIcon::NWSEResize#625

Open
Pewnack wants to merge 1 commit intonot-fl3:masterfrom
Pewnack:macos_cursoricon
Open

native/macos: Added support for CursorIcon::NESWResize and CursorIcon::NWSEResize#625
Pewnack wants to merge 1 commit intonot-fl3:masterfrom
Pewnack:macos_cursoricon

Conversation

@Pewnack
Copy link
Copy Markdown
Contributor

@Pewnack Pewnack commented Apr 25, 2026

On macOS cursor icons CursorIcon::NESWResize and CursorIcon::NWSEResize were not supported. Added support for it.
These cursor icons are not officially supported, but there is an undocumented API for it.

The code for it was basically already there. In apple_util.rs there already is a function load_undocumented_cursor. This function was not entirely correct though and caused a panic. It needed only a small change to make it work. It now tries to set the undocumented cursor and falls back to the default cursor if it doesn't exist.

Cursor icons can be tested with miniquad example program mouse_cursor:

cargo run --example mouse_cursor

Press keys q to set NESWResize or w to set the NWSEResize icon.

Closes not-fl3/macroquad#1030

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CursorIcon::NESWResize and CursorIcon::NWSEResize work on Macos with set_mouse_cursor

1 participant