Zenclavier: Extreme Keyboarding

by Tom Christiansen
12/01/1999

He stands like a statue, becomes part of the machine
Feeling all the bumpers, always playing clean
Plays by intuition, the digit counters fall
That deaf, dumb and blind kid sure plays a mean pinball.
--The Who

When was the last time you really zenned out on a pinball machine? You know what I'm talking about: that transcendent state of consciousness in which you're no longer carefully calculating what to do and when to do it. You're completely oblivious to everything except the ricocheting silver ball. You're totally in the groove, and those multiballs, extra balls, and free replays keep racking up all day long. Spectators and would-be players come and go, but their presence barely registers in your mind. Hours later, when it's all over and you finally step away from the machine, you find that words come haltingly; you've gone a bit nonverbal. Drifting off to sleep that night, instead of getting darker when you close your eyes, the world gets brighter as hypnagogic flashes from today's games explode in your mind's eye like comets dancing with lightning.

It's a pretty neat feeling, isn't it? You were in an altered mental state--a high, if you would. And like any other high, pinball zen is a bit addicting. Not only will this high leave you a lot less poor than plenty of others would, the only physical side-effects are apt to be some sore pects the next day. This pleasant state of mind is hardly limited to pinball. You can become one with your skis and the powder you're flying over. You can become one with your musical instrument of choice. And, if you're a hacker, you can become one with your computer.

I'm not talking about sitting for hours on end, clicking from one web page to the next as trivia trickles passively in. I'm talking about actually creating or seriously manipulating something, not just impersonating the couch potatoes down the hall in the TV room. You're in the groove; you've got all the right moves down so pat you don't even think about them. The world again fades away. There is the computer. There is you. There is nothing else. And this is good.

This blissful state of being one with your computer doesn't actually have much to do with your computer. Paradoxically, the computer just gets in the way, a constant reminder of irrelevant physical constraints and realities. As long as your brain needs to spend time thinking about hardware, like the keyboard or the mouse or a flickering monitor or a groaning disk drive, you won't be able to attain this special state of mind. That's because it's not the computer itself you're trying to become one with. It's the virtual world of software that you're trying to enter. Only when the physical world recedes from conscious awareness can enlightenment become possible.

