From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bastien Newsgroups: gmane.emacs.help Subject: Re: query-replace-regexp-swap ? Date: Sat, 26 Nov 2005 03:54:01 +0000 Organization: Guest of ProXad - France Message-ID: <87br08kqsm.fsf@bzg.ath.cx> References: <873blmhk2n.fsf@bzg.ath.cx> <1132970598.686287.327620@g14g2000cwa.googlegroups.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1132977413 28246 80.91.229.2 (26 Nov 2005 03:56:53 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 26 Nov 2005 03:56:53 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Nov 26 04:56:52 2005 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1Efr9u-0000fs-5K for geh-help-gnu-emacs@m.gmane.org; Sat, 26 Nov 2005 04:55:30 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Efr9t-0008LV-Kn for geh-help-gnu-emacs@m.gmane.org; Fri, 25 Nov 2005 22:55:29 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!newsfeed.gamma.ru!Gamma.RU!fr.ip.ndsoftware.net!proxad.net!infeed-4.proxad.net!nnrp2-1.free.fr!not-for-mail Original-Newsgroups: gnu.emacs.help User-Agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux) Cancel-Lock: sha1:JPNl/iAf+pYtoLB2RCBS+5Agf/o= Original-Lines: 21 Original-NNTP-Posting-Date: 26 Nov 2005 04:54:23 MET Original-NNTP-Posting-Host: 80.1.113.52 Original-X-Trace: 1132977263 nnrp2-1.free.fr 21220 80.1.113.52:33210 Original-X-Complaints-To: abuse@proxad.net Original-Xref: shelby.stanford.edu gnu.emacs.help:135762 Original-To: help-gnu-emacs@gnu.org 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:31364 Archived-At: "rgb" writes: > Does this look like what you wanted? > > (defun swap-text (str1 str2 beg end) Well, kind of. The thing is that i rather would like to use regexps (instead of meer strings), and i would like this func to behave like query-* functions - i.e. asking for each instance etc, since this function would often be called in a context where we just *don't* want each occurrence to be replaced. But i don't know if it's possible, or even a good idea to try to use perform-replace for this purpose. Anyway, thanks for the help! -- Bastien