From 20419c0497e9917049d48cdf5092e19bd48e9ad9 Mon Sep 17 00:00:00 2001 From: teranisi Date: Thu, 13 Jul 2000 03:44:48 +0000 Subject: [PATCH] * wl-draft.el (wl-draft-reply): Insert address with full-name. (Thanks to MAKINO Takashi ) * wl-vars.el (wl-draft-reply-use-address-with-full-name): New user option. --- wl/ChangeLog | 6 ++++++ wl/wl-draft.el | 45 +++++++++++++++++++++++++++++++++++---------- wl/wl-vars.el | 8 +++++++- 3 files changed, 48 insertions(+), 11 deletions(-) diff --git a/wl/ChangeLog b/wl/ChangeLog index 17d62c6..9b95eb2 100644 --- a/wl/ChangeLog +++ b/wl/ChangeLog @@ -1,5 +1,11 @@ 2000-07-13 Yuuichi Teranishi + * wl-draft.el (wl-draft-reply): Insert address with full-name. + (Thanks to MAKINO Takashi ) + + * wl-vars.el (wl-draft-reply-use-address-with-full-name): + New user option. + * wl-summary.el (wl-summary-sync-update3): Use `elmo-list-bigger-diff' if elmo-nntp-use-killed-list is nil. Use `elmo-msgdb-append-to-killed-list'. diff --git a/wl/wl-draft.el b/wl/wl-draft.el index 00ad3a2..f3cf8d0 100644 --- a/wl/wl-draft.el +++ b/wl/wl-draft.el @@ -4,7 +4,7 @@ ;; Author: Yuuichi Teranishi ;; Keywords: mail, net news -;; Time-stamp: <2000-05-19 10:23:11 teranisi> +;; Time-stamp: <00/07/13 12:41:30 teranisi> ;; This file is part of Wanderlust (Yet Another Message Interface on Emacsen). @@ -275,7 +275,7 @@ the `wl-smtp-features' variable." (let ((r-list (if no-arg wl-draft-reply-without-argument-list wl-draft-reply-with-argument-list)) to mail-followup-to cc subject in-reply-to references newsgroups - from) + from addr-alist) (set-buffer buf) (if (wl-address-user-mail-address-p (setq from @@ -320,13 +320,25 @@ the `wl-smtp-features' variable." (setq r-list (cdr r-list))) (error "No match field: check your `wl-draft-reply-without-argument-list'"))) (setq subject (std11-field-body "Subject")) + (setq to (wl-parse-addresses to) + cc (wl-parse-addresses cc)) (with-temp-buffer ; to keep raw buffer unibyte. (elmo-set-buffer-multibyte default-enable-multibyte-characters) (setq subject (or (and subject (eword-decode-string (decode-mime-charset-string subject - wl-mime-charset)))))) + wl-mime-charset))))) + (if wl-draft-reply-use-address-with-full-name + (setq addr-alist + (mapcar + '(lambda (addr) + (setq addr (eword-extract-address-components addr)) + (cons (nth 1 addr) + (if (nth 0 addr) + (concat (nth 0 addr) " <" (nth 1 addr) ">") + (nth 1 addr)))) + (append to cc))))) (and subject wl-reply-subject-prefix (let ((case-fold-search t)) (not @@ -343,8 +355,6 @@ the `wl-smtp-features' variable." (setq references (nconc (std11-field-bodies '("References" "In-Reply-To")) (list in-reply-to))) - (setq to (wl-parse-addresses to) - cc (wl-parse-addresses cc)) (setq to (mapcar '(lambda (addr) (wl-address-header-extract-address addr)) to)) @@ -370,11 +380,26 @@ the `wl-smtp-features' variable." (append (wl-delete-duplicates cc nil t) to (copy-sequence to)) t t)) - (and to (setq to (mapconcat 'identity to ",\n\t"))) - (and cc (setq cc (mapconcat 'identity cc ",\n\t"))) - (and mail-followup-to (setq mail-followup-to - (mapconcat 'identity - mail-followup-to ",\n\t"))) + (and to (setq to (mapconcat + '(lambda (addr) + (if wl-draft-reply-use-address-with-full-name + (cdr (assoc addr addr-alist)) + addr)) + to ",\n\t"))) + (and cc (setq cc (mapconcat + '(lambda (addr) + (if wl-draft-reply-use-address-with-full-name + (cdr (assoc addr addr-alist)) + addr)) + cc ",\n\t"))) + (and mail-followup-to + (setq mail-followup-to + (mapconcat + '(lambda (addr) + (if wl-draft-reply-use-address-with-full-name + (cdr (assoc addr addr-alist)) + addr)) + mail-followup-to ",\n\t"))) (and (null to) (setq to cc cc nil)) (setq references (delq nil references) references (mapconcat 'identity references " ") diff --git a/wl/wl-vars.el b/wl/wl-vars.el index baeb944..975acd1 100644 --- a/wl/wl-vars.el +++ b/wl/wl-vars.el @@ -4,7 +4,7 @@ ;; Author: Yuuichi Teranishi ;; Keywords: mail, net news -;; Time-stamp: <00/06/14 23:38:57 teranisi> +;; Time-stamp: <00/07/13 12:39:53 teranisi> ;; This file is part of Wanderlust (Yet Another Message Interface on Emacsen). @@ -1064,6 +1064,12 @@ Set this if (system-name) does not return FQDN." :group 'wl-draft :group 'wl-pref) +(defcustom wl-draft-reply-use-address-with-full-name t + "*Use address with full-name in the draft of replied message." + :type 'boolean + :group 'wl-pref + :group 'wl-draft) + (defcustom wl-folder-many-unsync-threshold 70 "*Folders which contains messages more than this number are highlighted with wl-highlight-folder-many-face." -- 1.7.10.4