From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Barry Margolin Newsgroups: gmane.emacs.help Subject: Re: kill-region without modifying the kill ring Date: Fri, 25 Sep 2015 11:21:34 -0400 Organization: A noiseless patient Spider Message-ID: References: <8272bab2-aa15-479f-b838-0b60fb11c5bb@googlegroups.com> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1443194729 8259 80.91.229.3 (25 Sep 2015 15:25:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 25 Sep 2015 15:25:29 +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 25 17:25:28 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZfUsG-0000eI-QH for geh-help-gnu-emacs@m.gmane.org; Fri, 25 Sep 2015 17:25:24 +0200 Original-Received: from localhost ([::1]:47228 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZfUsB-0007vj-3K for geh-help-gnu-emacs@m.gmane.org; Fri, 25 Sep 2015 11:25:19 -0400 Original-Path: usenet.stanford.edu!news.kjsl.com!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.fsmpi.rwth-aachen.de!newsfeed.straub-nv.de!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!barmar.motzarella.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 34 Injection-Info: barmar.motzarella.org; posting-host="2be9e9f5dd9af768b8861af71b85fc28"; logging-data="23240"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1865UTu0F+LGx5o1I0JauT2" User-Agent: MT-NewsWatcher/3.5.3b3 (Intel Mac OS X) Cancel-Lock: sha1:QNadnIwX/vZ4D3aPuzNOF6BKDjk= Original-Xref: usenet.stanford.edu gnu.emacs.help:215060 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:107344 Archived-At: In article , jorge.alfaro-murillo@yale.edu (Jorge A. Alfaro-Murillo) wrote: > Jim Newton writes: > > > is there a way or an idiom for killing a region without changing > > the kill ring. I often want to cut several different regions by > > highlighting them, but then insert a particular thing with C-Y. > > If I use C-W to kill the region C-Y will yank back the string I > > just killed rather than the one I want. > > > > It would be nice to have a version of C-W which does not effect > > the kill-ring. > > Doesn't selecting the text and using do exactly that? I just tried it, and C-y recovered the deleted text. So it does put it on the kill-ring. > By the way, as Tomás suggested, I think that you are better off > always killing the region and then using M-y. You never know if > you will actually change your mind and use the text you deleted. I've used delete-region when I've accidentally run a command in a shell buffer that spews out thousands of lines of output. I know I'm not going to want it back. And back in the days of more limited memory, I would also turn off undo, so that the deleted region wouldn't be saved in the undo-history. -- Barry Margolin, barmar@alum.mit.edu Arlington, MA *** PLEASE post questions in newsgroups, not directly to me ***