Skip to main content
15 votes
Accepted

Using function keys as "sticky" modifier keys

If your workflow is: Press and release F8 Press and release s, expect it to trigger the binding for s-s Whatever key you press afterwards does not have the s modifier unless you press F8 again then ...
Gilles 'SO- stop being evil''s user avatar
4 votes

Emacs super key modifier on Caps Lock in Windows native and Cygwin emacs-w32

I feel your pain. Coming up with a decent hyper/super key binding which will work across all my keyboards is an ongoing search, especially given the widely varying laptop keyboard layouts. I dislike ...
Philip Daniels's user avatar
4 votes
Accepted

Open several files in a specifc layout with a shortcut

It will be necessary to decide ahead of time what windows/buffers will be A, B and C. The alist argument for the left window-width can be adjusted to taste -- it is presently hard-coded to 70. This ...
lawlist's user avatar
  • 19.2k
4 votes
Accepted

M-< and M-> don't appear to work

Sounds like either something has bound those keys to some other commands, or else emacs is actually seeing something other the M-< and M-> when you press the keys on your keyboard. To find out ...
user1978698's user avatar
4 votes
Accepted

Typing composite characters (e.g. diacritics) in emacs

This is a Dead Keys problem, and it's mentioned in the Emacs wiki. All the workarounds explained there solve the issue.
C2H5OH's user avatar
  • 181
3 votes
Accepted

Capital A Meaning in Emacs Syntax?

Emacs recognizes 5 modifier keys (arguably 6 depending on how you feel about Shift): <Control> (C-), <Meta> (M-), <Super> (s-), <Hyper> (H-), and <Alt> (A-). This ...
D. Gillis's user avatar
  • 496
3 votes
Accepted

How to insert special characters not on a US/UK keyboard?

