[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: check if these is a buffer to a file
From: |
Andy Stewart |
Subject: |
Re: check if these is a buffer to a file |
Date: |
Mon, 16 Feb 2009 11:50:52 +0800 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) |
Hi,
Kiwon Um <um.kiwon@gmail.com> writes:
> Hello. I'm now writing some lisp codes.
>
> I want to write some codes that kill a buffer if it is already opened
> (visited).
> Is there any predefined function to check the existence of a buffer?
Try to use function `get-buffer'.
Below is document of function `get-buffer':
,----
| (get-buffer BUFFER-OR-NAME)
|
| Return the buffer named BUFFER-OR-NAME.
| BUFFER-OR-NAME must be either a string or a buffer. If BUFFER-OR-NAME
| is a string and there is no buffer with that name, return nil. If
| BUFFER-OR-NAME is a buffer, return it as given.
`----
-- Andy