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

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

Re: No copy-rectangle-as-kill?


From: Chris F.A. Johnson
Subject: Re: No copy-rectangle-as-kill?
Date: Wed, 1 Jun 2005 06:58:06 -0400
User-agent: slrn/0.9.7.4 (Linux)

On Wed, 01 Jun 2005 at 09:50 GMT, Hattuari wrote:
> Am I overlooking something, or is there no command in Emacs to copy a
> rectangle into the last killed rectangle "special place" without also
> removing it from the current buffer?  I gotta tell y'all, XEmacs has better
> rectangle support than Emacs. ;)

(defun copy-rectangle-as-kill ()
    (interactive)
    (save-excursion
    (kill-rectangle (mark) (point))
    (exchange-point-and-mark)
    (yank-rectangle)))

-- 
    Chris F.A. Johnson                     <http://cfaj.freeshell.org>
    ==================================================================
    Shell Scripting Recipes: A Problem-Solution Approach, 2005, Apress
    <http://www.torfree.net/~chris/books/cfaj/ssr.html>


reply via email to

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