I occasionaly use Aquamacs on my Macbook Pro. I have also bought an Apple keyboard with a US english layout, because it is not practical to program on a Mac with a french (or more generally probably any non english) layout. These characters { } | \ ~ [ ] are not even on the keyboard, and you have to use various combinations of meta keys to get them.

Of course it doesn't work well when you need: M-\ , because typing backslash already requires meta keys.

So, how do you use Emacs on a non english keyboard, if that is even possible ?

I could switch the built-in keyboard layout to english, but that's not really comfortable to use it for a long time. I do it when I have no other choices, for example when at some point I need a lot of braces, but that's just temporary.

2 Answers 2


In Aquamacs check the Options->Option,Commands,Meta keys menu. It allows you to switch the key bindings of the various meta keys. I have the same issue with the Swiss German keyboard and using M-; to toggle Meta/Alt behavior helps a lot.

  • 1
    It wasn't obvious to me at first that this is the correct answer, but it is. The problem is that Aquamacs by default maps Alt to Meta. Just uncheck that and your national keyboard will work fine.
    – tripleee
    Oct 12, 2015 at 12:20
  • Also, for your init.el: (setq ns-alternate-modifier nil)
    – tripleee
    Oct 13, 2015 at 7:19

You could use Ukelele to modify the US layout to make French characters easier to access. For example add them under caps lock and then add something like this to private.xml in KeyRemap4MacBook:

<autogen>__KeyToKey__ KeyCode::OPTION_R, Option::KEYTOKEY_BEFORE_KEYDOWN, KeyCode::CAPSLOCK, Option::KEYTOKEY_AFTER_KEYUP, KeyCode::CAPSLOCK</autogen>

Pass-Through CapsLock LED status disables the caps lock light on some keyboards.

  • To apply changes to a keylayout, you currently have to for example run sudo touch /Library/Keyboard\ Layouts/ and log out and back in.
  • Keyboard layouts in ~/Library/Keyboard Layouts/ can't be selected in password dialogs or the login screen, but ones in /Library/Keyboard Layouts/ can.
  • XML keylayout files don't work with the popovers shown when holding keys, but keylayout bundles do.
  • The default input sources can be removed by editing ~/Library/Preferences/ByHost/com.apple.HIToolbox.*.plist.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .