AaronCrane.co.uk

Keyboard shortcuts

There’s been some discussion lately about the utility or otherwise of keyboard shortcuts, after Tim Bray linked to several pieces by Tog on the topic. Tim disagreed with Tog’s analysis, leaving explanations as an exercise for the reader, and Kevin Scaldeferri, one of his commenters, took up the challenge:

It seems to me that the flaw in Tog’s argument is summarized in these sentences: “it takes just as long to decide upon a command key as it does to access the mouse. The difference is that the command-key decision is a high-level cognitive function of which there is no long-term memory generated.”

Observing a skilled Emacs or vi user should put this assertion to rest. I no more think “what is the keystroke to delete this line?” than I would think “what is the keystroke to insert the letter ‘a’?”. To the point, there actually is a long-term memory generated of these high-level cognitive functions. Reasonably sophisticated editing sequences flow from my fingers with essentially the same ease as typing words and sentences.

This example may not be universal. There may be applications which do not lend themselves to the same muscle memory that text editing does. But, there are certainly counter-examples to the general assertion that Tog makes, and this is clearly one of them.

I have further evidence in favour of what Scaldeferri says: it’s much easier for an experienced vi user to come up with a complex sequence of editing commands than to recognise what such a sequence does, if it’s written out as a sequence of the characters needed to invoke it. That surely indicates that no high-level cognitive action is needed to produce the shortcuts (or at least that if it is, it’s not the same manner of thing as handling their textual representation).

In general, the more expertise you have in driving shortcuts, the more they constitute a win. I just know that C-M-f in Emacs will move me forward by a balanced expression, and I can produce such a keypress in the middle of editing with zero delay during which I invoke high-level cognitive functions to decide what to do. It takes place at the same level as moving both legs and one arm to change gear when driving. The cognitive function is “move” in one case, and “change gear” in the other.

I’d be very interested to see such keyboard-shortcut studies conducted on people who’ve invested large amounts of time in acquiring expertise in some particular piece of software, whether that be Vim, Emacs, Photoshop, or anything else. I find it very hard to believe that Tog’s results would be reproduced.