Welcome Guest.   Make a donation to an author on the site April 25, 2014, 02:35:56 AM  *

Please login or register.
Or did you miss your validation email?


Login with username and password (forgot your password?)
Why not become a lifetime supporting member of the site with a one-time donation of any amount? Your donation entitles you to a ton of additional benefits, including access to exclusive discounts and downloads, the ability to enter monthly free software drawings, and a single non-expiring license key for all of our programs.


You must sign up here before you can post and access some areas of the site. Registration is totally free and confidential.
 
Free DonationCoder.com Member Kit: Submit Request.
   
   Forum Home   Thread Marks Chat! Downloads Search Login Register  
Pages: [1]   Go Down
  Reply  |  New Topic  |  Print  
Author Topic: IDEA: Universal Hand Tool for Scrolling  (Read 4399 times)
skywalka
Member
**
Posts: 253


View Profile Give some DonationCredits to this forum member
« on: August 12, 2007, 06:17:18 AM »

Hi guys.

I've been using Adobe Reader a lot lately.  Now, when I am in any application that I need to scroll within (eg web browser) I find myself instinctively trying to use the handtool featured in Adobe Reader.  Problem is the hand tool is not universal.  And that's why I'm here.  Why can't the handtool be available whenever left-clicking is not going to perform any other function?

Thanx 4 looking.
Logged
Nighted
Charter Honorary Member
***
Posts: 572


Meat Popsicle

View Profile WWW Give some DonationCredits to this forum member
« Reply #1 on: August 13, 2007, 05:04:37 PM »

Oh boy....you haven't heard of MouseImp?

Does just what you want. Make sure you use the proper DLL if you want Firefox functionality. Or you can use the Grab and Drag extension for Firefox.
« Last Edit: August 13, 2007, 05:06:41 PM by Nighted » Logged

I`m a firm believer in the philosophy of a ruling class, especially since I rule.
Nod5
Supporting Member
**
Posts: 716



View Profile Give some DonationCredits to this forum member
« Reply #2 on: August 14, 2007, 03:39:31 PM »

Here's an AHK script that gives basic, vertical hand tool functionality when holding CAPS + right mouse button + dragging. It should work for all programs that use mousewheel up/down to scroll up/down. Change the sensitivity through the xsens variable in the code if needed. It's very limited though: no horizontal scrolling, no drag hand icon. So if you already have a mouse with a scrollwheel then it's not so very useful. Still it lets you do long scrolls a bit faster and with more "flow" I think.

By the way, Easy Window Dragging (that I built this upon) is extremely useful - try it anyone who hasn't yet.


[copy or print]
; Easy Window Scrolling
; adapted from Easy Window Dragging
; http://www.autohotkey.com/docs/scripts/EasyWindowDrag.htm

CapsLock & RButton::
CoordMode, Mouse  ; Switch to screen/absolute coordinates.
MouseGetPos, EWD_MouseStartX, EWD_MouseStartY, EWD_MouseWin
WinGetPos, EWD_OriginalPosX, EWD_OriginalPosY,,, ahk_id %EWD_MouseWin%

SetTimer, EWD_WatchMouse, 10 ; Track the mouse as the user drags it.

xsens = 20     ;<------- change sensitivity here if needed
return

EWD_WatchMouse:
GetKeyState, EWD_RButtonState, RButton, P
if EWD_RButtonState = U  ; Button has been released, so drag is complete.
{
    SetTimer, EWD_WatchMouse, off
    return
}

; Otherwise, scroll to match the change in mouse coordinates
; caused by the user having dragged the mouse:
CoordMode, Mouse
MouseGetPos, EWD_MouseX, EWD_MouseY
ychange := EWD_MouseStartY - EWD_MouseY
SetWinDelay, -1   ; Makes the below move faster/smoother.
if ychange > %xsens%
 SendInput {WheelDown}
if ychange < -%xsens%
 SendInput {WheelUp}


EWD_MouseStartX := EWD_MouseX  ; Update for the next timer-call to this subroutine.
EWD_MouseStartY := EWD_MouseY
return
Logged
skywalka
Member
**
Posts: 253


View Profile Give some DonationCredits to this forum member
« Reply #3 on: August 15, 2007, 04:16:47 AM »

Oh boy....you haven't heard of MouseImp?

Does just what you want. Make sure you use the proper DLL if you want Firefox functionality. Or you can use the Grab and Drag extension for Firefox.
Thanx Nighted!

That's exactly what I'm looking for.
Here's an AHK script that gives basic, vertical hand tool functionality when holding CAPS + right mouse button + dragging. It should work for all programs that use mousewheel up/down to scroll up/down. Change the sensitivity through the xsens variable in the code if needed. It's very limited though: no horizontal scrolling, no drag hand icon. So if you already have a mouse with a scrollwheel then it's not so very useful. Still it lets you do long scrolls a bit faster and with more "flow" I think.

By the way, Easy Window Dragging (that I built this upon) is extremely useful - try it anyone who hasn't yet.
Nod5, that script is largely unresponsive for me.  Rather than troubleshoot, I'll stick with MouseImp for now.  But, thanx for taking the time to write post that.
Logged
Nod5
Supporting Member
**
Posts: 716



View Profile Give some DonationCredits to this forum member
« Reply #4 on: August 16, 2007, 05:52:20 PM »

Yes, I have to admit it's pretty dodgy after testing it again here.  Grin The right click context menu keeps popping up now and then even though it isn't supposed to. Not sure why. The script only took a few (fun) minutes to piece together from the Easy Window Dragging code so. I actually just recently discovered the Easy Window Dragging script and liked it a lot and had thought about expanding it somehow. So this was good practice. Other ways to expand it that I've since found really useful are: CAPS + middle mouse ---> minimize the window under the mouse pointer , CAPS + shift + move mouse = resize window under mouse pointer.
Logged
skywalka
Member
**
Posts: 253


View Profile Give some DonationCredits to this forum member
« Reply #5 on: August 17, 2007, 12:39:56 AM »

From my brief experience using the CAPS key for a hotkey isn't a good choice because you have to reset it.  Or is the CAPS key supposed to work without physically holding it down?  I tried using your script without holding the key down but it wouldn't work but maybe it did work & it was the unresponsive problem making it appear that it didn't...blah...blah...blah
Logged
Nod5
Supporting Member
**
Posts: 716



View Profile Give some DonationCredits to this forum member
« Reply #6 on: August 17, 2007, 01:25:05 PM »

But when you use CAPS as a hotkey combo in AHK then it isn't (by default) supposed to change the usual toggle mode of the CAPS button I think. So whatever you had it set to before stays set afterwards. And that's how it works when I try it at least. You can put ~ before a hotkey to force AHK to not block the native function though
Logged
skywalka
Member
**
Posts: 253


View Profile Give some DonationCredits to this forum member
« Reply #7 on: August 17, 2007, 02:46:06 PM »

Well, I felt pretty stupid asking that.  Halfway through typing up my post I thought there must be a better way to waste 2 minutes of my life...BUT...I just tried it out & you were spot on.  When you finish utilising the script's functionality it restore's the setting.

Thanx 4 the heads up.
Logged
Pages: [1]   Go Up
  Reply  |  New Topic  |  Print  
 
Jump to:  
   Forum Home   Thread Marks Chat! Downloads Search Login Register  

DonationCoder.com | About Us
DonationCoder.com Forum | Powered by SMF
[ Page time: 0.03s | Server load: 0 ]