Feature Idea: Mouse Input Grab in Window

Almas Baimagambetov almaslvl at gmail.com
Thu Dec 17 17:17:24 UTC 2020


Johan Vos and I had a quick chat about this feature and he suggested it
might be a good idea to start a discussion.

*Use case:* 3D games or 3D modelling tools, where the application "grabs"
(gets exclusive control of) the mouse and moving the mouse doesn't move the

*Feature:* Allow to confine the mouse to a window. The cursor is centered
on the window and does not move/leave the window, whilst all mouse move
events are reported normally. Since this is already provided by native code
(e.g. Windows API), an implementation of this would probably be a wrapper,
similar to the wrapper that the SDL library provides:

*Possible high-level API:*

Window window = ...


I've tried working around this by using Robot API, but it isn't quite the

Kind regards, Almas

More information about the openjfx-dev mailing list