April 1997
Intermediate to advanced
240 pages
5h 56m
English
Now that we've bound help-command to M-?, the next thing to do is to change the binding for C-h. Using exactly the same process just described—that is, running describe-bindings (with either C-h b or M-? b at this point)—we find that the command invoked by DEL is delete-backward-char.
So we can write
(global-set-key "\C-h" 'delete-backward-char)
Now DEL and C-h do the same thing. If you put these lines into your .emacs file:
(global-set-key "\M-?" 'help-command) (global-set-key "\C-h" 'delete-backward-char)
then in your future Emacs sessions, your BACKSPACE/DELETE/ERASE key will do the right thing, whether it sends a BS code or a DEL code. But how can we cause these changes to take effect in the current session? This requires explicit evaluation of these two Lisp expressions.
Read now
Unlock full access