From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: deprecated Newsgroups: gmane.emacs.help Subject: Re: Column replace Date: Tue, 12 Jun 2007 17:37:03 -0000 Organization: http://groups.google.com Message-ID: <1181669823.283617.131480@n15g2000prd.googlegroups.com> References: <1181638134.131187.199190@i13g2000prf.googlegroups.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Trace: sea.gmane.org 1181674690 14185 80.91.229.12 (12 Jun 2007 18:58:10 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 12 Jun 2007 18:58:10 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jun 12 20:58:09 2007 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 1HyBZ7-00029j-69 for geh-help-gnu-emacs@m.gmane.org; Tue, 12 Jun 2007 20:58:05 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HyBZ6-0003fY-PI for geh-help-gnu-emacs@m.gmane.org; Tue, 12 Jun 2007 14:58:04 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!n15g2000prd.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 43 Original-NNTP-Posting-Host: 132.248.81.29 Original-X-Trace: posting.google.com 1181669824 11748 127.0.0.1 (12 Jun 2007 17:37:04 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Tue, 12 Jun 2007 17:37:04 +0000 (UTC) In-Reply-To: <1181638134.131187.199190@i13g2000prf.googlegroups.com> User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8.1.4) Gecko/20070515 Firefox/2.0.0.4,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: n15g2000prd.googlegroups.com; posting-host=132.248.81.29; posting-account=tOnIyg0AAADhFtkD7ea9SIozDSqPZMH5 Original-Xref: shelby.stanford.edu gnu.emacs.help:149369 X-Mailman-Approved-At: Tue, 12 Jun 2007 14:57:51 -0400 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:44961 Archived-At: Just in case anyone was worried that emacs has only two solutions to this problem, there is a third way ..... :) On Jun 12, 3:48 am, Enchanter wrote: > How to replace this? > > From: > > text ts > text ts > text ts > text ts > text ts > text ts > text ts > > to: > text ts0 > text ts1 > text ts2 > text ts3 > text ts4 > text ts5 > text ts6 > Turn on CUA mode (M-x cua-mode) Move to the end of the first line and type C-return (cua-set-rectangle- mark). Now move to the end of the last line and type M-n (cua-sequence- rectangle). You will be prompted for a starting value, an increment and a format string. [Only tested in emacs 22] Cheers Will