Carlos Fenollosa

Carlos Fenollosa

Engineer, developer, entrepreneur

Carlos Fenollosa — Blog

Thoughts on science and tips for researchers who use computers

Redefining your keyboard

June 11, 2012 — Carlos Fenollosa

I live in Spain, so most of the computers I work on have a Spanish keyboard layout. We really need it for the accents, ñ, ç and other language-related keys.

However, when it comes to programming, the Spanish layout seems... designed by Spaniards. Well, not actually. It is designed for writers, not programmers, which makes sense because it follows old typewriter's layouts.

For example, colons need an additional shift key press, the slash is inconveniently located above the number seven, so you need to perform an exercise of finger gymnastics to press it, braces need AltGr, etc. It is very, very inefficient, and it also leads to hand strains and finger pain after a few hours of work.

After some time considering it, I asked for a US keyboard, and voilà, programming is a lot easier now. For me, the major improvement is the location of the slash, widely used in UNIX, but also braces and the pipe. Sure, it takes some time getting used to it, but after about a month of daily use one can perfectly type with, at least, their original typing speed— if not even more—with the included benefit of less finger movement.

Accents can be typed anyway, either by pressing Alt-Letter or mapping them to any other combination. In any case, when I need to type a long text in any language other than English, I just press my layout-change key and use the Spanish keyboard again.

Windows, Linux and Macs allow you to change keyboard layouts on the fly by just pressing a key. With a couple of Google searches you should be able to learn how to do it, it's real easy. However, there's more! I recently discovered another trick which might be useful for your work.

Don't you feel your fingers a little bit tired after working with screen, Emacs or any program which uses Ctrl? That's because the Control key is located down in the keyboard and you need to stretch your fingers to Ctrl-A and Ctrl-E. A hidden feature of all operating systems also allows you to move it up, to the home row of your keyboard. Would you mind checking if there's some key you don't use that often which might be suitable to replace Ctrl? Caps Lock, indeed!

Caps Lock is a huge key which has no practical use except for twelve-year-olds on Youtube, and it is placed so close to A and E that it would be a sin not to make it behave like Ctrl. Again, do a quick Google search, and learn how to remap it. It can be done with the GUI, no need to change configuration files. And, were you in need to use Caps Lock for some reason, you can always map Shift-CapsLock to its old behavior.

From now on, I encourage you to think about remapping keys that you don't use. Personally, I have the Windows key remapped to switch layouts, CapsLock as a Ctrl and the F1..F12 as desktop keys: move one desktop to the left, right, move windows to another desktop, lock screen, volume controls, etc. And, now that you're here, take some time to learn or assign keyboard shortcuts to common tasks, either in the console or in the GUI. You'll work much faster and, more importantly, your hands' health will improve.

Tags: hardware

Comments? Tweet