Direct Manipulation, and Text Editors

Hat-tip to Giles Bowkett for mentioning Bret Victor’s talk, Stop Drawing Dead Fish, about direct manipulation and computer interaction as a tool for illustrators and animators.

I paused this video part-way through, so I could Get Down to Work. I paused it around 34:30, right after Bret Victor mentioned David Hestenes‘ idea that algebra and geometry help us model the world in similar ways, but that algebra uses our linguistic ability, while geometry uses our visual/spatial perception. Victor went on to say that tools for visual artists should use our visual/spatial abilities (direct manipulation), rather than our linguistic ones (code).

Like I said, it was time to Get Down to Work. I flipped over to Sublime Text 2, where I happened to have a block of text selected. Warming up, I idly hit command-I to search for a bit of text, only to realize that Sublime was only searching in that selected text. This is handy! I’ve been wanting something like this lately, when a method or variable name shows up all over the file, but I’m only working on one method.

Using the trackpad to select a bunch of text, and then working on it, feels a lot like I’m holding the text in one hand, and working on it with Sublime in the other. I discovered this accidentally, too – I’ve felt pretty productive with Sublime after the (tiny) initial bump, and I occasionally, gradually, get better as I learn new tricks.

I switched to Sublime after trying to learn Vim for a month or so. I’d been an emacs user for a few years, but I was under-using it, and didn’t need all the extra machinery. Vim seemed lighter, so I tried it out. But it felt like learning emacs all over again, but with different incantations: everything forced into the keyboard. And I get that! I’m a home-row Dvorak typist! But I still felt like emacs and vim were a step back from humbler tools like Programmer’s Notepad.

Bret Victor’s talk suggests an interesting explanation for that. He points out that some animations are a pain to create manually, and some behaviors are hard to code into the tool: so you divide and allocate tasks to the computer and the artist according to their abilities, and their cooperation produces the best effect.

Maybe this explains the appeal of these less-hardcore text editors. Sure, using the mouse and buttons for everything, a la Microsoft Word, is tedious, but so is forcing all interaction through the keyboard. Maybe a better allocation of tasks, a better balance of responsibilities between typist and tool, is what’s needed.

Dvorak: The Betamax Keyboard

I’ve been a Dvorak typist for about five months. It took me three tries to really stick it out through the learning phase, because let me tell you—as a touch typist, any learning curve over one week sucks (and you’re probably not learning Dvorak if you’re a hunt-and-peck-er). There are some things I wish I knew before I switched, so I’m feeding them to Google for others to find. My thoughts reflect only my experience, YMMV, and all that. For me, the short answer is that I’ll probably switch back to QWERTYUpdate: I never actually did, and I’m considering writing a recant to this post.  See the bottom of the post…

How Bad is the Learning Curve?

I suspect this really varies from person to person—I’ve read “Allow for about 1 hour of training for each WPM to regain your old QWERTY speed”. I don’t know my old QWERTY speed, but I was proficient, so let’s say it was 70 WPM. If I “trained” all day, that’s 70 hours / 8 working hours = 8.75 days, almost two weeks. I really type only about a third of the day, so that makes it 8.75×3 = 26.25 days, about five weeks. In reality, it took me about two months to type without thinking. Maybe I was faster at QWERTY than I thought, or maybe I’m a slow learner, but it took me longer to transition than I’d expected.

That may be because I type largely from muscle memory. Instead of mentally spelling out each word, then finding the corresponding keys, I rely on automatic keystroke patterns for common words (I suspect most touch-typists do this). This is especially true for keywords in programming languages: table, div, span; class, public, void, String; select, from, where, join. When I started learing Dvorak, my muscle memory for different languages had to be re-learned. Maybe this made it harder for me to feel comfortable with Dvorak, to really say “ok, I’ve learned it.” HTML was the worst, for some reason. I was re-learning SQL at the time, and didn’t have much SQL muscle memory, so I picked it up much faster.

Living with Dvorak

So now that I’ve arrived, it’s keyboard bliss, right? Almost. I do like it better, and can definitely feel the difference, but there are some real problems with it, which basically boil down to incompatibility. I hate to say it, but like Betamax vs. VHS, the inferior solution wins, by sheer ubiquity.

Keyboard Shortcuts

