From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: bojohan+news@dd.chalmers.se (=?iso-8859-1?q?Johan_Bockg=E5rd?=) Newsgroups: gmane.emacs.help Subject: Re: copy-region-to-variable Date: Wed, 04 Feb 2004 14:50:24 +0100 Organization: Chalmers University of Technology, Sweden Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: <4yllnj56lq.fsf@skjellgran.ii.uib.no> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1075903612 28192 80.91.224.253 (4 Feb 2004 14:06:52 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 4 Feb 2004 14:06:52 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Feb 04 15:06:44 2004 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AoNfw-0001Dv-00 for ; Wed, 04 Feb 2004 15:06:44 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.24) id 1AoNaT-0006fg-PS for geh-help-gnu-emacs@m.gmane.org; Wed, 04 Feb 2004 09:01:05 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!bloom-beacon.mit.edu!news2.telebyte.nl!news1.spb.su!newsfeed1.funet.fi!newsfeeds.funet.fi!newsfeed.sunet.se!news01.sunet.se!dd.chalmers.se!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 20 Original-NNTP-Posting-Host: frealaf.dd.chalmers.se Mail-Copies-To: never User-Agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.2 (usg-unix-v) Cancel-Lock: sha1:Ft5byEZseyn2niYPXrKh8HfAh04= Original-Xref: shelby.stanford.edu gnu.emacs.help:120685 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.2 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 Xref: main.gmane.org gmane.emacs.help:16633 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:16633 Joakim Hove writes: > (kill-region p1 p2) (delete-region p1 p2) ; thou shalt not (mess with the) kill (ring) Also consider: - Function: delete-and-extract-region start end This function deletes the text between positions START and END in the current buffer, and returns a string containing the text just deleted. If point was inside the deleted region, its value afterward is START. Otherwise, point relocates with the surrounding text, as markers do. -- Johan Bockgård