how to prevent delayed wheel scrolling in a RichTextBox

59 Views Asked by At

When you scroll using the mouse wheel inside a RichTextBox the scrolling continues for a little while after you stop turning the wheel. I want it to stop as soon as the wheel stops turning instead.
What's the way to go to implement this behaviour?

It doesn't look like there is any related property on the control.

I plan on using it as a Console-like read-only output, so it has nothing fancy attached so far: just a black-background Form-Wide box.

--SOLUTION--
Overriding WndProc()'s WM_MOUSEWHEEL case neatly did the trick,
as was pointed out in the comments below.

Just be sure to use bitshift to test the IntPtr sign

0

There are 0 best solutions below