Of all the issues, this hit me hardest, being something of a power-user. On Windows, a bunch of useful commands are conventionally tied to the same keyboard shortcuts, generally with the Ctrl key. Ctrl+X is cut (like scissors). C is Copy. V is paste (the v points down – “put it down here”). Z is undo (I don’t know why that makes perfect sense to me). A is select All. S is Save. B is Bold text. On QWERTY, those are all left-hand, contiguous keys – mousing with my right hand, I could edit really fast.

All this changed with Dvorak. The left-handed Ctrl shortcuts are now scattered across the board. I don’t want to re-bind them in every app I use, and in some apps, I couldn’t if I wanted to. I got around this by buying a fancy mouse (a Logitech MX400) with extra buttons, and tied them to Copy and Paste. It’s not the same, but it solves 70 or 80% of the problem.

Using Other Computers

This one is bigger than I’d thought. I know, you’re thinking “How often does he use someone else’s computer?” But QWERTY computers are everywhere, and they’re spreading. Most kiosks and embedded devices use QWERTY (the rest use alphabetical order). SmartPhones use QWERTY. The TitleSleuths at Borders bookstores use it. Even my Prius uses it. Lots of devices offer keyboards to talk to them, and they’re not supporting Dvorak. The range of devices that I’ve become incompatible with is only growing.

Other People Using My Computer

This is a minor point. Everytime someone wants to use my computer (pair programming, or whatever), I have to switch it to QWERTY, for each application they use…it’s not global (is this any better on Macs or *nix?). So I launch an app and give them the keys, but they’re only OK until they launch something else. And some apps you need to tell twice, most notably the command line. You tell it “Dvorak”, it says QWERTY. “Dvorak”. QWERTY. “No, dammit, Dvorak!

You can get around this with the excellent Dvorak Assistant, a little System tray tool, whose icon is either a Q or a D key. Instead of mousing around with the Win XP Language Toolbar, you can switch layouts via Ctrl+Shift+F12—much better than WinXP’s default, Ctrl+Left Alt. I used to mash that combo all the time, and sure enough, it’d pop me right into QWERTY. Even better, the Dvorak Assistant affects all apps at once.

Switch back to QWERTY?

Like I said earlier, I’ll probably switch. My slightly-better speed comes at the cost of compatibility with the rest of the world. My Dvorak speed will continue to improve some, and eventually plateau, but the number of QWERTY keyboards around me will only increase. This makes Dvorak a steadily growing liability.

It’ll take a bit to re-train my muscle memory, but I believe it’ll be much faster than learning Dvorak. Back on QWERTY, I’ll be able to use any keyboard that crosses my path, and I’ll get all those keyboard shortcuts back. I’ll have to make those extra mouse buttons do something else.


2007-02-23 So I still haven’t switched back to QWERTY. I’ve tried a few times, and it doesn’t seem like it’ll be too hard to do, but I’m lazy, and busy doing other things. On the other hand, if it’s easy enough to switch to QWERTY, I might opt instead to stay on Dvorak, and just periodically practice QWERTY. That way, I’ll have the best of both worlds.

Also, someone found this article by searching for Vista + Dvorak. I’ll try to test the Dvorak Assistant on Vista, and will let everyone know how it goes, unless someone posts with a more specific question.

UPDATE (again)

2009-01-24 Somewhere in the two years since I last updated this, I decided to stay on Dvorak.  Reading over my reasons for switching back to QWERTY, they boil down to three: crappy Windows support, other people and computers, and hot-keys.

Crappy Windows support is 100% solved by the still-excellent Dvorak Assistant — I carry a copy on my thumbdrive, and it’s on every machine I regularly use.  If I could pay for it, I would.  It works flawlessly on Vista.

Other people and computers is still an issue, but only a minor one.  I can comfortably hunt-and-peck QWERTY, so using any other machine (kiosk, TitleSleuth, or my Prius) is simple enough.  Even since I started pair-programming all the time at my new job, it hasn’t been a problem — the Dvorak Assistant lets me switch my machine when we’re at my desk, and I can find my way around QWERTY easily enough at other people’s machines.

Hot-keys have become less of an issue as I’ve gotten more used to life with Dvorak.  I’m used to using hot-keys where they are in Dvorak (Ctrl-S looks like Ctrl-semi-colon), because when I type them, I still think in terms of letters: “S for Save”, and for me, it’s still an S.