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: How to get rid of *GNU Emacs* buffer on start-up? Date: Thu, 25 Sep 2008 22:52:31 -0600 Message-ID: References: <873ajzwoqu.fsf@kobe.laptop> <823901dd-c54c-4e3b-b6ad-512d52724a46@z11g2000prl.googlegroups.com> <87ljxoffs6.fsf@atthis.clsnet.nl> <31ddf1ec-5b63-4005-9c9e-d0006a44408e@s9g2000prg.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1222404804 21745 80.91.229.12 (26 Sep 2008 04:53:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 26 Sep 2008 04:53:24 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Sep 26 06:54:21 2008 connect(): Connection refused Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Kj5LR-0007Xx-Bg for geh-help-gnu-emacs@m.gmane.org; Fri, 26 Sep 2008 06:54:21 +0200 Original-Received: from localhost ([127.0.0.1]:53257 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kj5KO-0005PQ-N5 for geh-help-gnu-emacs@m.gmane.org; Fri, 26 Sep 2008 00:53:16 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Kj5Jr-0005Ot-V5 for help-gnu-emacs@gnu.org; Fri, 26 Sep 2008 00:52:43 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Kj5Jq-0005Nb-1X for help-gnu-emacs@gnu.org; Fri, 26 Sep 2008 00:52:43 -0400 Original-Received: from [199.232.76.173] (port=34087 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Kj5Jp-0005NY-S1 for help-gnu-emacs@gnu.org; Fri, 26 Sep 2008 00:52:41 -0400 Original-Received: from main.gmane.org ([80.91.229.2]:60327 helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1Kj5Jp-0002HQ-Hw for help-gnu-emacs@gnu.org; Fri, 26 Sep 2008 00:52:41 -0400 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1Kj5Ji-0001s0-La for help-gnu-emacs@gnu.org; Fri, 26 Sep 2008 04:52:34 +0000 Original-Received: from c-67-161-145-183.hsd1.co.comcast.net ([67.161.145.183]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 26 Sep 2008 04:52:34 +0000 Original-Received: from kevin.d.rodgers by c-67-161-145-183.hsd1.co.comcast.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 26 Sep 2008 04:52:34 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 60 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: c-67-161-145-183.hsd1.co.comcast.net User-Agent: Thunderbird 2.0.0.16 (Macintosh/20080707) In-Reply-To: <31ddf1ec-5b63-4005-9c9e-d0006a44408e@s9g2000prg.googlegroups.com> X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) 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:58095 Archived-At: Xah Lee wrote: > On Sep 24, 12:35 am, Kevin Rodgers wrote: >> Kevin Rodgers wrote: >> Nikolaj Schumacher's recent message prompted me to check that little >> hack, and I see that it's got a typo. It should be: >> >> (defun switch-to-new-buffer () >> "Switch to a new *scratch* buffer." >> (interactive) >> (switch-to-buffer (generate-new-buffer "*scratch*")) >> (setq buffer-offer-save t)) >> >> You might like (auto-save-mode 1) in there as well. > > A new buffer is not a existing buffer, so the switch in the name is > unfit. Also, since the function's purpose is creating a new *scratch*, > you should have that in the name to reflect the fact. In Emacs, you can create a buffer without making it the current buffer and/or without displaying it. Emacs uses the verb "switch" to mean "display the buffer and select the window in which it is displayed". > So, given your code, one step of improvement is to change the name to > new-scratch-buffer or create-scratch-buffer. Fair enough: switch-to-new-scratch-buffer. > But, as i detailed, since scratch is simply a new buffer, and since > now you can create multiple scratches, it ceases to be one special > buffer emacs called *scratch*. The *scratch* buffer _is_ special: If you kill it, it is regenerated, and its major mode is determined by initial-major-mode. No other buffer respects that variable. In contrast, the major mode of the new *scratch* buffers is determined by default-major-mode. > So, this comes back to my original > suggestion, that it might simply be better to just have create-new- > buffer. And, if you agree this far, then since you now have a > mechanism to create new buffers proper, and the few emacs developers > agree that *scratch* has problems albeit minor one, we might simply at > this point get rid of the *scratch* because create-new-buffer > completely covers its functionality. I do not agree that it would be better to eliminate the *scratch* buffer in deference to a create-new-buffer command. I do not know which Emacs developers think *scratch* has problems, or what those alleged problems are. You can pry the *scratch* buffer from my cold, dead fingers. :-) > This is exactly what is proposed in my article, alone with code. > See > http://xahlee.org/emacs/modernization_scratch_buffer.html -- Kevin Rodgers Denver, Colorado, USA