4 ms·
> These are called "M-x" in emacs parlance. And if you use the GUI version of emacs, you can use alt-x instead of pressing escape then x. It's much easier, but
by wtbob 11y ago
> These are called "M-x" in emacs parlance. And if you use the GUI version of emacs, you can use alt-x instead of pressing escape then x. It's much easier, but doesn't seem to work in the terminal.
That works in all my terminals — I suspect something's awry with your settings.
One issue is that if you use gnome-terminal under Ubuntu, I think by default it steals alt for its own menus. There's a setting to disable that, and I always selected it when I used gnome-terminal, because who uses GUI menus with a terminal? Nowadays I just use st.
Another tip is to set your caps lock key to control. This is one of those 'how did I ever live without this?' things (I actually buy keyboards where the control key is physically where caps lock is on most; it's that vital).
And if you write any Lisp or code, you might like to swap parentheses & square brackets. For me, at least, it's another one of those 'how did I ever live without this?' things. I type parens all the time, and now I don't have to hit shift. It's … wonderful.
- malloryerik 11y agoI actually use empty shift for parens, so comfy I almost feel guilty about it...
- disease 11y agoThat sounds like something I'd like to try. Mind sharing the code from your init file that does this - assuming you are doing this in Emacs?
- malloryerik 11y agoFor this remapping and a few others I'm using Karabiner for OSX. I remap elisp commands in emacs all the time, but I don't know how to remap the keybinding for the single SHIFT to parens. The answer might be here: https://www.gnu.org/software/emacs/manual/html_node/elisp/Changing-Key-Bindings.html https://www.gnu.org/software/emacs/manual/html_node/elisp/Ch... Karabiner is pretty good though, and you can select certain keybindings to only work in emacs. I've also remapped CONTROL to CAPS LOCK, a more common re-binding to save one's left-hand from endless torture and mutilation! Karabiner https://pqrs.org/osx/karabiner/index.html.en https://pqrs.org/osx/karabiner/index.html.en On GitHub https://github.com/tekezo/Karabiner https://github.com/tekezo/Karabiner It's also pretty simple to extend Karabiner with XML scripts.
- disease 11y agoFigured it out myself. Couldn't find a way to map single presses of the Shift key in emacs, but I was able to do this using AutoHotKey in Windows: LShift UP::Send, ( RShift UP::Send, ) LShift & F13:: RShift & F13:: As a Clojure and JavaScript dev I think I am going to like this mapping quite a bit, so thanks for the tip!
- malloryerik 11y agoI actually use empty shift for parens, so comfy I almost feel guilty about it...
- jquast 11y agoSet option 'metaSendsEscape' for xterm, lots of help here, https://www.emacswiki.org/emacs/MetaKeyProblems https://www.emacswiki.org/emacs/MetaKeyProblems
- _asummers 11y agoOne thing I recently did - MacBook Pros do not have a right control key and I really wanted one for my emacs use. So I downloaded a remapping program that interprets holding the return key as control, but normal presses as return. Seems to have worked out well, and it gives me some keyboard symmetry with caps lock control.
- ruraljuror 11y ago>Another tip is to set your caps lock key to control. This is one of those 'how did I ever live without this?' things (I actually buy keyboards where the control key is physically where caps lock is on most; it's that vital). I recently switched from Vim (still using it through plugins in some IDEs) and decided to not start with Evil mode but give Emacs keybindings a proper go. Switching the capslock key to CTRL has been crucial. This switch is a built in feature in OS X and Gnome. Downloaded a third party app in windows for my corporate pc.
- drivers99 11y agoIt could also be if he's on a Mac, you have to go to Terminal -> Preferences -> select your current profile -> Keyboard -> check "Use option as meta key" I found that out because I was trying to start using org mode but I'm new to emacs. That was one of many issues I ran into trying to get it to work. (First was that the emacs that comes with OS X is ancient and doesn't have org-mode, so I had to use brew to get a good version). Next is none of the tutorials actually match the shortcuts that org-mode actually uses on my system.