* How to close or kill *messages* window by using elisp script
@ 2019-06-04 8:08 Budi
2019-06-04 13:16 ` Budi
0 siblings, 1 reply; 6+ messages in thread
From: Budi @ 2019-06-04 8:08 UTC (permalink / raw)
To: help-gnu-emacs
How to close or kill *messages* window by using script of emacs lisp
running this
(quit-window nil "*Messages*")
yields error:
window-normalize-window: *Messages* is not a live window
Sincere useful help is so invaluable
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: How to close or kill *messages* window by using elisp script
2019-06-04 8:08 Budi
@ 2019-06-04 13:16 ` Budi
2019-06-04 13:23 ` Anders Dalskov
2019-06-04 14:56 ` Michael Heerdegen
0 siblings, 2 replies; 6+ messages in thread
From: Budi @ 2019-06-04 13:16 UTC (permalink / raw)
To: help-gnu-emacs
How to close or kill *messages* window by using script of emacs lisp
running this
(quit-window nil "*Messages*")
yields error:
window-normalize-window: *Messages* is not a live window
Sincere useful help is so invaluable
On 6/4/19, Budi <budikusasi@gmail.com> wrote:
> How to close or kill *messages* window by using script of emacs lisp
>
>
> running this
>
> (quit-window nil "*Messages*")
>
> yields error:
>
> window-normalize-window: *Messages* is not a live window
>
> Sincere useful help is so invaluable
>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: How to close or kill *messages* window by using elisp script
2019-06-04 13:16 ` Budi
@ 2019-06-04 13:23 ` Anders Dalskov
2019-06-04 14:56 ` Michael Heerdegen
1 sibling, 0 replies; 6+ messages in thread
From: Anders Dalskov @ 2019-06-04 13:23 UTC (permalink / raw)
To: Budi; +Cc: help-gnu-emacs
(kill-buffer "*Messages*")
Budi writes:
> How to close or kill *messages* window by using script of emacs lisp
>
>
> running this
>
> (quit-window nil "*Messages*")
>
> yields error:
>
> window-normalize-window: *Messages* is not a live window
>
> Sincere useful help is so invaluable
>
> On 6/4/19, Budi <budikusasi@gmail.com> wrote:
>> How to close or kill *messages* window by using script of emacs lisp
>>
>>
>> running this
>>
>> (quit-window nil "*Messages*")
>>
>> yields error:
>>
>> window-normalize-window: *Messages* is not a live window
>>
>> Sincere useful help is so invaluable
>>
--
- Anders
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: How to close or kill *messages* window by using elisp script
2019-06-04 13:16 ` Budi
2019-06-04 13:23 ` Anders Dalskov
@ 2019-06-04 14:56 ` Michael Heerdegen
1 sibling, 0 replies; 6+ messages in thread
From: Michael Heerdegen @ 2019-06-04 14:56 UTC (permalink / raw)
To: Budi; +Cc: help-gnu-emacs
Budi <budikusasi@gmail.com> writes:
> running this
>
> (quit-window nil "*Messages*")
>
> yields error:
>
> window-normalize-window: *Messages* is not a live window
You can get the window with `get-buffer-window-list' (a list cause there
can be more than one of course).
[ Dunno how your workflow is, but you might also like "winner.el" which
allows to go back in window config history (`winner-undo',
`winner-redo'). ]
Regards,
Michael.
^ permalink raw reply [flat|nested] 6+ messages in thread
* How to close or kill *messages* window by using elisp script
@ 2019-06-05 7:22 martin rudalics
2019-06-05 7:52 ` Emanuel Berg via help-gnu-emacs
0 siblings, 1 reply; 6+ messages in thread
From: martin rudalics @ 2019-06-05 7:22 UTC (permalink / raw)
To: budikusasi; +Cc: help-gnu-emacs
> How to close or kill *messages* window by using script of emacs lisp
>
>
> running this
>
> (quit-window nil "*Messages*")
>
> yields error:
>
> window-normalize-window: *Messages* is not a live window
The doc-string of 'quit-window' says
(quit-window &optional KILL WINDOW)
Quit WINDOW and bury its buffer.
WINDOW must be a live window and defaults to the selected one.
but *Messages* is a string most likely denoting a buffer. Try
running
(let ((window (get-buffer-window "*Messages*")))
(when (window-live-p window)
(quit-window nil window)))
instead.
martin
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: How to close or kill *messages* window by using elisp script
2019-06-05 7:22 How to close or kill *messages* window by using elisp script martin rudalics
@ 2019-06-05 7:52 ` Emanuel Berg via help-gnu-emacs
0 siblings, 0 replies; 6+ messages in thread
From: Emanuel Berg via help-gnu-emacs @ 2019-06-05 7:52 UTC (permalink / raw)
To: help-gnu-emacs
martin rudalics wrote:
>> How to close or kill *messages* window [...]
>
> The doc-string of 'quit-window' says [...]
Excuse me for asking, but why would anyone want
to kill *Messages*?
It will just reappear with the next message,
which should be like instantly!
If you close it all the time, and having it
appear all the time might even imply a small
but still overhead penalty...
So why do it?
--
underground experts united
http://user.it.uu.se/~embe8573
https://dataswamp.org/~incal
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2019-06-05 7:52 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-05 7:22 How to close or kill *messages* window by using elisp script martin rudalics
2019-06-05 7:52 ` Emanuel Berg via help-gnu-emacs
-- strict thread matches above, loose matches on Subject: below --
2019-06-04 8:08 Budi
2019-06-04 13:16 ` Budi
2019-06-04 13:23 ` Anders Dalskov
2019-06-04 14:56 ` Michael Heerdegen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).