Add wheel_scroll_min_lines to set the minimum scrolling lines - #4710
Conversation
|
Is there a chance that yoffset is 0? if (yoffset != 0) {
const int min_lines = ...
}I saw that it is already checked for zero and returned. if (yoffset == 0.0) return; |
|
currently, no. but that might change in the future, and I want to be |
|
Nevermind, I missed For example, scrolling is disabled when Thank you. This is always good to check. |
|
I noticed that Although I need this, I don't want to introduce effects that do not match the design. |
|
It doesn't matter when grabbed. When the mouse is grabbed yoffset is not However, for consistency in case in the future I design a new mouse |
Under macOS, some mice have a scroll wheel that starts at yoffset 0.100...1 (with default multiplier it's 0.500..5), resulting in one line per click with a slow scroll.
If a larger multiplier is set, the acceleration is too fast.
Add a new option
wheel_scroll_min_linesto set the minimum number of scrolling lines.If the number is positive, the minimum number of lines will be taken. (Obviously acceleration does not take effect when the minimum number is not reached.)
If it is negative, the number of lines is always added and the acceleration remains the same and takes effect immediately.
For me personally, I use the default
wheel_scroll_multiplier 5.0, andwheel_scroll_min_lines -2.Please review, thank you.