Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
d536293f
Commit
d536293f
authored
Jul 16, 1994
by
Richard M. Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(print-help-return-message): If help buffer is a
special display buffer, say nothing about how to switch back.
parent
7f410bb7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
34 additions
and
10 deletions
+34
-10
lisp/help.el
lisp/help.el
+34
-10
No files found.
lisp/help.el
View file @
d536293f
...
@@ -136,16 +136,40 @@
...
@@ -136,16 +136,40 @@
Computes a message and applies the optional argument FUNCTION to it.
Computes a message and applies the optional argument FUNCTION to it.
If FUNCTION is nil, applies `message' to it, thus printing it."
If FUNCTION is nil, applies `message' to it, thus printing it."
(
and
(
not
(
get-buffer-window
standard-output
))
(
and
(
not
(
get-buffer-window
standard-output
))
(
funcall
(
or
function
'message
)
(
let
((
first-message
(
concat
(
cond
((
or
(
member
(
buffer-name
standard-output
)
(
substitute-command-keys
special-display-buffer-names
)
(
if
(
one-window-p
t
)
(
let
(
found
(
if
pop-up-windows
(
tail
special-display-regexps
)
"Type \\[delete-other-windows] to remove help window."
(
name
(
buffer-name
standard-output
)))
"Type \\[switch-to-buffer] RET to remove help window."
)
(
while
(
and
tail
(
not
found
))
"Type \\[switch-to-buffer-other-window] RET to restore the other window."
))
(
if
(
string-match
(
car
tail
)
name
)
(
substitute-command-keys
(
setq
found
t
))
" \\[scroll-other-window] to scroll the help."
)))))
(
setq
tail
(
cdr
tail
)))
found
))
;; If the help output buffer is a special display buffer,
;; don't say anything about how to get rid of it.
;; First of all, the user will do that with the window
;; manager, not with Emacs.
;; Secondly, the buffer has not been displayed yet,
;; so we don't know whether its frame will be selected.
;; Even the message about scrolling the help
;; might be wrong, but it seems worth showing it anyway.
nil
)
((
not
(
one-window-p
t
))
"Type \\[switch-to-buffer-other-window] RET to restore the other window."
)
(
pop-up-windows
"Type \\[delete-other-windows] to remove help window."
)
(
t
"Type \\[switch-to-buffer] RET to remove help window."
))))
(
funcall
(
or
function
'message
)
(
concat
(
if
first-message
(
substitute-command-keys
first-message
)
""
)
(
if
first-message
" "
""
)
(
substitute-command-keys
"\\[scroll-other-window] to scroll the help."
))))))
(
defun
describe-key
(
key
)
(
defun
describe-key
(
key
)
"Display documentation of the function invoked by KEY. KEY is a string."
"Display documentation of the function invoked by KEY. KEY is a string."
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment