[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: `last-message' variable ?
From: |
Magnus Henoch |
Subject: |
Re: `last-message' variable ? |
Date: |
Tue, 16 May 2006 10:45:25 +0200 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (berkeley-unix) |
Bastien <bastien@xxx.fr> writes:
> Just guessing, i thought Emacs would have a `last-message' variable,
> in case we want to fetch the last message quickly. Apparently, this
> is not the case.
>
> How do i get the last message string ?
>
> What about implementing this ?
I have worked around it like this:
(defun last-message ()
"Display last message from *Messages* buffer."
(interactive)
(with-current-buffer "*Messages*"
(save-excursion
(goto-char (point-max))
(previous-line)
(message "%s" (buffer-substring (point) (1- (point-max)))))))
Magnus
- `last-message' variable ?, Bastien, 2006/05/15
- Re: `last-message' variable ?,
Magnus Henoch <=
- Message not available
- Re: `last-message' variable ?, Bastien, 2006/05/16
- Re: `last-message' variable ?, Tim X, 2006/05/16
- Re: `last-message' variable ?, Bastien, 2006/05/16
- Re: `last-message' variable ?, Kim F. Storm, 2006/05/16
- Message not available
- Re: `last-message' variable ?, Bastien, 2006/05/16
- RE: `last-message' variable ?, Drew Adams, 2006/05/16