help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: quoting a block of text with ">"


From: Sergei Organov
Subject: Re: quoting a block of text with ">"
Date: Thu, 30 Sep 2010 12:44:42 +0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

"Stever" <address@hidden> writes:
> I can't seem to find this function in my version of emacs, but I assume
> there is one. is there any function where I can highlight a block of text
> and put a ">" in front of it.

While not obvious, `string-rectangle' is your friend here:

  string-rectangle is an interactive autoloaded Lisp function in
  `rect.el'.
  
  It is bound to C-x r t.
  
  (string-rectangle START END STRING)
  
  Replace rectangle contents with STRING on each line.
  The length of STRING need not be the same as the rectangle width.

Put cursor at the beginning of the first line of the region, set the
mark, move cursor to the _beginning_  of the last line, then
press

C-x r t > <ENTER>

(there is a space entered after ">").

-- Sergei.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]