Q
Q
qwert212021-12-25 10:50:58
C++ / C#
qwert21, 2021-12-25 10:50:58

How to capture the cursor in a window?

How to capture the cursor in the window (in the sense of restricting its movement within the window)?
I know that there is a function in WinApi ClipCursor. But maybe there is something better/more convenient in Builder (Embarcadero RAD C++ Builder 10.4)?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Ananiev, 2021-12-25
@SaNNy32

Make the app full screen. Otherwise, you will have to put low-level hooks on mouse movement to limit its movement (bad practice, it is better not to do this)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question