27 ms·
This is off topic, but I've always wanted to know if there is some reason that Mac OS supports so many of the Emacs editing commands? C-a, C-e, C-f, C-b, C-k, C
by MarcScott 12y ago
This is off topic, but I've always wanted to know if there is some reason that Mac OS supports so many of the Emacs editing commands? C-a, C-e, C-f, C-b, C-k, C-d all work. It often surprises me when I'm in some other app and accidentally use an Emacs command, only to find that it works.
- protomyth 12y agoIts part of Cocoa, search for ~/Library/KeyBindings/DefaultKeyBinding.dict for more information and how to alter the behavior.
- jaequery 12y agoIt's part of unix/linux, they all have emacs keybindings as default
- protomyth 12y agoMarcScott asked about Mac OS and the unix subsystem isn't the part on Mac OS that provided the emacs bindings for the apps.
- ibrahima 12y agoYou're probably thinking of readline[1] actually. At the least that's why bash supports emacs keybindings (though I am never sure if a feature is from the shell or the terminal emulator). I believe you can configure readline to have vim keybindings. [1] http://en.wikipedia.org/wiki/GNU_Readline http://en.wikipedia.org/wiki/GNU_Readline
- huxley 12y agoIt comes from NeXTSTEP, text fields were given several emacs compatible keystroke editing commands as part of the key bindings for NSTextField and NSTextView. You can modify the default keybindings and even add more emacs compatible keystrokes if you find it helpful and most Cocoa apps will inherit the new keystrokes: http://www.hcs.harvard.edu/~jrus/site/cocoa-text.html http://www.hcs.harvard.edu/~jrus/site/cocoa-text.html (it's a good article that also has some interesting info on Input Managers and modifying keyboard layouts) drdrang wrote an article that linked to several other good sources on the subject: http://www.leancrew.com/all-this/2011/11/capitalization-keybinding/ http://www.leancrew.com/all-this/2011/11/capitalization-keyb...