unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: gareth.rees@pobox.com (Gareth Rees)
Subject: Re: How to copy rectangles
Date: 13 Oct 2003 05:34:46 -0700	[thread overview]
Message-ID: <e867ce6d.0310130434.2da5327c@posting.google.com> (raw)
In-Reply-To: 3f85cbb5$1@news.seqnet.net

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)))

-- 
Gareth Rees

  parent reply	other threads:[~2003-10-13 12:34 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-10-09 20:50 How to copy rectangles Siegfried Heintze
2003-10-11 18:37 ` roodwriter
2003-10-11 21:47 ` Martin Stone Davis
2003-10-13 12:34 ` Gareth Rees [this message]
2003-10-14 16:54   ` Sandip Chitale
2003-10-15 10:03     ` Gareth Rees
2003-10-15 18:14       ` Sandip Chitale

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e867ce6d.0310130434.2da5327c@posting.google.com \
    --to=gareth.rees@pobox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).