listhelper-moderate
[Top][All Lists]
Advanced

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

help-gnu-emacs post from address@hidden requires approval


From: help-gnu-emacs-owner
Subject: help-gnu-emacs post from address@hidden requires approval
Date: Sat, 30 Jun 2007 13:40:14 -0400

As list administrator, your authorization is requested for the
following mailing list posting:

    List:    address@hidden
    From:    address@hidden
    Subject: Moving regions up and down by lines
    Reason:  Post by non-member to a members-only list

At your convenience, visit:

    http://lists.gnu.org/mailman/admindb/help-gnu-emacs
        
to approve or deny the request.
--- Begin Message --- Subject: Moving regions up and down by lines Date: Sat, 30 Jun 2007 10:25:35 -0700 User-agent: Mozilla-Thunderbird 2.0.0.4 (X11/20070622)
Greetings,

I have these two functions defined, which allow me to move the region up and down by one or more lines, displacing the text around it. This works pretty well, but after the call to yank, the region is no longer selected (I use transient-mark-mode). I've tried calling exchange-point-and-mark after the yank, but it has no effect. Does anyone know how to accomplish this?

(defun move-region-up (arg)
  (interactive "p")
  (kill-region (region-beginning) (region-end))
  (unwind-protect
      (previous-line arg)
    (yank)))

(defun move-region-down (arg)
  (interactive "p")
  (kill-region (region-beginning) (region-end))
  (unwind-protect
      (next-line arg)
    (yank)))

Thanks,
Dave

--- End Message ---
--- Begin Message --- Subject: confirm 2a6ed1370e3de638ad83b341fc2013495b16e55e
If you reply to this message, keeping the Subject: header intact,
Mailman will discard the held message.  Do this if the message is
spam.  If you reply to this message and include an Approved: header
with the list password in it, the message will be approved for posting
to the list.  The Approved: header can also appear in the first line
of the body of the reply.

--- End Message ---

reply via email to

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