[Mew-dist 09436] Re: supporting alias with domainpart (Re: mew-1.94b34.tar.gz)

Hidetomo Hosono hidetomo at example.com
1999年 6月 22日 (火) 21:00:38 JST


ほそのです。

From: Hidetomo Hosono <hidetomo at example.com>
To: mew-dist at example.com
Subject: [Mew-dist 09433] supporting alias with domainpart (Re:  mew-1.94b34.tar.gz)
Date: Tue, 22 Jun 1999 19:13:57 +0900

>  これは嬉しい機能なのですが、ひとつお願いしたいことがあります。第2パー
> トに付けた mew-addrbook.el.diff のように、
> mew-summary-personalinfo-add を mew-refile-guess-strip-domainpart の値を
> 見てふるまいを変えるようにして頂けるといいな、と思っているのです。

 私が書いたパッチを改めて送ります。(if COND THEN ELSE) の COND で複数の 
Lisp 文を実行させる方法を忘れてしまったので、幼稚な Lisp になってしまっ
ていますが、ご容赦下さい。

----
Hidetomo Hosono @ Chiba University Design Systems
[smtp] hidetomo at example.com, hide at example.com
[http] http://www.students.chiba-u.ac.jp/~qhosono/

-------------- next part --------------
--- mew-addrbook.el~	Tue Jun 22 12:43:26 1999
+++ mew-addrbook.el	Tue Jun 22 20:24:09 1999
@@ -251,9 +251,14 @@
 	(if (and (string-match "<.*>" from)
 		 (y-or-n-p (message "Add only the address part: %s? " addr)))
 	    (setq from addr))
-	(setq alias (read-string (format "Input its short name (%s): " user)))
-	(if (equal alias "")
-	    (setq alias user))
+	(if mew-refile-guess-strip-domainpart
+	    (setq alias (read-string (format "Input its short name (%s): " user)))
+	  (setq alias (read-string (format "Input its short name (%s): " addr))))
+	(if mew-refile-guess-strip-domainpart
+	    (if (equal alias "")
+		(setq alias user))
+	  (if (equal alias "")
+	      (setq alias addr)))
 	(set-buffer (find-file-noselect mew-addrbook-file))
 	(goto-char (point-max))
 	(if (not (bolp)) (insert "\n"))
@@ -287,10 +292,16 @@
 	      (setq phrase (mew-match 1 from))
 	      (setq phrase (mew-chop phrase)))
 	  (setq phrase ""))
-	(setq shortname (read-string (format "Input a short name for %s (%s): "
-					     addr user)))
-	(if (equal shortname "")
-	    (setq shortname user))
+	(if mew-refile-guess-strip-domainpart
+	    (setq shortname (read-string (format "Input a short name for %s (%s): "
+							     addr user)))
+	  (setq shortname (read-string (format "Input a short name for %s (%s): "
+					       addr addr))))
+	(if mew-refile-guess-strip-domainpart
+	    (if (equal shortname "")
+		(setq shortname user))
+	  (if (equal shortname "")
+	      (setq shortname addr)))
 	(setq name (read-string (format "Input a name (%s): " phrase)))
 	(if (equal name "")
 	    (setq name phrase))


Mew-dist メーリングリストの案内