On August 13, 2003 at 9:59AM +0200, Roland Stigge <[EMAIL PROTECTED]> wrote:
> A user complained about the global keymap bindings for hyperlatex > in emacs. Since Emacs Lisp is not my "native language", please > acknowledge the following patch: > -(global-set-key "\C-ch" 'hyperlatex-format-buffer) > +(if (not (featurep 'latex)) > + (add-to-list 'after-load-alist > + '("latex" (define-key LaTeX-mode-map > + (kbd "C-c c h") > + 'hyperlatex-format-buffer))) > + (define-key LaTeX-mode-map > + (kbd "C-c c h") > + 'hyperlatex-format-buffer)) Don't use C-c LETTER, because these sequences are reserved for users. "GNU Emacs Lisp Reference Manual": | Emacs Lisp CodingConventions | * Please do not define `C-c LETTER' as a key in your major modes. | These sequences are reserved for users; they are the *only* | sequences reserved for users, so do not block them. | | Instead, define sequences consisting of `C-c' followed by a control | character, a digit, or certain punctuation characters. These | sequences are reserved for major modes. | | Changing all the Emacs major modes to follow this convention was a | lot of work. Abandoning this convention would make that work go | to waste, and inconvenience users. | | * Sequences consisting of `C-c' followed by `{', `}', `<', `>', `:' | or `;' are also reserved for major modes. | | * Sequences consisting of `C-c' followed by any other punctuation | character are allocated for minor modes. Using them in a major | mode is not absolutely prohibited, but if you do that, the major | mode binding may be shadowed from time to time by minor modes. -- Tatsuya Kinoshita