comparison lisp/packages/func-menu.el @ 134:34a5b81f86ba r20-2b1

Import from CVS: tag r20-2b1
author cvs
date Mon, 13 Aug 2007 09:30:11 +0200
parents 9f59509498e1
children 59463afc5666
comparison
equal deleted inserted replaced
133:b27e67717092 134:34a5b81f86ba
212 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 212 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
213 ;;;;;;;;;;;;;;;;;;;;;;;; Environment Initialisation ;;;;;;;;;;;;;;;;;;;;;; 213 ;;;;;;;;;;;;;;;;;;;;;;;; Environment Initialisation ;;;;;;;;;;;;;;;;;;;;;;
214 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 214 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
215 215
216 (defconst fume-version "2.45") 216 (defconst fume-version "2.45")
217
218 (defgroup fume nil
219 "Jump to a function within a buffer."
220 :tag "Func Menu"
221 :group 'tools)
217 222
218 (defconst fume-developer "David Hughes <ukchugd@ukpmr.cs.philips.nl>") 223 (defconst fume-developer "David Hughes <ukchugd@ukpmr.cs.philips.nl>")
219 224
220 (defun fume-about () 225 (defun fume-about ()
221 (interactive) 226 (interactive)
392 397
393 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 398 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
394 ;;;;;;;;;;;;;;;;;;;;;;;;;; Customizable Variables ;;;;;;;;;;;;;;;;;;;;;;;; 399 ;;;;;;;;;;;;;;;;;;;;;;;;;; Customizable Variables ;;;;;;;;;;;;;;;;;;;;;;;;
395 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 400 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
396 401
397 (defvar fume-auto-position-popup t 402 (defcustom fume-auto-position-popup t
398 "*Set to nil if you don't want the menu to appear in the corner of the window 403 "*Set to nil if you don't want the menu to appear in the corner of the window
399 in which case it will track the mouse position instead.") 404 in which case it will track the mouse position instead."
405 :type 'boolean
406 :group 'fume)
400 407
401 (fume-defvar-local fume-display-in-modeline-p t 408 (fume-defvar-local fume-display-in-modeline-p t
402 "*Set to nil if you don't want the function name appearing in the modeline. 409 "*Set to nil if you don't want the function name appearing in the modeline.
403 If your modeline is already full, then you can set this variable to something 410 If your modeline is already full, then you can set this variable to something
404 besides nil or t and the current function will replace the normal 411 besides nil or t and the current function will replace the normal
407 Note, this is a buffer-local variable.") 414 Note, this is a buffer-local variable.")
408 415
409 (defvar fume-buffer-name "*Function List*" 416 (defvar fume-buffer-name "*Function List*"
410 "Name of buffer used to list functions when fume-list-functions called") 417 "Name of buffer used to list functions when fume-list-functions called")
411 418
412 (defvar fume-menubar-menu-name "Functions" 419 (defcustom fume-menubar-menu-name "Functions"
413 "*Set this to the string you want to appear in the menubar") 420 "*Set this to the string you want to appear in the menubar"
421 :type 'string
422 :group 'fume)
414 423
415 ;;; Bob Weiner <weiner@infodock.com> 424 ;;; Bob Weiner <weiner@infodock.com>
416 (defvar fume-menu-path nil 425 (defvar fume-menu-path nil
417 "Menubar menu under which the function menu should be installed. 426 "Menubar menu under which the function menu should be installed.
418 Nil means install it on the menubar itself. Otherwise, it should be a list 427 Nil means install it on the menubar itself. Otherwise, it should be a list
419 of strings, each string names a successively deeper menu under which the 428 of strings, each string names a successively deeper menu under which the
420 new menu should be located.") 429 new menu should be located.")
421 430
422 (defvar fume-menubar-menu-location "Buffers" 431 (defcustom fume-menubar-menu-location "Buffers"
423 "*Set this nil if you want the menu to appear last on the menubar. 432 "*Set this nil if you want the menu to appear last on the menubar.
424 Otherwise set this to the menu you want \"Functions\" to appear in front of.") 433 Otherwise set this to the menu you want \"Functions\" to appear in front of."
425 434 :type '(choice (const :tag "Last" nil) (string :format "%v"))
426 (defvar fume-max-items 24 435 :group 'fume)
427 "*Maximum number of elements in a function (sub)menu.") 436
428 437 (defcustom fume-max-items 24
429 (defvar fume-fn-window-position 3 438 "*Maximum number of elements in a function (sub)menu."
439 :type 'integer
440 :group 'fume)
441
442 (defcustom fume-fn-window-position 3
430 "*Number of lines from top of window at which to show function. 443 "*Number of lines from top of window at which to show function.
431 If nil, display function start from the centre of the window.") 444 If nil, display function start from the centre of the window."
432 445 :type '(choice (const :tag "Center" nil) integer)
433 (defvar fume-index-method 3 446 :group 'fume)
447
448 (defcustom fume-index-method 3
434 "*Set this to the method number you want used. 449 "*Set this to the method number you want used.
435 450
436 Methods currently supported: 451 Methods currently supported:
437 0 = if you want submenu names to be numbered 452 0 = if you want submenu names to be numbered
438 1 = if you want submenu range indicated by first character 453 1 = if you want submenu range indicated by first character
439 2 = if you want submenu range indicated by first 12 characters 454 2 = if you want submenu range indicated by first 12 characters
440 3 = if you want submenu range indicated by as many characters as needed") 455 3 = if you want submenu range indicated by as many characters as needed"
441 456 :type '(radio (const :tag "Numbered" 0)
442 (defvar fume-scanning-message "Scanning buffer... (%3d%%)" 457 (const :tag "Indicated by first character" 1)
458 (const :tag "Indicated by first 12 characters" 2)
459 (const :tag "Indicated by as many characters as needed" 3))
460 :group 'fume)
461
462 (defcustom fume-scanning-message "Scanning buffer... (%3d%%)"
443 "*Set to nil if you don't want progress messages during manual scanning 463 "*Set to nil if you don't want progress messages during manual scanning
444 of the buffer.") 464 of the buffer."
445 465 :type '(choice (const :tag "None" nil) string)
446 (defvar fume-rescanning-message nil 466 :group 'fume)
467
468 (defcustom fume-rescanning-message nil
447 "*Set to non-nil if you want progress messages during automatic scanning 469 "*Set to non-nil if you want progress messages during automatic scanning
448 of the buffer. For example \"Re-Scanning buffer...\"") 470 of the buffer. For example \"Re-Scanning buffer...\""
471 :type '(choice (const :tag "None" nil) string)
472 :group 'fume)
449 473
450 (defvar fume-rescan-trigger-counter-buffer-size 10000 474 (defvar fume-rescan-trigger-counter-buffer-size 10000
451 "Used to tune the frequency of automatic checks on the buffer. 475 "Used to tune the frequency of automatic checks on the buffer.
452 The function fume-rescan-buffer-trigger only works whenever the value of the 476 The function fume-rescan-buffer-trigger only works whenever the value of the
453 variable fume-rescan-trigger-counter reaches zero, whereupon it gets reset to 477 variable fume-rescan-trigger-counter reaches zero, whereupon it gets reset to