[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master f29ea44 2/2: Clarify describe-bindings code slightly
From: |
Lars Ingebrigtsen |
Subject: |
master f29ea44 2/2: Clarify describe-bindings code slightly |
Date: |
Sun, 31 Oct 2021 18:25:35 -0400 (EDT) |
branch: master
commit f29ea4418f9352df6ecb7118228e9825b92b5533
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>
Clarify describe-bindings code slightly
* lisp/help.el (describe-bindings): Clarify code slightly.
---
lisp/help.el | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/lisp/help.el b/lisp/help.el
index af68c57..afb91a5 100644
--- a/lisp/help.el
+++ b/lisp/help.el
@@ -567,6 +567,8 @@ To record all your input, use `open-dribble-file'."
:group 'help
:version "29.1")
+(declare-function outline-hide-subtree "outline")
+
(defun describe-bindings (&optional prefix buffer)
"Display a buffer showing a list of all defined keys, and their definitions.
The keys are displayed in order of precedence.
@@ -598,9 +600,8 @@ or a buffer name."
(goto-char (point-min))
(let ((inhibit-read-only t))
;; Hide the longest body
- (when (and (re-search-forward "Key translations" nil t)
- (fboundp 'outline-cycle))
- (outline-cycle))
+ (when (re-search-forward "Key translations" nil t)
+ (outline-hide-subtree))
;; Hide ^Ls.
(while (search-forward "\n\f\n" nil t)
(put-text-property (1+ (match-beginning 0)) (1- (match-end 0))