diff options
author | Richard M. Stallman <rms@gnu.org> | 2005-04-26 10:59:44 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 2005-04-26 10:59:44 +0000 |
commit | 0a3e46de17584a2bd6045895615d83f9127681f0 (patch) | |
tree | 2d5c574df4db37f70b04f53203a36a030cfd0656 /lisp/emacs-lisp/eldoc.el | |
parent | 2c705f25481eb44b9eb33b414528f0f2856ffc99 (diff) |
(eldoc-mode): Doc fix.
(eldoc-documentation-function):
Renamed from eldoc-print-current-symbol-info-function. Calls changed.
Diffstat (limited to 'lisp/emacs-lisp/eldoc.el')
-rw-r--r-- | lisp/emacs-lisp/eldoc.el | 22 |
1 files changed, 8 insertions, 14 deletions
diff --git a/lisp/emacs-lisp/eldoc.el b/lisp/emacs-lisp/eldoc.el index f31dafb7b1..29167c7081 100644 --- a/lisp/emacs-lisp/eldoc.el +++ b/lisp/emacs-lisp/eldoc.el @@ -139,16 +139,11 @@ truncated to make more of the arglist or documentation string visible." ;;;###autoload (define-minor-mode eldoc-mode "Toggle ElDoc mode on or off. -Show the defined parameters for the elisp function near point. - -For the emacs lisp function at the beginning of the sexp which point is -within, show the defined parameters for the function in the echo area. -This information is extracted directly from the function or macro if it is -in pure lisp. If the emacs function is a subr, the parameters are obtained -from the documentation string if possible. - -If point is over a documented variable, print that variable's docstring -instead. +In ElDoc mode, the echo area displays information about a +function or variable in the text where point is. If point is +on a documented variable, it displays that variable's doc string. +Otherwise it displays the argument list of the function called +in the expression point is on. With prefix ARG, turn ElDoc mode on if and only if ARG is positive." :group 'eldoc :lighter eldoc-minor-mode-string @@ -167,7 +162,6 @@ With prefix ARG, turn ElDoc mode on if and only if ARG is positive." (eldoc-mode 1)) -;; Idle timers are part of Emacs 19.31 and later. (defun eldoc-schedule-timer () (or (and eldoc-timer (memq eldoc-timer timer-idle-list)) @@ -235,7 +229,7 @@ With prefix ARG, turn ElDoc mode on if and only if ARG is positive." (not (eq (selected-window) (minibuffer-window))))) -(defvar eldoc-print-current-symbol-info-function nil +(defvar eldoc-documentation-function nil "If non-nil, function to call to return doc string. The function of no args should return a one-line string for displaying doc about a function etc. appropriate to the context around point. @@ -249,8 +243,8 @@ Emacs Lisp mode) that support Eldoc.") (defun eldoc-print-current-symbol-info () (condition-case err (and (eldoc-display-message-p) - (if eldoc-print-current-symbol-info-function - (eldoc-message (funcall eldoc-print-current-symbol-info-function)) + (if eldoc-documentation-function + (eldoc-message (funcall eldoc-documentation-function)) (let* ((current-symbol (eldoc-current-symbol)) (current-fnsym (eldoc-fnsym-in-current-sexp)) (doc (cond |