[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#43813: [BUG] current-message not working with minibuffer-message
From: |
pinkanon pinkanon |
Subject: |
bug#43813: [BUG] current-message not working with minibuffer-message |
Date: |
Mon, 05 Oct 2020 18:56:12 +0300 |
The echo area is also used to display the minibuffer
From: pinkanon pinkanon <pinkanon.pinkanon@yandex.com>
Date: Mon, 05 Oct 2020 10:34:49 +0300
Eval this:
(progn (minibuffer-message "hello world") (print (format "current message: %s" (current-message))))
to get "current message: nil" in the *Messages*. If message is used in place of minibuffer message, works
as expected.
I think your expectations are incorrect, and Emacs works correctly in
this case.
The reason I think current-message should work with minibuffer-message is due to its docstring: "Return the
string currently displayed in the echo area, or nil if none."
The echo area and the minibuffer are two different buffers. They both
use the same mini-window to display their text, but they are not the
same.
Sorry, should've included this, I am basing my assumption on the manual
https://www.gnu.org/software/emacs/manual/html_node/emacs/Echo-Area.html
"The echo area is used to display the minibuffer".
Hmm. I guess I just want the contents of the mini window then, whether it was produced by message or minibuffer-message. And the realization that it's a window yields the following code, but it's not working...
(progn
(minibuffer-message "hello world")
(with-selected-window (minibuffer-window)
(print (format "ms: %s" (buffer-substring-no-properties (point-min) (point-max))))))
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message,
pinkanon pinkanon <=
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/05
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/06
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/06
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/06
- bug#43813: [BUG] current-message not working with minibuffer-message, Eli Zaretskii, 2020/10/06
- bug#43813: [BUG] current-message not working with minibuffer-message, pinkanon pinkanon, 2020/10/06