AutoHotkey

Sunday 15 April 2007This is close to 18 years old. Be careful.

One problem I find with laptops: the keyboards have been modified to fit into the small space available. Usually this means moving around the “extra” keys so that the letters and numbers can be full size. And usually, one or more of these compromises seems really stupid to me.

For example, my current Toshiba laptop has a bottom row of keys like this:

[Ctrl][Fn][Alt][`~][     Space    ][Ins][Del][Alt]

What!? Ins, but no right Ctrl? Are these people crazy? Who uses Ins any more?

To fix this problem, I found AutoHotkey, one of those single-minded Windows utilities which takes a seemingly small domain and makes the most of it. AutoHotkey remaps keys and key sequences. With it, I could remap the Ins key to mean Ctrl, fixing my keyboard.

I also found that my left thumb was hurting more than my other digits, and that my Alt-Tab habit was aggravating it. I would tuck my left thumb under to the left Alt key, and hit the Tab key with my ring finger. Very quick, but also contorted. With AutoHotkey, I remapped that key combination to not do Alt-Tab, breaking me of the habit. Now I use the right Alt key with my right hand, press the tab key with my left hand, and my discomfort is much reduced.

The AutoHotkey scripting language can do many things, my little script only scratches the surface:

Ins::Ctrl
RAlt & Tab::AltTab
RAlt & CapsLock::ShiftAltTab
LAlt & Tab::MsgBox Boo!

This says:

  • Ins should be treated as Ctrl
  • Right-Alt and Tab should do an Alt-Tab
  • Right-Alt and CapsLock should do a Shift-Alt-Tab (rotate applications backwards)
  • Left-Alt and Tab should put up a message box that says “Boo!”

There’s lots more that AutoHotkey can do that I haven’t even begun to explore, like sending Windows messages, manipulating windows, and so on. But the few things I need it to do, it does well.

Comments

[gravatar]
I used it to give iTunes and MediaMonkey global windows hotkeys (before I switched to foobar2000, anyway).
[gravatar]
Couldn't agree more about the annoyances of keys moving around.

No right Ctrl key seems to be an annoying trend on laptops these days. Do those keyboard designers never hit Ctrl-P? Are they stuck in a world where keyboard shortcuts are illegal so as to keep productivity down to a minimum? *sigh*

Moving ~ around seems to be a fun game with keyboard designers, too. With three desktop keyboards and a laptop keyboard in my view right now, the tilde is in three different locations. Clearly an anti-trust violation right there, since it's preventing ease of use of a very handy Bourne-shell shortcut.

And if people don't stop moving the Escape key around, there's going to be trouble! Make up your minds about whether it goes next to F1 or under it. I'm tired of missing that key and hitting F1 just because I changed computers and this particular keyboard has moved it.
[gravatar]
Who uses Ins? People who want to switch modes in Vim safely, that's who.

Microsoft can take my Ins key when they pry it from my clammy, moon-tanned hands.
[gravatar]
Last time I bought a laptop I ignored about half of those on offer who though Fn was an acceptable key for the bottom left position.
[gravatar]
I can't stand the new keyboards with no Insert key! Some of them even eliminate it by making the delete key take up both spaces... WTF?!? Are they trying to save the cost of one extra switch?

Am I the only person on earth who still uses overwrite on a regular basis? Or perhaps still uses the old DOS copy(ctrl + ins), cut(shift + del), & paste(shift + ins) commands? Ok, fine, the answer to that one may be yes, but still... LEAVE THE INSERT KEY ALONE!!
[gravatar]
Dan Strychalski 5:24 AM on 3 Jan 2021
Throughout the nineteen-eighties, IBM manipulated the industry and the media to ensure that people would become dependent on the many non-main-block keys originally present only on IBM's keyboards.

Now we see the results.

I feel extraordinarily lucky to have started with an Apple II clone and WordStar, to have learned why every respectable computer keyboard has Ctrl (which made me swear never to accept the Mac or Windows), to have been able to WordStar-ize the function-key-dependent word processor my employer forced on me, and to now have Linux and the WordStar-like Joe's Own Editor (joe).

Note that after customizing WordPerfect so my hands never had to leave the typing block, I had Ctrl-plus-letter-key keystrokes left over to bind to any function I wanted. We have all been had.

Add a comment:

Ignore this:
Leave this empty:
Name is required. Either email or web are required. Email won't be displayed and I won't spam you. Your web site won't be indexed by search engines.
Don't put anything here:
Leave this empty:
Comment text is Markdown.