dvorak
leŭksman
Warning: Most of this document was written around 1998 and may no longer be accurate as of 2005.
Contents |
Introduction to Dvorak
The Dvorak keyboard layout looks something like this:
` 1 2 3 4 5 6 7 8 9 0 [ ]
' , . p y f g c r l / =
a o e u i d h t n s -
; q j k x b m w v z
(Shifted)
~ ! @ # $ % ^ & * ( ) { }
" < > P Y F G C R L ? +
A O E U I D H T N S _
: Q J K X B M W V Z
It looks a little odd if you've spent your whole life using QWERTY keyboards, and it takes some getting used to (in general it takes about a month to get up to one's former speed when switching from QWERTY to Dvorak), but it's really more efficient. When it was developed in the 1920's it was found that in a typical day's work a typist's fingers moved a total of (look this up) several miles when using a QWERTY keyboard, but less than one mile on the Dvorak keyboard thanks to the better placement of the keys. Note that the most used letters in the English language are on the home row! This is a good thing, and reduces the likelyhood of nasty problems like carpal tunnel syndrome.
Dvorak and Linux
I am a rabid Linux user, and like so many of my brethren also a rabid Slashdot reader. In June 1998 there was a poll on which keyboard layout was better - QWERTY or Dvorak. Although QWERTY was winning by a large margin (largely because most people had never tried any other layout I suspect), there were a lot of very positive comments on Dvorak. Since it was summer I didn't have any papers to write, and I had no job at the time that might require me to use QWERTY, so I decided to try it out.
It was very frustrating for a couple of days, and I was constantly referring to a picture of the layout to figure out where keys were. After that I began to get the hang of it, and though I was still a bit slow and prone to typos for a while I saw the beauty of Dvorak - my fingers strayed only rarely from the home row, while in QWERTY they did so constantly. Over the next few months I proceeded to Dvorakize my entire system from top to bottom.
The Linux console
This is probably the easiest to do! Just log in and type:
loadkeys dvorak
or with Red Hat 6.0 which changed it,
loadkeys pc-dvorak-latin1
You now have a Dvorak keyboard layout set up! If you for some reason want to switch back, do:
loadkeys us
This loads the standard US QWERTY keyboard again. If you use a different layout (for instance if you're not in the US), substitite the appropriate keyboard layout.
You can load the Dvorak layout in you rc.* startup scripts to do this automatically, or if other people use that computer you may wish to put it in your personal login scripts so it is done after you log in. If so, be sure that the layout is back to whatever other people expect when you log out!
If you are using the
Red Hat Linux distribution, the
initial keyboard setting can be changed by editing the file /etc/sysconfig/keyboard
and specifiying the filename of the keymap (they are in /usr/lib/kbd/keytables,
and you don't need to specify the .gz extension if present).
The X Window System
XFree86 the most commonly used X server on Linux systems, will by default take its keymap from the console when it starts. So if you have Dvorak set on the console and then run X you'll get Dvorak in X.
If you use the XKBD extension, you'll want to configure it to load Dvorak also. For some reason it seems to think that a couple of keys are in different places than everything else, and it also does things I don't like with the numeric keypad, so I don't use it.
If you are using a multi-user system with QWERTY users and a graphical login manager such as XDM, you'll probably want to load the Dvorak keymap into X when you log in. This can be done using xmodmap, using a file like this... link... yadda yadda. This can be done automatically in your .xsession file; when you log out the X server is killed and restarted, so the keymap change is undone at that point and the next QWERTY user to come along won't be confused.
LILO
The most widely used boot loader for Linux is LILO, the Linux Loader. You can choose which operating system to boot (including multiple versions of Linux) and can specify additional parameters to the kernel to boot into single user mode, enable or disable some feature, etc. Since this is done by typing on the keyboard, it's nice to be able to do it in a decent layout!
Fortunately LILO includes the ability to remap the keyboard, and it's fairly simple to set up. You'll want a copy of dvorak.ktl (or you can make your own by following the directions in the LILO docs somewhere), and put a line like this in your lilo.conf to point to the keymap:
keytable = /boot/dvorak.ktl
Run lilo to update it and you should be in business!
SVGAlib
The Super VGA library is used by most non-X graphical apps for Linux. Some of them, especially games such as Quake, use "raw keyboard mode", which means they read from the keyboard directly, bypassing the kernel's keyboard layout translations. X does this too, but it does its own translations as we have seen. SVGAlib doesn't, and all of the raw keyboard SVGAlib apps I've seen assume as US QWERTY layout.
Fortunately this makes it easy to perform translations ourselves! Although it's a bit kludgey, we can translate keyboard scancodes from our preferred layout (such as Dvorak) into the equivalent scancodes for US QWERTY, and the program will understand us just fine as long as all the keys we need do have exact equivalents. That is, it wouldn't work right if the other layout had say 5 and % on different keys unless we went to a whole lot of trouble to figure out what combination of keys would be necessary to create each character and then simulate those keys being pressed or released as necessary. Ick!
My patch to SVGAlib, which includes a Dvorak map, is available at http://pobox.com/~brion/linux/svgalib.html I also have binaries for glibc2 and libc5 available if you trust me. ;)
Magic SysRq Key
The 2.1.x series of development kernels include a feature called the "Magic SysRq Key" that can be used to (fairly) safely reboot a system in many cases when the keyboard is normally not available (such as when X or a SVGAlib raw keyboard app takes the keyboard and then crashes without giving it back). It also can be used to do some other nifty debugging things.
Unfortunately the keyboard map it uses to figure out what you meant to do (which letter you pressed in combination with Alt+SysRq) is for QWERTY. So I hacked up a patch which adds a Dvorak layout option to the kernel configuration, and if selected the map is replaced with a Dvorak one. I haven't tried all of the letters since some of them do things like kill all processes and reboot, but the ones I've tried do work. The patch was made against 2.1.121 but applies to 2.1.123 and 2.124 cleanly. Also, it only applies to the x86 architecture, but it should be pretty easy to do the same for other architectures, if you do so please e-mail me your patch and I'll combine it in with mine.
The patch can be downloaded at http://pobox.com/~brion/linux/dvorak-sysrq.patch
Other operating systems
Every once in a while I have to use other operating systems, and I'm sure you do too. It's terribly painful but necessary. :( So while doing it, at least save some pain for your wrists and use a decent keyboard!
Other Unices
The xmodmap thing should work for any OS that uses X, but you'll want to make sure the scancodes are correct for your machine. I have a layout for Solaris/SPARC available at http://pobox.com/~brion/linux/dvorak.sun For other systems, take the regular keymap by running "xmodmap -pke > oldkeymap" and then changing it around.
I don't know about changing the keyboard layout in the console for other Unices, but I'd love to hear about it from people who do.
Update: Joshua Honeycutt has provided a
console keyboard map for Solaris/SPARC:
"I've currently tested it on a sparcstation 20 with a type 5c keyboard in both solaris 8 and 9 enviroments and simply put it with my other keymaps in /usr/share/libs/keymaps using loadkeys to switch to it."
DOS
For people who use LOADLIN or a similar DOS-based loader, this might even be relevant to Linux! There's a little package you can download that includes a keymap for DOS, I'll have to go looking for it again.
Windows
Control Panel/Keyboard. Change keyboard layout, select "US-Dvorak". If necessary insert your Windows floppy or CD-ROM so that it can copy the file over. If you use DOS programs be sure to set up DOS as well, see above.
At least in Windows 95, the keyboard layout is a per-user setting, so you can set it for yourself and non-Dvorak users can still use Qwerty. If you don't utilize separate user accounts you'll need to set it manually when you begin and end using the computer. If you do, at least Win95 freaks out when you log out and you can't type in the login box anymore. Sheesh. If you encounter this, reboot instead of logging out. Or just use Linux instead. ;)
Note that in environments such as a school computer lab, the system administrators are sometimes paranoid enough to disable almost everything you could possibly do to make the computer easier for you to use, including the keyboard control panel. If this happens, complain bitterly until they let you change the keyboard layout. (Me, I just use the UltraSPARCs instead, they manage to be secure witout becoming useless.)
Mac OS
This one's a pain... The OS supports different keymaps easily enough, but it doesn't include a Dvorak keyboard layout. You need to download it from ... somewhere... and put it in your system folder, and then you can select the keymap from one of the Control Panel applets. Probably called "Keyboard" but I don't recall.
Update: Mac OS X comes with Dvorak keymaps built in, select them from System Preferences -> International -> Input Menu. There's a regular Dvorak layout and a version that switches in the QWERTY keys when the command key is pressed so that shortcut keys don't move around.
For more information...
If you need more information than we have here, try some other sites...
- Dvorak International
- Introducing the Dvorak Keyboard
- and many many more to come!

