diff options
author | Stefan Kangas <stefan@marxist.se> | 2021-03-01 04:21:11 +0100 |
---|---|---|
committer | Stefan Kangas <stefan@marxist.se> | 2021-03-01 04:38:38 +0100 |
commit | 5684f7995d07496fea4c38133dda81ee93ec9948 (patch) | |
tree | 76c51cd821375ede04cde6a9faecc13ea453a2ca /lisp/emacs-lisp | |
parent | 8bdaac34579fd270b5ba5403711e626fb03587d0 (diff) | |
download | emacs-5684f7995d07496fea4c38133dda81ee93ec9948.tar.gz emacs-5684f7995d07496fea4c38133dda81ee93ec9948.tar.bz2 emacs-5684f7995d07496fea4c38133dda81ee93ec9948.zip |
Convert various menus to easymenu
* lisp/emacs-lisp/lisp-mode.el (lisp-mode-map): Move menu from
here...
(lisp-mode-menu): ...to here, and convert to easymenu.
* lisp/progmodes/elisp-mode.el (lisp-interaction-mode-map): Move
menu definition from here...
(lisp-interaction-mode-menu): ...to here, and convert to easymenu.
* lisp/replace.el (occur-menu-map): Convert to easymenu.
Diffstat (limited to 'lisp/emacs-lisp')
-rw-r--r-- | lisp/emacs-lisp/lisp-mode.el | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/lisp/emacs-lisp/lisp-mode.el b/lisp/emacs-lisp/lisp-mode.el index 54089c4bc69..257ac7412e8 100644 --- a/lisp/emacs-lisp/lisp-mode.el +++ b/lisp/emacs-lisp/lisp-mode.el @@ -740,25 +740,24 @@ font-lock keywords will not be case sensitive." ;;; Generic Lisp mode. (defvar lisp-mode-map - (let ((map (make-sparse-keymap)) - (menu-map (make-sparse-keymap "Lisp"))) + (let ((map (make-sparse-keymap))) (set-keymap-parent map lisp-mode-shared-map) (define-key map "\e\C-x" 'lisp-eval-defun) (define-key map "\C-c\C-z" 'run-lisp) - (bindings--define-key map [menu-bar lisp] (cons "Lisp" menu-map)) - (bindings--define-key menu-map [run-lisp] - '(menu-item "Run inferior Lisp" run-lisp - :help "Run an inferior Lisp process, input and output via buffer `*inferior-lisp*'")) - (bindings--define-key menu-map [ev-def] - '(menu-item "Eval defun" lisp-eval-defun - :help "Send the current defun to the Lisp process made by M-x run-lisp")) - (bindings--define-key menu-map [ind-sexp] - '(menu-item "Indent sexp" indent-sexp - :help "Indent each line of the list starting just after point")) map) "Keymap for ordinary Lisp mode. All commands in `lisp-mode-shared-map' are inherited by this map.") +(easy-menu-define lisp-mode-menu lisp-mode-map + "Menu for ordinary Lisp mode." + '("Lisp" + ["Indent sexp" indent-sexp + :help "Indent each line of the list starting just after point"] + ["Eval defun" lisp-eval-defun + :help "Send the current defun to the Lisp process made by M-x run-lisp"] + ["Run inferior Lisp" run-lisp + :help "Run an inferior Lisp process, input and output via buffer `*inferior-lisp*'"])) + (define-derived-mode lisp-mode lisp-data-mode "Lisp" "Major mode for editing Lisp code for Lisps other than GNU Emacs Lisp. Commands: |