4

I am using Terminal version 2.5, where I have two requirements:

  1. I need to be able to type the Meta key.
  2. I need to be able to type the # character, too (Option+3 for the UK keyboard layout)

How can I satisfy both of these? By default, (2) is satisfied, but (1) is not. I can then turn on "Use Option as Meta key", which satisfies (1), but breaks requirement (2).

How can I have both? (It shouldn't be so hard for me to just be able to type.)

Edit: what I'm looking for, for example, might be a way to just "Use Option as Meta key" for the left/right Option key, or a way to override the "Use Option as Meta key" for the sole exception of the # character.

  • idk whether it will fix your specific requirement, but Karabiner is a popular tool for that kind of thing - pqrs.org/osx/karabiner – Tetsujin Nov 13 '14 at 10:26
  • 1
    Which keyboard do you have as on US ones shift 3 is # – mmmmmm Nov 13 '14 at 13:03
  • @Mark UK layout – jameshfisher Nov 13 '14 at 15:40
4

iTerm 2 can be configured to only use one option key as meta:

| improve this answer | |
  • Thanks. I found that iTerm's behavior here is somehow buggy; it stopped treating Option as Meta at some point during a session. In the meantime, I've switched to using a graphical version of Emacs which fixes my problem. – jameshfisher Nov 13 '14 at 15:42
1

For requirement 2 you can choose to make the keyboard an Australian one. The only difference between UK and Australian i alt3 and shift3. For UK they give # and £ and vice versa for Australian. This means that for an Australian keyboard # is shift3 as it is for a US or under Windows or Linux.

To change the keyboard layout (under Yosemite) got System Preferences->Language & region - hit the Keyboard Preferences button and use + to add Austrailian to the left hand column

| improve this answer | |
0

I finally figured out how to do this by code:

https://stackoverflow.com/questions/30336086/make-shift3-produce-not-%C2%A3-on-osx-by-code

If you have developer tools, you can compile & run that from the commandline.

| improve this answer | |
0

I have built a solution myself and it doesn't require abandoning Terminal.app in favour of iTerm 2.

It is a simple status bar app that runs in the background and rewrites all left Alt + $KEY key events to two key events in rapid succession, Esc, then $KEY; however, it only does this if Terminal.app is in focus.

You can find the source for the app here. You'll need Xcode to build it.

| improve this answer | |

You must log in to answer this question.

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