Click here to Skip to main content
15,890,282 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
We need to reduce touchpad cursor speed in certain state in our application. So, i was planning that when the application enter a specific state, we will change touchpad cursor speed at run time by using some Windows API. And when coming out of the specific state, revert the touchpad cursor speed to original value.

However, i did not find any Windows API to change touchpad 'Cursor speed' dynamically without restarting. I found API to change mouse speed (SystemParametersInfo). But this API only changes the mouse cursor speed. It does not change touchpad cursor speed.

I tried changing the below registry. But the problem with changing registry is that touchpad cursor speed gets updated only after system restart. I need an API to change touchpad cursor speed without restarting system (similar to how we can change mouse speed using SystemParametersInfo)

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\PrecisionTouchPad\CursorSpeed

Any suggestions in this regard will be really very helpful.

What I have tried:

I tried changing the below registry. But the problem with changing registry is that touchpad cursor speed gets updated only after system restart. I need an API to change touchpad cursor speed without restarting system (similar to how we can change mouse speed using SystemParametersInfo)

HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\PrecisionTouchPad\CursorSpeed
Posted
Updated 19-Jul-18 9:45am
Comments
Dave Kreskowiak 19-Jul-18 16:37pm    
This is a bad idea. Changing the cursor speed and acceleration affects the mouse speed in EVERY application and window, not just your application.

That's a really bad change to make.
AroraSaurabh 19-Jul-18 22:52pm    
Thanks for your feedback.
The application runs in a closed environment and no other Windows application can be accessed when our application is running. And also, within our application we want to reduce the cursor speed only for a specific state of the application and then revert to original when we come out.

The same is possible with mouse (using SystemParametersInfo API). However with touchpad, i don't find a way to do that.
Richard MacCutchan 20-Jul-18 3:53am    
You already posted this in the C++ forum; please do not crosspost.

1 solution

Microsoft seems pretty clear about what they expect from the experience; which is probably why they make it difficult to change "Windows Settings" on the fly.

One usually uses "input events" to "manage" input devices. When you detect movement, you can affect speed then by manipulating the mouse / cursor coordinates.

Handle pointer input - UWP app developer | Microsoft Docs[^]
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900