AutoHotkey Community

It is currently May 27th, 2012, 12:23 pm

All times are UTC [ DST ]




Post new topic Reply to topic  [ 71 posts ]  Go to page Previous  1, 2, 3, 4, 5
Author Message
 Post subject:
PostPosted: November 13th, 2010, 8:57 pm 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
This all depends on speed.
There is no functionality to find out if you are typing a word or double pressing the hotkey.

You can change the timer, depends how fast you can double press a key. This looks to be quite okay.
You can also change the default in the function to change it for all scripts.
Code:
~m::RapidHotkey("{Raw}_m_", 2,0.08)


Second one should be:
Code:
~F9::RapidHotkey("^v""{Raw}_F9_",1)

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 13th, 2010, 9:18 pm 
Offline

Joined: August 4th, 2009, 3:58 am
Posts: 373
Thanks for the tips.

Is there specific how-to documentation I could read somewhere or just what is posted throughout this thread?

_________________
"A person who has never made a mistake is a person who has never tried anything new." ~Albert Einstein
"Any fool can make things larger and more complex. It takes a touch of genius...to move in the opposite direction." ~Albert Einstein


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 13th, 2010, 9:22 pm 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
There are no docs, just ask if need help :)

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 13th, 2010, 10:55 pm 
Offline

Joined: August 4th, 2009, 3:58 am
Posts: 373
HotKeyIt wrote:
There are no docs, just ask if need help :)

OK, thanks.


BTW, in case you have not already noticed them, I am wondering if you might be able/willing to look at a couple of threads with questions I have posted. In making that request, I certainly do not want to imply that the comments already posted there by others have been lacking. On the contrary, they have been most helpful. However, having written this RapidHotKey function, you are obviously extremely knowledgeable in this area of auto-replacement and perhaps you may have insights or suggestions which have not yet been addressed.

On a personal note, the reason for my keen interested in these topics is that I am a quadriplegic with paralyzed fingers so using a keyboard is very difficult and slow. As a result, every keystroke I can eliminate is a big help and every two- or three-key entry (Shift+key, Ctrl+Alt+key, etc) which can be done with a single key (even though it may involve a double-press of that key) saves a lot of time and energy. Consequently, I'm always on the lookout for the best/easiest ways to abreviate as many words, phrases, and processes as possible.

The biggest issue right now is a pesky problem described here: Auto-replace fails if triggered by another auto-replace

The second is a question with several parts, some of which are pretty "out-there," but all of which would be helpful. It is here: Possible hotkey variations.

Finally, someone suggested I take a look here: Chording keyboard: strings sent at key combinations
It looks like it has potential also but do you think there might be overlap with RapidHotKey?

Thanks for the help – any and all input is greatly appreciated!

Thanks

PS I know you are very familiar with this, but I am including the link here, simply as a reference for myself: Morse: find hotkey press-and-hold patterns

_________________
"A person who has never made a mistake is a person who has never tried anything new." ~Albert Einstein
"Any fool can make things larger and more complex. It takes a touch of genius...to move in the opposite direction." ~Albert Einstein


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 14th, 2010, 12:57 am 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
Have you seen HotKeyString :?:

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 14th, 2010, 1:45 am 
Offline

Joined: August 4th, 2009, 3:58 am
Posts: 373
HotKeyIt wrote:
Have you seen HotKeyString :?:

Not before now, but I just glanced at it and it looks very intriguing.


One question I have though is based on this statement:
HotKeyIt* wrote:
hotkeystrings get activated by pressing the sequence of characters while keeping one of previous keys down.
I assume two hands (or at least two keys) are always involved. Is that correct? If so, is there a way to apply Sticky Keys?

Thanks


*From HotKeyString() - Do you need more hotkeys?

_________________
"A person who has never made a mistake is a person who has never tried anything new." ~Albert Einstein
"Any fool can make things larger and more complex. It takes a touch of genius...to move in the opposite direction." ~Albert Einstein


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: November 14th, 2010, 4:05 am 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
dsavant wrote:
I assume two hands (or at least two keys) are always involved. Is that correct?
Yes
Quote:
If so, is there a way to apply Sticky Keys?
That won't be easy.

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
 Post subject: Re: RapidHotkey()
PostPosted: June 4th, 2011, 2:24 am 
Offline

Joined: August 4th, 2009, 3:58 am
Posts: 373
HotKeyIt wrote:
Syntax:
Code:
Key::RapidHotkey("keystrokes" ;Enter keystrokes here. E.g.: "^o"
           , times          ;optional. How often the key must be pressed to execute. E.g.: 3

Hello,

This RapidHotKey is really cool. Someone just pointed me here and I'm looking forward to using it. Thanks for putting it together!

This is a small point but just FYI, the Syntax info in the first code box says:
Code:
;How often the key must be pressed to execute. E.g.: 3

in describing what I think is the number of times the key must be pressed. If that is correct, then it might be better (or at least more accurate) to say:

Code:
;The number of times the key must be pressed to execute.  E.g.: 3


I was confused because, as I understand it, the word "often" refers to frequency (i.e. how long or short the interval is between some series of events).

If my interpretation is wrong, please forgive me because I just started looking through the string.

Cheers!

_________________
"A person who has never made a mistake is a person who has never tried anything new." ~Albert Einstein
"Any fool can make things larger and more complex. It takes a touch of genius...to move in the opposite direction." ~Albert Einstein


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: June 4th, 2011, 9:29 am 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
Thanks, I have changed that ;)

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: August 1st, 2011, 12:56 am 
Offline

Joined: August 4th, 2009, 3:58 am
Posts: 373
Would you mind giving me an example for a very basic script to help me get going on this? I really appreciate it. Here's the reason I ask (from another thread):
Quote:
[Note: I have come to realize that I can go through the AHK docs 3-4 times and still not understand a concept. However, if I have an example or two in which I can tweak different parts to see what happens, then working backwards with modifications usually gets me where I need to go. Once I have gone through that process, reading the docs again makes a lot more sense and helps fill in whatever I may still be missing.]


For example, suppose I wanted to be able to press Numpad8 three times rapidly to trigger the following code:
Code:
WinGetPos, X, Y, W, H, A   ;   
w := w/2   ;   
MouseMove, w, 2   ;   
return


Can you show me how that would be constructed? And then, a couple of variations:
• press four times instead of three
• slightly increase the pressing rate required to run the script

Thanks

_________________
"A person who has never made a mistake is a person who has never tried anything new." ~Albert Einstein
"Any fool can make things larger and more complex. It takes a touch of genius...to move in the opposite direction." ~Albert Einstein


Report this post
Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: August 1st, 2011, 5:20 am 
Offline

Joined: June 18th, 2008, 8:36 am
Posts: 4923
Location: AHK Forum
Try this, pressing once will send Numpad8, 2 and 3 times will launch Labels.
Code:
#Include RapidHotkey.ahk

$Numpad8::RapidHotkey("{NumPad8}""Numpad81""NumPad82",1,0.15,"0""1""1")

Numpad81:
   MsgBox Pressed Numpad twice
Return
   
Numpad82:
WinGetPos, X, Y, W, H, A   ;   
w := w/2   ;   
MouseMove, w, 2   ;   
return

_________________
AHK_H (2alpha) AHF TT _Struct WatchDir Yaml _Input ObjTree RapidHotkey DynaRun :wink:


Report this post
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 71 posts ]  Go to page Previous  1, 2, 3, 4, 5

All times are UTC [ DST ]


Who is online

Users browsing this forum: Bon, Google Feedfetcher, SKAN and 5 guests


You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Group