Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cornell!batcomputer!itsgw!steinmetz!ge-dab!andrew!mmatlack From: mmatlack@andrew.GE.COM (Mike Matlack, 609/866-6612) Newsgroups: comp.emacs Subject: Re: mail-yank-original prefixes and gnus Message-ID: <313@andrew.GE.COM> Date: 16 Feb 89 13:01:51 GMT References: <1187@ubu.warwick.UUCP> Reply-To: mmatlack@atl.ge.com (Mike Matlack, 609/866-6612) Distribution: comp Organization: GE Advanced Technology Laboratories, Moorestown, NJ Lines: 36 Phil Watkins needed a mail-yank-original that allows the insertion of an arbitrary string (such as "> ") before each line of a yanked mail message, instead of the default x number of spaces. I use the following redefinition of mail-yank-original...not sure from whom I got it: (defun mail-yank-original (arg) "Insert the message being replied to, if any (in rmail). Puts point before the text and mark after. Adds a > character before the yanked message. A nonnumeric arg means don't delete any header fields." (interactive "P") (if mail-reply-buffer (let ((start (point))) (delete-windows-on mail-reply-buffer) (insert-buffer mail-reply-buffer) (if (consp arg) nil (mail-yank-clear-headers start (mark)) (while (< (point) (mark)) (beginning-of-line) (if (boundp '*mail-yank-line-prefix*) (insert-string *mail-yank-line-prefix*) (insert-string "> ")) (next-line 1))) (exchange-point-and-mark) (if (not (eolp)) (insert ?\n))))) If the variable *mail-yank-line-prefix* is not bound, this function will insert a "> " before each line. Otherwise, it will insert the string bound to this variable. -- MikeM mmatlack@atl.ge.com or mmatlack%atl.decnet@ge-crd.arpa ...!mcnc!ge-rtp!atl.ge.com!mmatlack