|
From: | Tim Johnson |
Subject: | Re: Binding Keymap prefix to Major Mode |
Date: | Sat, 02 Apr 2005 12:57:01 -0900 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.2) Gecko/20040805 Netscape/7.2 |
Stefan Monnier wrote:
(defvar rebol-keymap (make-sparse-keymap) "Rebol mode keymap") (defcustom rebol-keymap-prefix [(control ?')] "*Keymap prefix string for rebol-keymap" :type 'string :group 'rebol) (local-set-key rebol-keymap-prefix rebol-keymap) (define-key rebol-keymap "b" 'previous-rebol-definition)Seeing the code above, I *strongly* suggest you google for "sample-mode.el" and try to start from that instead. Stefan
Hello Stefan:Thank you very much,that is something that I have been looking for - an example of how to set up a mode.
FYI: The solution has proven to be just to change (use-local-map rebol-keymap) ;; to (local-set-key rebol-keymap-prefix rebol-keymap) Now keybindings work as I would expect them to. I have googled for "sample-mode.el" and have found only two references, but no code. In fact what I find are emails from you and since you appear to be the author, I would deeply appreciate it if you could provide a link for this file. Regards Tim Johnson ---------------------------- Senior Programer/Analyst Alaska Internet Solutions
[Prev in Thread] | Current Thread | [Next in Thread] |