From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/48366 Path: main.gmane.org!not-for-mail From: Reiner Steib <4uce.02.r.steib@gmx.net> Newsgroups: gmane.emacs.gnus.general Subject: [Patch] MFT in mml-preview Date: Mon, 30 Dec 2002 19:59:23 +0100 Sender: owner-ding@hpc.uh.edu Message-ID: Reply-To: reiner.steib@gmx.de NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: main.gmane.org 1041275288 24063 80.91.224.249 (30 Dec 2002 19:08:08 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Mon, 30 Dec 2002 19:08:08 +0000 (UTC) Return-path: Original-Received: from util1.math.uh.edu ([129.7.128.22]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18T5Gg-0006Fw-00 for ; Mon, 30 Dec 2002 20:08:07 +0100 Original-Received: from sina.hpc.uh.edu ([129.7.128.10] ident=lists) by util1.math.uh.edu with esmtp (Exim 4.10) id 18T58Y-0002Ul-00; Mon, 30 Dec 2002 12:59:42 -0600 Original-Received: by sina.hpc.uh.edu (TLB v0.09a (1.20 tibbs 1996/10/09 22:03:07)); Mon, 30 Dec 2002 13:00:34 -0600 (CST) Original-Received: from theotp5.physik.uni-ulm.de (theotp5.physik.uni-ulm.de [134.60.10.145]) by sina.hpc.uh.edu (8.9.3/8.9.3) with ESMTP id NAA13520 for ; Mon, 30 Dec 2002 13:00:21 -0600 (CST) Original-Received: (from ste@localhost) by theotp5.physik.uni-ulm.de (8.11.2/8.11.2) id gBUIxNV21971; Mon, 30 Dec 2002 19:59:23 +0100 X-Authentication-Warning: theotp5.physik.uni-ulm.de: ste set sender to reiner.steib@physik.uni-ulm.de using -f Original-To: ding@hpc.uh.edu X-Face: P05mdcZT&lL[-s2=mw~RsllZ0zZAb?vdE}.s8--- 2002-12-30 Reiner Steib * mml.el (mml-preview-insert-mft): New function. (mml-preview): Use it. * message.el (message-send-mail): Added comment concerning `mml-preview-insert-mft'. --8<---------------cut here---------------end--------------->8--- --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=message.mml-preview-insert-mft.patch Content-Description: message.mml-preview-insert-mft.patch --- message.el 2002/12/29 18:33:35 6.266 +++ message.el 2002/12/30 15:15:00 @@ -3337,6 +3352,8 @@ (save-restriction (message-narrow-to-headers) ;; Generate the Mail-Followup-To header if the header is not there... + ;; (Please also change code in `mml-preview-insert-mft', + ;; if you change anything here.) (if (and (or message-subscribed-regexps message-subscribed-addresses message-subscribed-address-file --- mml.el 2002/12/29 16:03:07 6.65 +++ mml.el 2002/12/30 16:23:12 @@ -1007,6 +1007,19 @@ (mml-insert-tag 'part 'type type 'disposition "inline") (forward-line -1)) +(defun mml-preview-insert-mft () + "Insert a Mail-Followup-To header before previewing an article. +Should be adopted if code in `message-send-mail' is changed." + (when (and (message-mail-p) + (or message-subscribed-regexps + message-subscribed-addresses + message-subscribed-address-file + message-subscribed-address-functions) + (not (mail-fetch-field "mail-followup-to")) + (message-make-mft)) + (message-position-on-field "Mail-Followup-To" "X-Draft-From") + (insert (message-make-mft)))) + (defun mml-preview (&optional raw) "Display current buffer with Gnus, in a new buffer. If RAW, don't highlight the article." @@ -1027,7 +1040,8 @@ "*MIME preview of ") (buffer-name)))) (erase-buffer) (insert-buffer buf) + (mml-preview-insert-mft) (let ((message-deletable-headers (if (message-news-p) nil message-deletable-headers))) --=-=-= Bye, Reiner. -- ,,, (o o) ---ooO-(_)-Ooo--- PGP key available via WWW http://rsteib.home.pages.de/ --=-=-=--