comparison lisp/emacs-lisp/lisp-mode.el @ 92937:9b852833cd26

(emacs-lisp-mode-map): Add menu entries for checkdoc and profiling.
author Dan Nicolaescu <dann@ics.uci.edu>
date Fri, 14 Mar 2008 16:09:39 +0000
parents 48d82b59381a
children d90ba9c4c093
comparison
equal deleted inserted replaced
92936:1814780cd628 92937:9b852833cd26
270 map) 270 map)
271 "Keymap for commands shared by all sorts of Lisp modes.") 271 "Keymap for commands shared by all sorts of Lisp modes.")
272 272
273 (defvar emacs-lisp-mode-map 273 (defvar emacs-lisp-mode-map
274 (let ((map (make-sparse-keymap "Emacs-Lisp")) 274 (let ((map (make-sparse-keymap "Emacs-Lisp"))
275 (menu-map (make-sparse-keymap "Emacs-Lisp"))) 275 (menu-map (make-sparse-keymap "Emacs-Lisp"))
276 (prof-map (make-sparse-keymap)))
276 (set-keymap-parent map lisp-mode-shared-map) 277 (set-keymap-parent map lisp-mode-shared-map)
277 (define-key map "\e\t" 'lisp-complete-symbol) 278 (define-key map "\e\t" 'lisp-complete-symbol)
278 (define-key map "\e\C-x" 'eval-defun) 279 (define-key map "\e\C-x" 'eval-defun)
279 (define-key map "\e\C-q" 'indent-pp-sexp) 280 (define-key map "\e\C-q" 'indent-pp-sexp)
280 (define-key map [menu-bar emacs-lisp] (cons "Emacs-Lisp" menu-map)) 281 (define-key map [menu-bar emacs-lisp] (cons "Emacs-Lisp" menu-map))
282 (define-key menu-map [profiling] (cons "Profiling" prof-map))
283 (define-key prof-map [prof-restall]
284 '(menu-item "Remove Instrumentation for All Functions" elp-restore-all
285 :help "Restore the original definitions of all functions being profiled"))
286 (define-key prof-map [prof-restfunc]
287 '(menu-item "Remove Instrumentation for Function" elp-restore-function
288 :help "Restore an instrumented function to its original definition"))
289
290 (define-key prof-map [sep-rem] '("--"))
291 (define-key prof-map [prof-resall]
292 '(menu-item "Remove Instrumentation for All Functions" elp-reset-all
293 :help "Reset the profiling information for all functions being profiled"))
294 (define-key prof-map [prof-resfunc]
295 '(menu-item "Remove Instrumentation for Function" elp-reset-function
296 :help "Reset the profiling information for a function"))
297 (define-key prof-map [prof-res]
298 '(menu-item "Show Profiling Results" elp-results
299 :help "Display current profiling results"))
300 (define-key prof-map [prof-pack]
301 '(menu-item "Instrument Package" elp-instrument-package
302 :help "Instrument for profiling all function that start with a prefix"))
303 (define-key prof-map [prof-func]
304 '(menu-item "Instrument Function" elp-instrument-function
305 :help "Instrument a function for profiling"))
306 (define-key menu-map [checkdoc]
307 '(menu-item "Check Documentation Strings" checkdock
308 :help "Check documentation strings for style requirements"))
281 (define-key menu-map [edebug-defun] 309 (define-key menu-map [edebug-defun]
282 '(menu-item "Instrument Function for Debugging" edebug-defun 310 '(menu-item "Instrument Function for Debugging" edebug-defun
283 :help "Evaluate the top level form point is in, stepping through with Edebug" 311 :help "Evaluate the top level form point is in, stepping through with Edebug"
284 :keys "C-u C-M-x")) 312 :keys "C-u C-M-x"))
313 (define-key menu-map [separator-byte] '("--"))
285 (define-key menu-map [byte-recompile] 314 (define-key menu-map [byte-recompile]
286 '(menu-item "Byte-recompile Directory..." byte-recompile-directory 315 '(menu-item "Byte-recompile Directory..." byte-recompile-directory
287 :help "Recompile every `.el' file in DIRECTORY that needs recompilation")) 316 :help "Recompile every `.el' file in DIRECTORY that needs recompilation"))
288 (define-key menu-map [emacs-byte-compile-and-load] 317 (define-key menu-map [emacs-byte-compile-and-load]
289 '(menu-item "Byte-compile And Load" emacs-lisp-byte-compile-and-load 318 '(menu-item "Byte-compile And Load" emacs-lisp-byte-compile-and-load