Jump to content

Sky Slate Blueberry Blackcurrant Watermelon Strawberry Orange Banana Apple Emerald Chocolate
Photo

Accelerated Scrolling Script


  • Please log in to reply
94 replies to this topic
BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
What is accelerated scrolling?

Normally, when scrolling using the mouse wheel, the number of lines scrolled per notch or 'tick' of the wheel is constant. With accelerated scrolling, the faster you turn the wheel, the more lines you will scroll per tick. Therefore, if you turn the wheel slowly over 5 ticks, you may scroll 30 lines (default 6 lines per tick on Windows), but flicking the wheel very fast over the same five ticks may scroll 50 or 100 lines, depending on your speed.


How does it work?

Normally, one tick of the scroll wheel sends a single key signal to the application. This script works by sending extra key signals when you scroll quickly.


Why should I try it?

I think most people would benefit from using accelerated scrolling. On a daily basis, I see friends and colleagues attempting to scroll a large web page or a long list using the mouse wheel, and they flick the wheel very quickly, many, many times. Not only is that frustratingly slow, but it may contribute to Repetitive Stain Injury if done often enough.

Accelerated scrolling is very intuitive because it's obvious that slow scrolling means the user is reading line-by-line, while fast scrolling means the user is trying to traverse a long distance.

For people that already use acceleration in another form, using this AHK script means you can easily take it to any other computer, without having to install specific mouse software, and are not tied to a particular brand of mouse.


Features

Unlike some special scrolling features like cruise control and autoscroll, this works on any application or control that responds to the mouse wheel. That even includes things like Sliders (like the volume control). See also, "Will it affect my games?"

You can turn on tooltips, which will indicate next to your cursor how much acceleration is applied while you're scrolling fast. Turn this on by editing the source code.

Finally, I've also added a unique boost feature. If you keep turning the scroll wheel without stopping, after a set distance, the acceleration factor will gradually increase so that you can scroll faster and faster! The delay between scrolls to maintain boost, the distance you travel before boost begins, and the maximum boost speed can all be customized in the source.


Why did you write it?

I had a Microsoft mouse for a very long time, and the mouse software, IntelliPoint, had an accelerated scrolling option, which I always found extremely useful. Then, I got a Logitech mouse which is a great deal better, BUT the IntelliPoint software refused to accelerate with it. Also, the Logitech software SetPoint did not allow me to use the feature, even though people with other expensive Logitech mice could access it.

In both cases, it appears that the software reads the product ID of the connected hardware, and refuses to enable the special features unless it's deemed 'worthy'. Thanks a lot, Logitech and Microsoft, for discriminating against me!

So, I asked in the Logitech Forums and got a response in the form of a very simple AutoHotKey script... And that's how I learned about AHK.


Will it affect my games?

Yes, the extra scroll signals will be sent to games, but whether they have any effect is another matter.

For instance, in-game windows with scrollbars should benefit from acceleration, but when changing weapons in games like Half-Life 2, the game will wait for a brief period before responding to the input again. This means weapon-switching with the scroll wheel is not affected, which is good! And if it does cause problems, simply suspend or exit the script (see key bindings).


It's too fast! How can I adjust it?

The actual number of lines scrolled per tick depends on the application, but this is often determined by the scroll wheel setting in Windows.

If you open up Mouse from the Control Panel, and go to the Wheel tab, you should have an option to set the number of lines scrolled per tick. If you have other mouse drivers or touchpad software installed, these options may be in a different place. The default is 6. I would recommend 4.

After that, it's just a matter of getting used to it, and learning to scroll slowly when reading.


Key Bindings

Win + WheelUp: disable (and repeat to enable again)
Win + WheelDown: exit (and display a tooltip to inform you that it has terminated).


Download

Accelerated Scrolling 1.3.zip

This archive contains:
- The source file (you need AutoHotKey installed to run this)
- The compiled exe (the password is 'ahk')
- A text file 'Lines.txt' containing 10,000 lines of 100x100 triangles, to test wheel acceleration.

The executable is password-protected so the archive can get through proxies, such as company firewalls, that scan files for executables.

ruespe
  • Members
  • 567 posts
  • Last active: Dec 01 2014 07:59 PM
  • Joined: 17 Jun 2008
