From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Rodgers Newsgroups: gmane.emacs.help Subject: Re: where is the scratch buffer Date: Fri, 31 Mar 2006 09:22:25 -0700 Message-ID: References: <442cc22b$1_1@news.iprimus.com.au> <442cf283$1_1@news.iprimus.com.au> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1143822338 11411 80.91.229.2 (31 Mar 2006 16:25:38 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 31 Mar 2006 16:25:38 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Mar 31 18:25:37 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FPMQ9-0001VU-VJ for geh-help-gnu-emacs@m.gmane.org; Fri, 31 Mar 2006 18:24:22 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FPMQ9-0001D9-CP for geh-help-gnu-emacs@m.gmane.org; Fri, 31 Mar 2006 11:24:21 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FPMPz-0001D4-6h for help-gnu-emacs@gnu.org; Fri, 31 Mar 2006 11:24:11 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FPMPw-0001Cs-So for help-gnu-emacs@gnu.org; Fri, 31 Mar 2006 11:24:09 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FPMPw-0001Cp-La for help-gnu-emacs@gnu.org; Fri, 31 Mar 2006 11:24:08 -0500 Original-Received: from [80.91.229.2] (helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FPMSN-0004yT-3j for help-gnu-emacs@gnu.org; Fri, 31 Mar 2006 11:26:39 -0500 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1FPMPe-0001PX-Tf for help-gnu-emacs@gnu.org; Fri, 31 Mar 2006 18:23:51 +0200 Original-Received: from 207.167.42.60 ([207.167.42.60]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 31 Mar 2006 18:23:50 +0200 Original-Received: from ihs_4664 by 207.167.42.60 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 31 Mar 2006 18:23:50 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-To: help-gnu-emacs@gnu.org Original-Lines: 49 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: 207.167.42.60 User-Agent: Mozilla Thunderbird 0.9 (X11/20041105) X-Accept-Language: en-us, en In-Reply-To: <442cf283$1_1@news.iprimus.com.au> X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:34105 Archived-At: Gary Weselle wrote: > "Wolfram Kraus" wrote in message > news:e0ijsp$qvk$1@ork-un.noris.net... > >>Gary Weselle wrote: >> >>>a problem which I have not found a solution for. >>>when I write something in the scratch buffer and save it as a file, then >>>kill this "file" I lose the scratch buffer, how do I get it back. >> >>Just switch to the *scratch* buffer. Emacs will (re)create every >>non-exiting buffer: >>C-x b *scratch* [RET] > > well, that is the point, there is not *scratch* in the buffer Menu when C-x > b is hit. *scratch* is not there because you implicitly renamed it, by making it visit the file: ,----[ C-h k C-x C-w ] | C-x C-w runs the command write-file | which is an interactive compiled Lisp function in `files'. | (write-file FILENAME &optional CONFIRM) | | Write current buffer into file FILENAME. | This makes the buffer visit that file, and marks it as not modified. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | If you specify just a directory name as FILENAME, that means to use | the default file name but in that directory. You can also yank | the default file name into the minibuffer to edit it, using M-n. | | If the buffer is not already visiting a file, the default file name | for the output file is the buffer name. | | If optional second arg CONFIRM is non-nil, this function | asks for confirmation before overwriting an existing file. | Interactively, confirmation is required unless you supply a prefix argument. `---- (`C-x C-s' does the same thing.) BTW, using the *scratch* buffer for new files is not a good idea, since it is not autosaved (you could lose your work if Emacs crashes -- or more likely, your computer). -- Kevin Rodgers