(gettext "key binding\n--- -------\n")))
(buffer (current-buffer))
(minor minor-mode-map-alist)
+ (extent-maps (mapcar-extents
+ 'extent-keymap
+ nil (current-buffer) (point) (point) nil 'keymap))
(local (current-local-map))
(shadow '()))
(set-buffer standard-output)
+ (while extent-maps
+ (insert "Bindings for Text Region:\n"
+ heading)
+ (describe-bindings-internal
+ (car extent-maps) nil shadow prefix mouse-only-p)
+ (insert "\n")
+ (setq shadow (cons (car extent-maps) shadow)
+ extent-maps (cdr extent-maps)))
(while minor
(let ((sym (car (car minor)))
(map (cdr (car minor))))
(stringp Installation-string))
(with-displaying-help-buffer
(lambda ()
- (princ Installation-string))
+ (princ
+ (if (fboundp 'decode-coding-string)
+ (decode-coding-string Installation-string 'automatic-conversion)
+ Installation-string)))
"Installation")
(error "No Installation information available.")))
(format (gettext "Describe function (default %s): ")
fn)
(gettext "Describe function: "))
- obarray 'fboundp t nil 'function-history))))
- (list (if (equal val "") fn (intern val)))))
+ obarray 'fboundp t nil 'function-history
+ (symbol-name fn)))))
+ (list (intern val))))
(with-displaying-help-buffer
(lambda ()
(describe-function-1 function)
This function is used by `describe-function-1' to list function
arguments in the standard Lisp style."
- (let* ((fndef (indirect-function function))
+ (let* ((fnc (indirect-function function))
+ (fndef (if (eq (car-safe fnc) 'macro)
+ (cdr fnc)
+ fnc))
(arglist
- (cond ((compiled-function-p fndef)
- (compiled-function-arglist fndef))
- ((eq (car-safe fndef) 'lambda)
- (nth 1 fndef))
- ((subrp fndef)
- (let* ((doc (documentation function))
- (args (and (string-match
- "[\n\t ]*\narguments: ?(\\(.*\\))\n?\\'"
- doc)
- (match-string 1 doc))))
- ;; If there are no arguments documented for the
- ;; subr, rather don't print anything.
- (cond ((null args) t)
- ((equal args "") nil)
- (args))))
- (t t))))
+ (cond ((compiled-function-p fndef)
+ (compiled-function-arglist fndef))
+ ((eq (car-safe fndef) 'lambda)
+ (nth 1 fndef))
+ ((subrp fndef)
+ (let* ((doc (documentation function))
+ (args (and (string-match
+ "[\n\t ]*\narguments: ?(\\(.*\\))\n?\\'"
+ doc)
+ (match-string 1 doc))))
+ ;; If there are no arguments documented for the
+ ;; subr, rather don't print anything.
+ (cond ((null args) t)
+ ((equal args "") nil)
+ (args))))
+ (t t))))
(cond ((listp arglist)
(prin1-to-string
(cons function (mapcar (lambda (arg)
(if v
(format "Describe variable (default %s): " v)
(gettext "Describe variable: "))
- obarray 'boundp t nil 'variable-history))))
- (list (if (equal val "") v (intern val)))))
+ obarray 'boundp t nil 'variable-history
+ (symbol-name v)))))
+ (list (intern val))))
(with-displaying-help-buffer
(lambda ()
(let ((origvar variable)
(if cmd (princ " ")))))
(terpri))))))
-;; Stop gap for 21.0 untill we do help-char etc properly.
+;; Stop gap for 21.0 until we do help-char etc properly.
(defun help-keymap-with-help-key (keymap form)
"Return a copy of KEYMAP with an help-key binding according to help-char
invoking FORM like help-form. An existing binding is not overridden.