When you're learning a new piece of music, bringing it up to performance tempo and committing it to memory, a funny thing happens. After enough practice, it feels as though your fingers themselves remember how to play the piece. You don't even watch them. They've a job to do, and once they've learned it, can go about that job remarkably free of direct supervision. The key to clearing the mind of the outside world, so that the program becomes the dominant reality, is what a musician would call "finger memory". (You might have heard athletes or dancers refer to it as muscle memory, but when we're talking about using the computer, it really is the fingers that count.)

Of course, that's not really what's going on; it only seems to be. Your fingers don't really remember. But a part of your brain that controls them does, even though "you" don't realize it. What's happened is that you've so successfully assimilated the moves needed that conscious direction is no longer required. The little lighthouse keeper behind your forehead can worry about other things, assured that your fingers will do the job you've trained them to do. Your eyes are on the screen, the program in your head, and your head is in the program. Your fingers become an unnoticed extension of your will. They're no more a conscious concern when typing than are your feet when you decide to walk. That's probably just as well, because if you ever thought too much about how walking is really just perpetual falling and nick-of-time rescue, you'd probably stumble.

It's a shame, but many people never achieve the same zenning out with a program that they may with a pinball game or a musical instrument. We're not talking about Eastern religions here; zenning out is just hacker-speak for what we always used to call "zoning out". Still, it can and does happen, and although it's something of an uncanny thing to witness someone else doing, it's a beautiful one to experience personally. In this satori-like state of experiencing knowledge without thought, the program's commands have become so deeply etched into your wetware that low-level tasks no longer require conscious direction. Your fingers seem to remember what to do on their own. Now on automatic pilot, they dance across the keyboard as quickly and as accurately as any performing pianist's fingers move, and just as automatically.

This isn't to say that the keyboard is the sole path to blindingly efficient computer use. Far from it! To be honest, the keyboard is sometimes the worst possible choice. It's entirely dependent on the task. For example, if you're playing xbill, the hacker's favorite video game, you certainly don't want to use the keyboard instead of the mouse. It's just going to slow you down. But neither does that mean that the mouse is always the best choice for all interactions.

Here's another example. I once tried using xmame to play Millipede. Using the keyboard for movement was excruciatingly painful, but the mouse wasn't all that much better. I realized that I would never become one with Millipede using either device. But just a few feet away stood a real Millipede game (yes, I actually do own one). I have no problem becoming one with that version, even though as far as the software goes, it's the same as what xmame is running. Why? Because the real game has a trackball, that's why! No longer tied to a clunky input device, I could sail along so fast that the non-rational part of my brain could take over and, like Tommy, play by intuition alone. After the first 200,000 points, you get to play with eight bouncing spiders simultaneously. Try it sometime--it's a real trip.

There's no question that, for certain tasks, the keyboard is clearly the optimally efficient input device. Consider the game of rogue or one of its more recent incarnations. You wouldn't want to use anything but a keyboard there. The command set is just too rich. Trying to play the game with a mouse-and-menu interface instead of a keyboard one would slow you down by at least two orders of magnitude. It would be as bad as trying to play Millipede with a keyboard, if not worse. As someone who once spent most of his non-hacking waking hours playing classic video games like rogue, srogue, larn, moria, and nethack, you'll just have to take my word on this. I certainly became one with the game. My fingers flew across the keys; my eyes never left the screen. I never had to think about how to do what I wanted to do, because no sooner did the desire enter my head than my finger memory took care of it.

When I wasn't playing rogue at university, I was hacking on code, for which I used a popular rogue-variant called vi. Yes, I know you probably think of vi as an editor, but I've always found people more receptive when I explain that it's actually a video game that happens to get a job done, too. In any event, the command set and design philosophy of the two programs overlap well enough to permit cross-competence between them. And as with rogue, I could zen out on vi. I was tremendously lucky I could, too, because most classes in my compsci program required more than 10,000 lines of code for each course. Try taking two or three of those classes in one term. You had to have a powerful and super-efficient editor, and you had to let the mechanics of the editor fade into the background, or else you just didn't survive. By zenning out, you ascended to a higher plane of productivity and did things that you normally couldn't do.

It sometimes seems that, as time marches on, fewer and fewer people will get the chance to experience the sublime joy of becoming one with their computer. It's as though hardware and software manufacturers were all conspiring to render this good, clean high an unattainable one. It's not illegal, at least as far as I know, but for most people it might as well be. In pursuit of the dubious goal of producing idiot-proof, zero-learning-curve programs, even programs intended for heavy-duty use such as editors--arguably the most important piece of software you'll use--have been turned into children's toys, effectively expert-proofed. In mindless and unexamined pursuit of false efficiency, the programs' authors have sacrificed the design attributes that let our fingers go about their proper business, get our faces up out of the mundane mechanics, and let our minds transcend the hardware and get into the program. They installed, if not outright roadblocks, then velocity regulators and gratuitous speedbumps.

How did this ever happen? Let's start with why the current crop of keyboards are suboptimal in the extreme. There's a general principle that says that the farther away something is, the larger it needs to be for equally swift access. This is true even if you are looking at the keys (but don't do that--see below), and fatal if you aren't. Distant keys like SHIFT, ENTER, TAB, CTRL, and the spacebar used to be larger, but they keep getting smaller as more and more vanity keys get added to your main keyboard. Look at an old Sun keyboard. While hardly the paragon of virtue as far as keyboards are concerned, it's further back up the downward path of devolution afflicting modern keyboards. Notice how SHIFT is bigger than CTRL, and CTRL is bigger than TAB. This size corresponds to how much relative use you make of those keys. Oh, and the CTRL key is both large and conveniently located on a Sun keyboard. What a joy!

Now go look on the cretinous keyboard that came with some poor sot's Wintel box. The spacebar, the most important key on the whole keyboard, is but a shrivelled and shrunken vestige of its former self. The ESC key has been moved to the penalty zone, the CTRL key is both distant and small (that's two strikes), and there's a CAPSLOCK key that's just as big as the TAB key. Hello? What can these people possibly be thinking? That I want to hit CAPSLOCK as often as I do TAB, and that I don't care about CTRL or ESC? This is completely crazy. The proper place for a CAPSLOCK key is in a different hemisphere from you. If we ever manage find out who put that abomination in its currently common place, we're all going to show up for the lynching party, but we'll have to wait our turn in a line of programmers stretching all the way from Boston to Mountain View.

If it were only the outlandishly rococo keyboards they were shoving at us, we hackers might still have a chance to become one with our computers. After all, we could always get a real keyboard instead: one with a decent layout and sans penalty zone. Happy Hacker makes a nice one.

But really, this is the least of our many problems. First of all, there's no end of brain-damaged programs these days, programs which both expect and require you to continuously enter and exit the penalty zone. This destroys your concentration, because you can no longer get there and back again while still looking at the screen. You incur a context-switch penalty that feels like a speedbump in your typing. It slows down your hands, and it interrupts your eyes. Once that happens, your concentration suffers a severe hit as you're forced to deal with mechanics, which you cannot internalize or omit.

The next gross inconvenience is requiring frequent chorded-key combinations. Any time you have to hold two or more keys down at the same time, this becomes more difficult to finagle. Compare how difficult it is to type a CTRL+G chorded combination with a simple, unshifted 'g'. If you ever need to hit a chord with more than two keys, such as CTRL+ALT+SHIFT+F11, you're in serious, serious trouble. This kind of thing is especially arduous on keyboards lacking duplicated left and right versions of the modifier keys. There's a very good reason we have two SHIFT keys. We should have two CTRL keys as well, and these should be easily accessible without looking. It's a lot easier on the hand to use the right-hand SHIFT key with a letter like 'e' or 'g'. Why should it be any different with CTRL, ALT, or the vanity keys?

If you're striving for efficiency, it's best to stay away from chords entirely. If you look at the way popular video games like rogue and vi work, their command structure consists mainly of single, non-chorded keystrokes, or sequences of single keystrokes. That's why those games are inherently easier on the typist than games like emacs and Microsoft's word processors are, where all your most valuable real estate has been thrown away, and every command is now a chord. Chorded commands are harder to type because you have to hold down the SHIFT or CTRL key. In a program designed for efficient use these are relegated to rarer activities, so the impact is minimized. The easy stuff is easy, and you never have to slow down, or even look down.

Consider how much easier it is to type a '/' to start a search than it is to start a search by using 'ALT+S'--or, horrors, by pulling down a menu and clicking on selections. There's no reason that a slash can't mean a search in a context where this makes sense. This wouldn't mean that if you were typing in a path name in some text box that a search window would pop up. You simply make it context-sensitive. Humans, you know, are really very good at context. Check out this sentence: "Can you please can the can-can while I'm in the can, man?" No problem. You see, our brains don't work off of a context-free grammar, and there's no reason that commands, keystroke or otherwise, should. In fact, because our brains do not work off of a context-free grammar, making our command set context-free would be running against our inner natures. It's just not how we think.

Besides the useless vanity keys stealing invaluable real estate from the main keyboard, we are saddled with an ever-growing number of extra keys in the penalty zone, such as function keys, INSERT and its friends, arrow keys, and relics out of the shrouded mists of antiquity such as SysRQ and Scroll Lock. I'm sure there will be more keys on your keyboard any day now.

Can you imagine how painful it would be if you were typing in some code or a letter, and every time you wanted to go to the next line, you had to use ENTER key way over on the numeric keypad? That would be nuts, wouldn't it? So can anyone tell me why programs expect you to switch back and forth between the real keyboard and the penalty zone? Apparently nobody ever told them that the closer something is, the easier it is. Something right underneath your fingertips is the most readily accessible. That's why rogue-style movement is easier on your hand than CTRL+[BNPF] commands. Still, both of these are substantially easier than movement using the arrow keys over there in the penalty zone.

The much-vaunted arrow keys, ostensibly easier to use for cursor motion, are in fact tremendously harder to use. There are three distinct reasons for this. First of all, if you're mixing commands over in the penalty zone with other commands which are on the keyboard, you're never going to achieve keyboard satori. You've got too much back-and-forth going on to find your groove. Your eyes act as a bridge linking two virtual worlds, the first inside your head, the other inside your computer's memory. With shifts between the arrows and the keyboard, your eyes have to desert their proper post to go slumming in the real world to play tour guide long enough to get you there and back again.

The second reason the arrow keys are terrible is that they're set in an arrangement designed by a masochist, probably the same torturer who stuck us with the CAPSLOCK key. Even if all you were doing was keeping one hand poised above the arrow keys, never switching keyboard domains, you would still be unacceptably slowed. That's because the up arrow and the down arrow are directly aligned vertically. Your hand despises this; notice how the main keyboard has no such configuration. To see what I mean, try alternating the 'j' and 'k' keys in rapid succession, using differnet finger side by side. See how easy that is? This makes video games like rogue really scream. Now try the same trick on the up and down arrows (which once upon a time were lined up just like 'hjkl'). Whoops! You have to turn your hand completely sideways, or else use the same finger to do both jobs. Either way you play it, you lose. You had go between left and right easily, or in any combination than up and down.

Does the visible label on the arrow keys truly offset the gross inefficiencies of being placed in the penalty zone and being stacked vertically? After all, the argument runs, someone who doesn't know the key command to move around can just use those. In the shallow and ephemeral world of zero-learning-curve and one-shot programs, this might have a scant iota of reason behind it. But really, for just how long do you expect your users to remain ignorant? Once they learn what the motion key is, they're not going to forget it from one moment to the next. If you assume that users cannot or will not learn, you thereby guarantee this very outcome. That hardly seems either fair or productive.

The third reason that arrow keys are inherently evil is that they support navigation based on characters alone. You'll never move on to higher abstractions, like words, sentences, or paragraphs, or in the programming world, to tokens, expressions, statements, blocks, or functions. You'll certainly never start thinking in powerful, abstract patterns like regular expressions. By relying upon arrow use alone for movement, and discouraging other kinds of information chunking, you lock your poor users into a tedious monotony and forever bar them from making the jump to light speed.

In any program designed for heavy use, the penalty zone should be not merely strenuously avoided, but completely banned. The keys there interfere with your prospects of ever becoming one with the computer. But isn't the numeric keypad in the penalty zone, and isn't it great for accountants? Don't they become one with their keypad? Well, sure they do. That's because they're staying in the same area. If all you're doing is entering numbers, then it's actually a good bit quicker to use the numeric keypad, because it fits under the hand better. The keypad is also optimized for numeric data entry: see how much larger the '0' key is there? And the '+' key? If you don't know why, watch a bean counter entering numbers on it some time. Go to your keyboard manufacturer and demand the return of the your CTRL key to it proper place and the restoration your wimpy spacebar to its proper size.

Don't expect to switch between numeric keypad and the main keyboard with anything resembling speed or accuracy. Unlike a normal clavier, where you can feel where you are in the scale because of the alternating two-three sets of raised keys, on a computer keyboard, no such sign posts exist. That means that while, the musical keyboardist can often make tremendous leaps in complete confidence without bothering to engage his eyes, the computer keyboardist cannot. Sure, you've probably got little nibs on your 'F' and 'J' keys (or sometimes on 'D' and 'K'), and on the '5' over on the numeric keypad, and it's a good thing that they're there, but really, they don't help all that much.

The lesson is that if you're going to change domains so radically that your hand has to move somewhere else, you absolutely need to stay right where you are for a good while in order to amortize the extreme cost of movement. Otherwise the context-switch latency issues will just kill you. And this is where the true root of all keyboard evil rears its ugly head: the mouse.

The mouse is the single greatest obstacle standing in the way of becoming one with your keyboard and the dramatically higher productivity levels which that state promises. That's because, of course, it has nothing to do with your keyboard. Compared with the onerous task of mousing through multiple menus, even a high density of chorded commands in rapid succession appears fast and easy--as many an emacs user will quickly attest. Chorded they may be, but at least they're still on the keyboard. The mouse might as well be in Timbuktu for how convenient it is to get your hand over to it and then safely home again without looking. Even though you'll often find your mouse without breaking stride, the same can hardly be said for returning to your standard keyboard position.

Unlike the arrow keys, that doesn't mean the mouse is inherently wicked for all things. (Well, unless you're an RSI victim, that is, or if you'd prefer not to become one. Mice, you see, destroy your wrists, and much more quickly than keyboards.) The mouse is only evil when you have to repeatedly switch between mouse and keyboard. That's because it knocks you out of the groove just as badly as an CTRL+ALT+SHIFT+F11 chord would. (I call that one a demented eleventh.)

Let's go back to that wonderful, angst-purging video game, xbill. You think of yourself as a Jedi sharpshooter, the last, lone defender against that creeping darkness which seeks to pollute and assimilate the free world into its hive mind. Reflexes are everything. You must walk the path of knowledge without thought, of action without contemplation. Anything less than complete dedication to your sacred duty will see another sun lost to The Evil Empire. In the back of your mind, you know that if you set down your laser rifle, you could program up a gooey bomb to encase the Bills in treacle to slow them down for a spell. All you'd have to do is take your hand off the mouse, move over to the keyboard, and type the baleful incantation, ``Department of Justice Anti-Monopoly Litigation''. But in the time it would take to do that, untold numbers of worlds would be lost, assimilated into the collective. So your slowness bomb remains untriggered: the price is too great to justify putting down your laser rifle.

So you see, there's certainly a place for a mouse. And, contrary to popular mythology, that place is not simply any system that provides the user with something more sophisticated than a 24-by-80 character display. "Mouse" doesn't mean "GUI", you know (nor, for that matter does GUI mean mice and menus). And a keyboard doesn't mean a CLI. A keyboard means the efficient input of diverse commands covering a vast domain. A mouse means the efficient selection of points and areas. Even if we temporarily tolerate the mistaken notions that CLI == text and GUI == pixels, a keyboard should not be limited to the world of command-lines and pipes, nor should a mouse be limited to the world of pixels and pop-up menus. Those are not the effective criteria for the most effective use of those two input devices.

If you don't believe me, just think for a minute about gpm, the mouse package for virtual consoles on Linux operating systems. It surely is a nice program to have around, isn't it? You don't have individual pixels, but you still appreciate having a mouse for certain tasks. Now think about your favorite pixel-addressable program, like xv or eterm. They have keyboard-accessible keystroke commands as alternatives to tedious mouse hunting. Aren't you glad those are there, too? The most popular version of the rogue games, nethack, comes in a GUI version these days, one complete with the fancy graphics. But guess what? There aren't any speed bumps. The keyboard is still king, which means that you can can still rip through the game just as fast as your fingers will fly.

I'll say it again for the logic-impaired: keyboards aren't just for CLIs, and mice aren't just for GUIs. There's no good reason whatsoever that, even in what's commonly referred to as the GUI world, you should eschew the keyboard. For many problem domains (xbill and its ilk notably excepted), the keyboard remains the fastest, most efficient, and most powerful input device available, and it would be the height of folly to avoid it.

Have you ever tried to play a piano using a stick that's clenched tightly between your teeth? Oh, you can do it, sort of--if you call that playing. You might manage to get out the melody of Jingle Bells, but I wouldn't set your hopes on the Flight of the Bumblebee if I were you. The percentage of your brain devoted to the hand, and in particular, the support structures for the fingers, is incredibly huge compared to the amount devoted to nearly any other physical activity. By avoiding the full potential of Man's wondrous capacity for prestidigitation in the literal sense, you cut him off from one of his greatest assets, one near and dear to his neural biology; one he was made for.

There's just no way you'll ever zen out on a keyboard when all you've got is a one-bit stick stuck in your mouth and your hands are tied effectively behind your back. Perhaps you prefer it this way, but you should understand the consequences of that choice. You'll never reach the point where your fingers know what to do on autopilot. You'll never get your face completely up off your desk. And you'll never savor the pleasures of having your mind firmly ensconced in the virtual reality of the program you are manipulating. The higher levels of mastery will be forever forbidden to you, and you shall dwell in the House of Clumsiness and Inefficiency all the days of your life.

Software engineers need to pay attention to both the keyboard and the mouse, irrespective of whether the program is running in a character-addressable terminal or in a pixel-addressable display. A simple change in visual resolution doesn't obsolete the entire access pattern. Developers should maximize locality of operations by hand position in ordre to facilitate an eyes-free operation of the input devices. Above all, they should give careful attention to programs destined for heavy use, so that they offer an upward path for all users, and experts are not hampered by the zero-learning-curve demands of non-users. Remember that a user is a novice but once and briefly, and an initiate ever after. Don't require infelicitous input combinations that would hamper efficiency in competent keyboardists. Only when the speed bumps and other awkward reminders of the physical world are removed can a computer user hope to reach that transcendent state of zenning out.


Cool links: