Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!mailrus!umix!nancy!eecae!fmsrl7!teemc!rolls!mtuxo!homxb!genesis!hotlr!news From: news@hotlr.ATT (Network News) Newsgroups: comp.emacs Subject: Re: Help with remapping C-h in GNU Emacs Keywords: control-h keymap help-command Message-ID: <350@hotlr.ATT> Date: 28 Apr 88 14:54:38 GMT References: <1512@se-sd.sandiego.NCR.COM> <179@pyrdc.UUCP> Reply-To: news@hotlr.UUCP (Network News) Organization: AT&T-BL Dept. 54315 Lines: 41 In article <179@pyrdc.UUCP> mike@pyrdc.UUCP (Mike Whitman) writes: > In article <1512@se-sd.sandiego.NCR.COM>, cliff@se-sd.sandiego.NCR.COM (Cliff Bamford) writes: > > I'm running GNU emacs 17.57.30 in an environment in which control-h > > usually (and unalterably) means "backwards-delete-character". I'd like > > to establish another keystroke sequence as the "help-prefix" , and > > make control-h mean backwards-delete-character so I can let my tactile > > memory autopilot take over the correction of simple typos again. I've > > looked at the documentation and it seems to require changing global-map > > which frankly scares me. What am I missing? > > > Don't be too scared it is as easy as putting the following in your .emacs > file. > > (global-set-key "\C-h" `delete-backward-char) > > hope this helps. Don't let the flames you will get for this question stop > you from asking more, it's the only way to learn unless you can find a > EMACS wiz localy to help you out like I did. Have fun!! > Ah well, the re-setting of the C-h key to invoke the delete-backward-char function is very easy. It is setting up the keymaps so that folks can still get help that is a little bit tougher. Here is a slice from our site-init.el file (the environment here also has the mindset ^h==erase). BTW, this code is for version 18.36. Earlier version may need a slightly different approach to re-setting the help key as C-_ (or whatever else you want it to be, some possibilities include C-M-h, C-x h, and C-^). ;; GNU Emacs site-specific changes file for Bell Labs (hotld!nz, 9/29/86) ;; ;; define ^h as a delete, for convenience of users (define-key global-map "\^h" 'backward-delete-char-untabify) ;; define ^_ as the help command (^? on vt100 and tty44xx and tty54xx) ;; (Some of this may be a little different for 17.57) (define-key global-map "\^_" 'help-command) (setq help-char ?\C-_ ) (fset 'help-command help-map) Don't let changing the global maps scare you, that's why they are there.