System-wide ErgoEmacs Keybinding for Windows, Mac, Bash
This page lists several utilities that let you use the ErgoEmacs Keybinding OS-wide.
Note: as of , the ergoemacs-mode has command to generate all these files. Alt + x ergoemacs-extras
to generate them.
Download
Download at: http://code.google.com/p/ergoemacs/source/browse/extra
Windows
For Windows, just download the following executables.
- ErgoEmacs_keybinding_Windows_dvorak.exe
- ErgoEmacs_keybinding_Windows_qwerty.exe
- ErgoEmacs_keybinding_Windows_PT-Nativo.exe (PT-Nativo layout for Portuguese)
Files ending in “.exe” are executable binaries. Double click on it, then ErgoEmacs keybinding will be activated. To de-activate, right-click on the AutoHotkey Green H icon in Taskbar. (aka the “system tray”).
Files ending in “.ahk” is the AutoHotkey source code.
Following are util to make CapsLock key call emacs's “execute-extended-command” (M-x). Very convenient.
- emacs_capslock_for_Alt+x.exe
- emacs_capslock_for_Alt+a.exe (if you are using ErgoEmacs Keybinding)
These are implemented using AutoHotkey. See: AutoHotkey Tutorial.
Mac
Download one of the following file, then rename the file to DefaultKeyBinding.dict
, then put it in ~/Library/KeyBindings/
. (create that dir if it doesn't exist.)
- ErgoEmacs_keybinding_os_x_dvorak.dict.txt
- ErgoEmacs_keybinding_os_x_qwerty.dict.txt
Restart any app and the keybinding will be effective (no need to restart Mac OS X.).
These are based on OS X's system-wide keybinding mechanism. For detail, see tutorial: Creating Keybinding in Mac OS X.
Linux/Bash
Download the following, then place the content in your ~/.inputrc
. (see the file header for detail.)
- ErgoEmacs_keybinding_bash_qwerty.txt
- ErgoEmacs_keybinding_bash_dvorak.txt
Not Perfect
I use all of them, the Dvorak version. However, note that there are many quirks in keybinding system in all Windows, Mac, Linux, and Bash too. In a perfect world, a keybinding system should let you assign or remap any key system-wide. However, that's not the case. Not in Windows, not in Mac OS X, not with emacs, nor with AutoHotkey. Typically, there are certain key combinations handled at low level that you just cannot remap, some are by design, but some due to complexity. (For example, on Windows, ❖ Window + l, ❖ Window + u, Ctrl + Alt + Del. On Mac, ⌥ option with any of e u i n `, or ⌘ command with any of z x c v.)
Also, there are many practical quirks. For example, on Windows with AutoHotkey, the keys won't work when you are intsalling a software or in regedit or running any of sys admin tools. Because, while in regedit, you are running it in admin privilege mode, But AutoHotkey is not running in admin privilege mode. You can run AutoHotkey as admin, but that introduces more complexities.
On the Mac, the system wide keybinding works only with apps written in the Cocoa framework, but even so, not all your key remappings works. (for practical purposes, it works in vast majority of apps out there.)
So, the above ErgoEmacs scripts are not perfect, but they cover all the basic cursor movement and deletion keys. (read the file header for detail.)
PS the contributors for these scripts are in the files. Here's a summary:
- Milan Santosi wrote the AutoHotkey scripts for Windows.
- Xavier Gomes Pinho contributed the PT-Nativo layout (Portuguese) of AutoHotkey scripts for Windows.
- I wrote the keybinding config files for OS X.
- Brendan Miller wrote the “.inputrc” config files for Bash.
Key Tools for {Windows, Mac, Linux}
If the pre-built tools on this page do not solve your need, see: