diff options
author | Dave Love <fx@gnu.org> | 2000-11-14 14:33:29 +0000 |
---|---|---|
committer | Dave Love <fx@gnu.org> | 2000-11-14 14:33:29 +0000 |
commit | d3461e8fd00ca874f89a9a2ea9db6823612cb5cc (patch) | |
tree | ca1073b823191ce5c293274ae863b855ca28356d /lisp/progmodes | |
parent | 88f0a1eb891365a60559174f75ed2631070b00bf (diff) | |
download | emacs-d3461e8fd00ca874f89a9a2ea9db6823612cb5cc.tar.gz |
(scheme-program-name): New variable
(originally in cmuscheme).
Diffstat (limited to 'lisp/progmodes')
-rw-r--r-- | lisp/progmodes/scheme.el | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/lisp/progmodes/scheme.el b/lisp/progmodes/scheme.el index 127efad288a..73ddd7c89fe 100644 --- a/lisp/progmodes/scheme.el +++ b/lisp/progmodes/scheme.el @@ -171,28 +171,22 @@ (defvar scheme-mode-line-process "") -(defvar scheme-mode-map nil - "Keymap for Scheme mode. -All commands in `lisp-mode-shared-map' are inherited by this map.") - -(unless scheme-mode-map +(defvar scheme-mode-map (let ((map (make-sparse-keymap "Scheme"))) - (setq scheme-mode-map (make-sparse-keymap)) - (set-keymap-parent scheme-mode-map lisp-mode-shared-map) - (define-key scheme-mode-map [menu-bar] (make-sparse-keymap)) - (define-key scheme-mode-map [menu-bar scheme] - (cons "Scheme" map)) - (define-key map [run-scheme] '("Run Inferior Scheme" . run-scheme)) - (define-key map [uncomment-region] - '("Uncomment Out Region" . (lambda (beg end) - (interactive "r") - (comment-region beg end '(4))))) - (define-key map [comment-region] '("Comment Out Region" . comment-region)) - (define-key map [indent-region] '("Indent Region" . indent-region)) - (define-key map [indent-line] '("Indent Line" . lisp-indent-line)) - (put 'comment-region 'menu-enable 'mark-active) - (put 'uncomment-region 'menu-enable 'mark-active) - (put 'indent-region 'menu-enable 'mark-active))) + (set-keymap-parent map lisp-mode-shared-map) + (define-key map [menu-bar scheme] + (cons "Scheme" + ;; Copy the shared menu rather than inheriting it, so that + ;; we can put the Scheme-specific items at the end. + (let ((menu (copy-keymap lisp-shared-menu))) + (define-key-after menu [s1] '("--")) + (define-key-after menu [run-scheme] + '("Run Inferior Scheme" . run-scheme)) + menu))) + map) + "Keymap for Scheme mode. +All items in `lisp-mode-shared-map' and `lisp-shared-menu' are copied +into this map.") ;; Used by cmuscheme (defun scheme-mode-commands (map) @@ -264,6 +258,12 @@ See `run-hooks'." :type 'hook :group 'scheme) +;; This is shared by cmuscheme and xscheme. +(defcustom scheme-program-name "scheme" + "*Program invoked by the `run-scheme' command." + :type 'string + :group 'scheme) + (defvar dsssl-imenu-generic-expression ;; Perhaps this should also look for the style-sheet DTD tags. I'm ;; not sure it's the best way to organize it; perhaps one type |