Using An Apple Keyboard With Windows 7

June 10th, 2012 | Posted by Stephane in Geekery

Now personally, I’m not exactly a big Apple fan, especially since some of their hardware tends to be a little overpriced. But when I started looking for a nice keyboard to go with my new desktop build, I quickly realized that my desires aligned quite nicely with those of our late pomaceous demigod, The Almighty Steve.

The Illusion of Choice

My requirements in a keyboard are simple enough, really. Sorted by importance, they go a little like this:

  • Low-profile chiclet keys
  • Wired
  • Comfortable to type on
  • Good build quality
  • Not horribly ugly to look at

… and that’s about it. No crazy rainbow LED backlighting, no built-in LCD that tells you the weather and suggests going outside for some exercise, no customizable command macros, just a simple keyboard I can write code and game with.

Apple Keyboard Side View

I’m all about efficiency, so I’ve come to love laptop-style chiclet keys than only need to be depressed a few millimeters. I feel like I’m wasting so much energy when I’m pushing an old clunky mechanical key down into the Earth’s mantle just to get one lousy letter out of it. And forget this wireless nonsense of pairing devices and changing batteries all the time. Wireless tech is cool and all, but until it’s been better refined I’ll stick to untangling my rat’s nest of cables once a year, thanks.

So wasn’t I pleasantly surprised to learn that Apple’s standard wired keyboard is only $50, when anything comparable from Logitech, Microsoft or SteelSeries was double the price and double the ugly. I’ve been using it for over a week now, and I’m happy to report that it’s the best feeling keyboard I’ve ever used, so I highly recommend it.

There are a few quirks to using an Apple keyboard on a Windows machine, of course, but nothing we can’t fix with some program downloaded off the internet. Your two choices here are AutoHotkey and SharpKeys. The former runs as a script in the background that intercepts key presses and can make them do something else entirely, like a multi-key press macro, which makes it far more powerful. But again, since I’m a little obsessed with efficiency, it just wouldn’t do for me to have a script that starts up with Windows on every boot, eating precious CPU cycles while I wait for code to compile. So, I went with SharpKeys, which has the added bonus of being much easier to use than AutoHotkey.  You don’t have to write any scripts, just a few clicks is all you need to set yourself up permanently.

Setting Up SharpKeys For The Apple Keyboard

The good news is that the keyboard itself is plug-and-play with a Windows machine, with almost everything working as expected. But if you’re anything like me, you probably want your shiny new device to match the functionality of a standard keyboard layout as closely as possible. The first step here is to identify the problem children when using the keyboard with stock settings:

  1. The Windows and Alt keys are swapped, on both the left and right of the spacebar
  2. There’s no Print Screen, Scroll Lock, Pause/Break, or Insert keys
  3. The Eject and Function keys don’t do anything

So, with this in mind, I suggest the following SharpKeys remapping:

SharpKeys Remapping

We’ve now fixed almost everything: the Windows and Alt keys are swapped back to the way they should be, and we get our handy Print Screen, Scroll Lock, and Insert keys back. The only problem is that Function and Eject are not recognized by SharpKeys, and hence we can’t do anything with them. You could probably overcome this using AutoHotkey, but I didn’t bother trying. The good news, however, is that you have four extra function keys you can use for whatever you want (I went with music controls), which gives us the following effective keyboard:

New Keyboard Layout

Now, I’m sure there’s a purist out there somewhere, screaming at his monitor that this doesn’t match the One True Keyboard Layout. Well, unfortunately, Pause/Break give SharpKeys some trouble by having a non-standard keycode, so I just didn’t bother with it. And let’s be honest, when’s the last time you pressed it? (If you answered “changing my environment variables, duh!” then you’ve earned yourself a cookie! But it’s still incredibly rarely, c’mon…) So, I plugged Insert there, rather than on the non-functional Function key (oh the irony). Finally, since Clear already behaves as Num Lock out of the box, we’ve got ourselves keyboard we can work with. Enjoy the shinies!

You can follow any responses to this entry through the RSS 2.0 You can leave a response, or trackback.

12 Responses

Leave a Reply

Your email address will not be published.