Jon AtkinsonI'm a web developer and system administrator

Using the hash key in Emacs with a UK keyboard

Posted on 26th November 2008. Tagged as tips, osx, mac, emacs

I've been using Emacs recently, and it took me a while to figure out how to make option-3 produce a hash symbol like other Cocoa applications.

This assumes you're using mac-key-mode like this:

(add-to-list 'load-path "~/.emacs.d/mac-key-mode/")
(require 'mac-key-mode)
(mac-key-mode 1)
(setq mac-option-modifier 'control)

To rebind the hash key, just drop the following in your .emacs:

(global-unset-key (kbd "C-3"))
(global-set-key (kbd "C-3") '(lambda() (interactive) (insert-string "#")))

blog comments powered by Disqus

Twitter

About Me

Picture of Jon Atkinson

Jon Atkinson is a web developer, sysadmin and occasional business guy. He works in the north west of England.

Jon can be contacted at , or on freenode as JonA. Also available: twitter, LinkedIn and Github.

My Company

Testled logo

I'm a director of Testled, a company which provides bespoke web and mobile development for all kinds of businesses.

If you're interested in working with me, take a look, then contact me via Testled.