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

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

Re: How to copy rectangles


From: Sandip Chitale
Subject: Re: How to copy rectangles
Date: 14 Oct 2003 09:54:22 -0700

gareth.rees@pobox.com (Gareth Rees) wrote in message 
news:<e867ce6d.0310130434.2da5327c@posting.google.com>...
> Siegfried Heintze wrote:
> > Why is there no kill-rectangle-save command? I need it!
> 
> Because you can use 'copy-rectangle-to-register' (C-x r r REGISTER) to
> save a copy, and 'insert-register' (C-x r i REGISTER) to insert it.
> 
> However, it's easy to roll your own:
> 
>     (defun kill-rectangle-save (start end)
>       "Save the region-rectangle as the last killed one."
>       (interactive "r")
>       (require 'rect)  ; Make sure killed-rectangle is defvar'ed.
>       (setq killed-rectangle (extract-rectangle start end)))

Thanks. I have added the above function to my .emacs now.

Can anyone tell me as to why this is not supported by emacs by
default? One would think this is very useful and commonly used
function.


reply via email to

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