Index: help-fns.el =================================================================== RCS file: /sources/emacs/emacs/lisp/help-fns.el,v retrieving revision 1.122 diff -u -r1.122 help-fns.el --- help-fns.el 6 Jun 2008 20:02:42 -0000 1.122 +++ help-fns.el 16 Jul 2008 10:19:34 -0000 @@ -104,7 +104,8 @@ ((byte-code-function-p def) (aref def 0)) ((eq (car-safe def) 'lambda) (nth 1 def)) ((and (eq (car-safe def) 'autoload) (not (eq (nth 4 def) 'keymap))) - "[Arg list not available until function definition is loaded.]") + ;;"[Arg list not available until function definition is loaded.]") + "[Arg list not available, click to load function library.]") (t t))) (defun help-make-usage (function arglist) @@ -417,7 +418,18 @@ (high (help-highlight-arguments use doc))) (let ((fill-begin (point))) (insert (car high) "\n") - (fill-region fill-begin (point))) + (fill-region fill-begin (point)) + ;; Add load link for autoloaded functions. + (let ((here (point)) + (load-marker "click to load function library")) + (goto-char fill-begin) + (when (search-forward load-marker here t) + (make-text-button (match-beginning 0) + (match-end 0) + 'action `(lambda (btn) (interactive) + (load-library ,file-name) + (describe-function ',function)))) + (goto-char here))) (setq doc (cdr high)))) (let* ((obsolete (and ;; function might be a lambda construct.