Hi,
I wanted to add an menu item for uncommentting out region under
Emacs-Lisp in lisp mode. So I added the following code in lisp-mode.el
under my emacs installation directory (in C:\emacs\lisp\emacs-lisp to be
exact).
...
(define-key map [separator-eval] '("--"))
(define-key map [eval-buffer] '("Evaluate Buffer" . eval-buffer))
(define-key map [eval-region] '("Evaluate Region" . eval-region))
(define-key map [eval-sexp] '("Evaluate Last S-expression" .
eval-last-sexp))
(define-key map [separator-format] '("--"))
(define-key map [uncomment-region] '("Uncomment Out Region" .
uncomment-region));; added
(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 'eval-region 'menu-enable 'mark-active)
(put 'comment-region 'menu-enable 'mark-active)
(put 'uncomment-region 'menu-enable 'mark-active) ;;added
(put 'indent-region 'menu-enable 'mark-active)...
of course, I didn't forget to byte-compile the file. But the menu items
don't seem to be taking effect after this. Am I missing something?