I have the following in my init.el to use the italian layout with Mac OS ;; Command key is Meta (setq ns-command-modifier 'meta) ;; Option (alt) key used for special characters (e.g. []@#{}...) (setq ...
matteol's user avatar
  • 2,038
3 votes
Accepted

I want to type special Spanish characters in Emacs on a MacBook Pro keyboard ... but I have no clue where to start

Short answer: C-u C\ spanish-prefix RET. The characters you mentioned can then be typed as ~? => ¿ ~! => ¡ Long answer: read the emacs documentation starting at Language Environments, plus the ...
rpluim's user avatar
  • 5,325
3 votes

My left alt key (OS X) does not work as Meta key in Emacs (terminal)

After making sure the right alt key is setup in the Terminal app as @junnu suggested, you can do the following to free up the right option key for the special characters you need: (setq mac-right-...
EFLS's user avatar
  • 1,612
3 votes
Accepted

How to remap the meta key on Linux?

The following elisp may help you out. Just add it to your config. (setq x-meta-keysym 'super)
Compro Prasad's user avatar
3 votes
Accepted

Accessing square bracket in Emacs with German Keyboard on Macbook with OS X

I have run into this issue before - also trying to use Emacs on OS X with a German keyboard for (C/C++) programming. My solution to this issue was to use the Command key as Meta and pass Option ...
Timo Geusch's user avatar
3 votes
Accepted

Diacritic marks in emacs for macOS

But on macs keyboard it is no distinction between left and right option key ⌥ as it is in Win (Alt and Alt+Gr). Yes, there is. You have the variables ns-alternate-modifier and ns-right-alternate-...
d125q's user avatar
  • 1,453
2 votes

Generate dynamic keybindings depending on keyboard layout

This is not exactly a complete answer to your question, but it may help you as a starting point. My evil-colemak-basics provides Qwerty/Colemak best-of-both-worlds key bindings: https://github.com/...
wouter bolsterlee's user avatar
2 votes

How to use the Insert key to toggle `overwrite-mode` when using a PC keyboard in OS X?

Placing the following snippet in user-init-file (~/.emacs.d/init.el in my case) worked for me. I also set ctrl-insert and shift-insert to copy/paste. (when (eq system-type 'darwin) ;; when using ...
ValG's user avatar
  • 21
2 votes

Accessing square bracket in Emacs with German Keyboard on Macbook with OS X

To change the meta key you can look at the variables ns-command-modifier, ns-option-modifier, ns-control-modifier, ns-right-command-modifier, ns-right-option-modifier, ns-right-control-modifier. On ...
amitp's user avatar
  • 2,541
2 votes
Accepted

US-Intl layout EU users of Emacs in WSL - how do you input those Alt-Gr characters?

Just found this issue, looking around the internet I came across this page, and the solution is at the bottom, basically you have to set the keyboard mapping with the following command on the Debian ...
Skalas's user avatar
  • 36
2 votes

I want to type special Spanish characters in Emacs on a MacBook Pro keyboard ... but I have no clue where to start

I just found out this is how you do it: (setq ns-alternate-modifier nil) I was instead using the insert-chart bound to C-x 8 which is very painful edit: thank you all for the interest xD I'm native ...
Daniel Baez's user avatar
2 votes
Accepted

How can I get holding down the spacebar to work as expected

sorry for kinda necro posting, but someone might find this useful. I stuck into Hangul_Hanja problem after installing emacs as well. After some research and conclusion, that's it's a hardware problem, ...
RamūnasP's user avatar
2 votes
Accepted

German input method: missing ' (single quote)

Created my own layout, german-t1, simply by adding to ~/.emacs: ;; T1 German keyboard layout without AltGR and without <> (see ;; <https://emacs.stackexchange.com/a/47487/5327>): (quail-...
feklee's user avatar
  • 1,079
2 votes
Accepted

How to access symbols in emacs, which are accessed normally by alt key

This is simple: set the Cmd key as Meta and let Alt key as Alt in your init.el file - use these: (setq ns-alternate-modifier 'alt ns-command-modifier 'meta ns-...
Ian's user avatar
  • 1,483
2 votes

Rebinding RET without rebinding <kp-enter>

By default, <kp-enter> runs [13] (see function-key-map) which equals a single C-m. So, Is there a way to do this without having to manually rebind <kp-enter> to any function RET fulfills ...
shynur's user avatar
  • 5,438
1 vote
Accepted

key binding isearch-forward with Greek keyboard

Try binding keys also in isearch-mode-map. These keys are among those bound there by default, for example: C-r isearch-repeat-backward C-s isearch-repeat-forward C-M-r isearch-repeat-backward ...
Drew's user avatar
  • 78k
1 vote
Accepted

Umlauts in Emacs on Mac

The following setting makes the left alt/option key behave like a system default key (so that one may use special symbols, foreign language characters, and so forth), and the right alt/opion key ...
lawlist's user avatar
  • 19.2k
1 vote

Keyboard map in X version of Emacs not respecting system map

Odd solution. In Manjaro I'd inadvertently set the Japanese keyboard layout. X emacs was respecting that setting, whereas the console version, and all other X apps were perhaps following locale.
Tony Martin's user avatar
1 vote

Bind Meta key to Command on Mac Without Altering its System-wide Behaviour

In non-windows mode, changes to ns-* variables (such as ns-alternate-modifier and ns-command-modifier) are ignored. In particular, if the -nw option is passed as argument to emacs, the logic that ...
anon2328's user avatar
1 vote
Accepted

How does one type <C-menu> or <next> on a keyboard (in Emacs)?

Probably depends on your keyboard. I have a typical US PC keyboard. I don't know whether I have a <menu> key (for C-<menu>). But the <next> key is the key labeled Page Down. To see ...
Drew's user avatar
  • 78k
1 vote
Accepted

In MacOS, is there any way to have native Mac layout for ‘option-something’ special symbols in quoted-insert?

As I learned that Emacs enters native special symbols if Option isn't mapped to Meta, I went ahead and made a wrapper for quoted-insert that does the unmapping: (defun my/quoted-insert-wrapper (arg) ...
aaa's user avatar
  • 446
1 vote

Use xcape-like Control_L=Escape only in Emacs evil insert-mode?

I found a workaround, inspired by the comment by Håkon Hægland in Leave evil insert mode with control key First make a keycode for VoidSymbol with xmodmap (xcape can only work on keysyms that have ...
unhammer's user avatar
  • 1,159
1 vote

My left alt key (OS X) does not work as Meta key in Emacs (terminal)

http://osxdaily.com/2013/02/01/use-option-as-meta-key-in-mac-os-x-terminal/ Open Terminal and pull down the primary Terminal menu to choose “Preferences” Under the “Settings” section, find your ...
junnu's user avatar
  • 780

Only top scored, non community-wiki answers of a minimum length are eligible