Thank you very much for sharing. I like it. Small, good documented, clearly described.

gargoyle888
  • Members
  • 27 posts
  • Last active: Nov 10 2015 03:56 PM
  • Joined: 10 Jan 2009

The ZIP file is password-protected so the archive can get through proxies, such as company firewalls, that scan files for executables.[/size][/b]


Unfortunately, the password protected zip is exactly what alerts the firewall here that something is trying to sneak through.

This sounds like a useful utility, I'll download it at home and give it a try.

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009

Unfortunately, the password protected zip is exactly what alerts the firewall here that something is trying to sneak through.


Wow... That's tight! I'm guessing if they parent the Internet like that, they'll also be watching over unauthorized executables and scripts anyway. Still, I hope you're able to try it at home and get it running if you find it useful. :)

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
And, @ruespe, thanks for the approval.

And to everyone, Merry Christmas. :)

kli6891
  • Members
  • 46 posts
  • Last active: Nov 24 2012 08:12 PM
  • Joined: 01 Aug 2009
Wow, I love this script, thanks a lot!

bitflow
  • Members
  • 5 posts
  • Last active: Dec 04 2011 07:48 PM
  • Joined: 08 Jan 2010
Nice script, thanks, I like this behavior far better than Microsoft's IntelliPoint accelerated scrolling.

Despite enjoying very fast scrolling, I found your suggestion for the Control Panel / Mouse / Wheel / Scrolling / "The following number of lines at a time" setting of 4 to produce unusably fast scrolling on Windows 7 with Microsoft Wireless IntelliMouse Explorer 2.0 and just Windows built-in driver (IntelliPoint not/never installed).

I found a setting of 1 to work beautifully. It allows readable scrolling when rolling wheel at a gentle pace and blazingly fast scrolling when flung when retaining your default timeout:500 / boost:30 / limit:60.

Thanks for putting this together. Beautiful.

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
Yes, I have one of those mice and I understand, because the scroll wheel rotation is completely smooth, and the number of ticks per revolution is very high compared to most mice. Still, isn't it great that you can adjust this from Windows and it simply multiplies? That's the way it should be - easy. ;)

I see this is your first post. Did you find this script from Google or was it just a coincidence? Anyway, I'm glad you approve!

bitflow
  • Members
  • 5 posts
  • Last active: Dec 04 2011 07:48 PM
  • Joined: 08 Jan 2010
Yes, searched Google for autohotkey scroll faster and landed here.

I've been using ahk for years, but your elegantly documented script prompted my first post.

W()RmS
  • Members
  • 9 posts
  • Last active: Feb 26 2011 02:00 PM
  • Joined: 21 Sep 2009
is there anyway to make this have a effect in games like in HL2?

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
@bitflow Well thanks for joining up to say so. :) I started using AHK about half a year ago and the reason for using it was... well, it's all in the first post! Despite not knowing much about AHK, I certainly believe in good documentation.

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
@W()RmS What exactly do you want to do in HL2? If you want to access a particular weapon quickly, assign it to a hotkey through the game options. If you use the mousewheel for something else, you may wish to test the results first. If you definitely want to send a series of scroll signals and want them all to be treated separately, you may be able to get the desired result by experimenting with the key repeat rate (check the help file for SetKeyDelay).

W()RmS
  • Members
  • 9 posts
  • Last active: Feb 26 2011 02:00 PM
  • Joined: 21 Sep 2009
BoffinbraiN
actaily it is because my mousewheel is half broken
and then i need something to make it scrol fast for when i'm useing the Physgun in Garrysmod

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
Oh dear! Well I experimented with SetMouseDelay but it didn't work for me.

You might need something like an auto-fire script that you modify to trigger the mouse-wheel rather than left mouse button. You can find a few of those in the forums. Also, see if the physgun's alternative firing modes can be reassigned via the console.

Otherwise... really, I'd recommend getting a new mouse. ;) They're not expensive.

BoffinbraiN
  • Members
  • 114 posts
  • Last active: Jun 18 2013 07:03 PM
  • Joined: 16 Nov 2009
Just thought I'd post a link to this thread as well, since it's scrollwheel-related. A script for performing 'cruise control' using the scrollwheel when the mouse software provides no such option.