I just got a couple of the new TypeMatrix keyboards. I’m friends with the owners, and years ago I made their promo video:
The new version is great, but some of the keys have been switched around, and I’m very picky. Luckily, autohotkey allows you to remap keys very easily (I always have a script running anyway). AHK can do tons of amazing things, but for our purposes we’re just going to do some simple remapping. The basics are:
- Download and install AHK
- Create a new text file (with notepad or whatever), and add the code below. Save it with the extension “.ahk”
- Double-click on the .ahk file you just saved, to launch it
It may seem confusing at first, because AHK is not a program you launch. You simply install it, and then launch each script individually. You can also create .exe files so you don’t need AHK installed, but I prefer to keep them .ahk so I can keep editing them at any time easily (I change my mind a lot).
Okay, so what’s the code? For starters, I really wanted the numpad Enter key on the right side where it used to be. They switched that key to CTRL. So to swap it back, all you need is this line:
RControl::NumpadEnter
The first key is the old key you want to change, the second is what you want it to be. Pretty simple. But now there’s no right CTRL key, so we’ll map that to the “www” key:
Browser_Home::RControl
That’s it! Be sure to put them on separate lines, save the file, and then launch the script. I recommend adding this script to your Windows startup folder.
For users of TypeMatrix, there are a couple other things you may be interested in. First, their copy/paste keys (this mostly applies to Dvorak typists like myself). They work fine most of the time, but some applications don’t like them. The reason for this, straight from TM:
For the record, here is how cut, copy and paste are implemented on TypeMatrix keyboards:
Cut: Shift + Del
Copy: Ctrl + Ins
Paste: Shift + Ins
They do this because those commands are more universal, whether you’re on Windows, Mac, or Linux. But if you’re always on one OS, you can safely remap them. For Windows, if we remap some keys to “CTRL-C” it should work perfectly in every app. Since the “shuffle” key is hardwired in the keyboard, we can’t reprogram it. We’ll move the keys to the left and use play and app instead:
^Media_Play_Pause::^c
^AppsKey::^v ; Keep this HIGHER in script than regular AppsKey!
The ^ means CTRL in the above code. So hitting CTRL-play = COPY, and CTRL-app = PASTE. The keys are all next to each other, which I also like. For CUT, I just use the normal CTRL-X since it’s not that far away, and can still be reached with only your left hand. Of course now the keys are labelled wrong, so don’t get confused. Also, the semi-colon in the code means it’s a comment, so you can leave that part in if you want.
Second, the shuffle key. I LOVE that key, but unfortunately it seems to be a bit buggy on the new version. We’ll just ignore their shuffle key and make our own. Again, we can’t reprogram the actual shuffle key, so we’ll use app instead:
Launch_App2::!Tab ;Calculator button
AppsKey::!Tab
Now both the CALC key and the APP key will shuffle (alt-tab one time). This only switches between two windows. If you hold it, it will keep shuffling back and forth. It’s super fast and that’s all I want. But some may prefer the TM shuffle key, which lets you hold it down to go 2, 3, 4 windows back, etc.
I’ve remapped other keys, but they may not be useful for most people. For instance:
Launch_Mail::^!+Space
Volume_Down::^!+Left
Volume_Up::^!+Right
Those are global hotkeys for VLC media player. If I hit CTRL-ALT-SHIFT-spacebar, my video pauses, even if it’s not in focus (I watch on a second monitor). So now with this new code, the MAIL key pauses, and the Volume keys skip forward and back. You’ll also need to set those within VLC for it to work.
If you’d like to remap the “desktop” key (this key sends the command WINDOWS-D), you can use this code (change the second part to whatever you want):
#d::RControl
However, note that this will disable the WINDOWS-D command, so only do this if you don’t use that shortcut.
This should give you a glimpse of how powerful autohotkey is, and this is really basic stuff. For more info, you can see a List of hotkeys, or read their tutorial on Key Remapping. I will update this post with any new commands people ask for. Have fun and let me know any other tricks in the comments!
I just bought a typematrix keyboard and am very thankful for your ahk guide here. However, I don’t seem to be able to reprogram the mail launch key by calling it Launch_Mail as you did above. Is a different code now in use? Any ideas?
I don’t see why it would be different, Launch_Mail is a Windows setting, so TM would have to release its own software to do it differently. You don’t have a typo or some other line that conflicts? Have you tried just setting:
Launch_Mail::1
…and then opening Notepad just to see if it works? If it types “1”, then the problem is with what you’re trying to set it to. I think there’s a way to target the actual keycode if you have to. Check the AHK site or ask on the forum.
@Tommy Gun
Figured it out; it worked by targeting the key’s scan code, as you suggested–
SC16C:
For the record, I think things may have also been affected by the fact that I was running Micro$oft Intellitype Pro (so much for the “intelli-” part…).
Thanks!
Hi, I’m trying yout tutorial. very nice work!!
But I am trying to modify the cut, copy, paste keys used with function and it doesn’t work 🙁
Any idea?
Is there a way to get each key code easily? I’m looking for the special keys ie shuffle, desktop, and the fn keys.
Thanks