From ebd0dcfac7f3da06820141c0808072442aa8fda6 Mon Sep 17 00:00:00 2001 From: morioka Date: Mon, 9 Mar 1998 18:53:55 +0000 Subject: [PATCH] tm 7.65. --- ChangeLog | 78 ++++++++++++++++++ Makefile | 2 +- README.en | 26 +++--- TM-CFG | 14 +++- gnus/ChangeLog | 13 +++ gnus/Makefile | 2 +- gnus/s-path | 3 +- gnus/tm-sgnus.el | 30 +++++-- inst-tm | 12 ++- tm-bbdb.el | 5 +- tm-def.el | 72 ++++++++++------ tm-edit.el | 8 +- tm-file.el | 7 +- tm-html.el | 6 +- tm-image.el | 16 ++-- tm-pgp.el | 6 +- tm-text.el | 8 +- tm-view.el | 9 +- tm-vm.el | 239 ++++++++++++++++++++++++++++++++++++++++-------------- 19 files changed, 409 insertions(+), 147 deletions(-) diff --git a/ChangeLog b/ChangeLog index efb06af..bf4a4ec 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,81 @@ +Mon May 27 15:14:29 1996 MORIOKA Tomohiko + + * tl: Version 7.27.1 was released. + * tm: Version 7.65 was released. + * tm/gnus: Version 7.63 was released. + + * README.en (4.1): add `EXEC_PREFIX'. + + September Gnus was renamed to Gnus 5.2. + + * TM-CFG (EXEC_PREFIX): new variable. + (BINS): fixed. + +Mon May 27 14:56:29 1996 MORIOKA Tomohiko + + * tm-def.el (mime/lc-charset-alist): add "ISO-8859-6". + + * inst-tm (install-elc): use `condition-case' for delete-file. + + * tm-def.el (mime/lc-charset-alist): Use constants `charset-*'. + +Mon May 27 08:16:38 1996 MORIOKA Tomohiko + + * tm-pgp.el (mime-article/check-pgp-signature): Use function + `mime-decode-region' instead of `mime/decode-region'. + + (mime-article/add-pgp-keys): Use function `mime-decode-region' + instead of `mime/decode-region'. + + * tm-text.el (mime-preview/decode-text-region): Use function + `mime-decode-region' instead of `mime/decode-region'. + + (mime-preview/filter-for-text/richtext): Use function + `mime-decode-region' instead of `mime/decode-region'. + + (mime-preview/filter-for-text/enriched): Use function + `mime-decode-region' instead of `mime/decode-region'. + +Mon May 27 08:08:00 1996 MORIOKA Tomohiko + + * tm-image.el (mime-preview/filter-for-inline-image): renamed from + function `mime-preview/filter-for-image/inline'. + + * tm-image.el (mime-preview/filter-for-image): Use function + `mime-decode-region' instead of `mime/decode-region'. + + (mime-preview/filter-for-image/inline): Use function + `mime-decode-region' instead of `mime/decode-region'. + + (mime-preview/filter-for-image/xbm): Use function + `mime-decode-region' instead of `mime/decode-region'. + +Mon May 27 08:00:50 1996 MORIOKA Tomohiko + + * tm-html.el (mime-article/decode-html): Use function + `mime-decode-region' instead of `mime/decode-region'. + +Mon May 27 07:58:21 1996 MORIOKA Tomohiko + + * tm-file.el (mime-article/extract-file): Use function + `mime-decode-region' instead of `mime/decode-region'. + +Thu May 23 16:51:04 1996 Shuhei KOBAYASHI + + * tm-vm.el (tm-vm/decode-message-header): doc string was modified. + (vm-yank-message): modified for `tm-vm/yank-content'. + (tm-vm/do-reply), (tm-vm/following-method), (tm-vm/yank-content): + New functions; following method for VM. + + * tm-view.el (mime/viewer-mode-map): New keybind for `describe-mode'. + was added. + (mime/viewer-mode): doc string was modified. + + * tm-bbdb.el: + (mime/viewer-mode-map): New keybinds for `tm-bbdb/edit-notes' and + `tm-bbdb/show-sender' were added. + + Thu May 23 01:34:26 1996 MORIOKA Tomohiko * tl: Version 7.27 was released. diff --git a/Makefile b/Makefile index 140d88f..70e373d 100644 --- a/Makefile +++ b/Makefile @@ -48,7 +48,7 @@ TL_FILES = tl/README.en tl/Makefile tl/mk-tl tl/tl-els \ FILES = $(TM_FILES) $(TM_MUA_FILES) $(MEL_FILES) $(TL_FILES) -TARFILE = tm7.64.tar.gz +TARFILE = tm7.65.tar.gz elc: $(EMACS) $(FLAGS) -l inst-tm -f compile-tm diff --git a/README.en b/README.en index 73597ee..b7b30cb 100644 --- a/README.en +++ b/README.en @@ -1,7 +1,7 @@ [README for tm (English Version)] by MORIOKA Tomohiko and KOBAYASHI Shuhei -$Id: README.en,v 7.20 1996/05/15 19:28:24 morioka Exp $ +$Id: README.en,v 7.21 1996/05/27 15:14:29 morioka Exp $ 1 What's tm? @@ -10,7 +10,7 @@ $Id: README.en,v 7.20 1996/05/15 19:28:24 morioka Exp $ - MIME style multilingual header - MIME message viewer (mime/viewer-mode) - MIME message composer (mime/editor-mode) - - MIME extenders for mh-e, GNUS, RMAIL and VM + - MIME extenders for mh-e, GNUS, Gnus, RMAIL and VM 2 Documents @@ -71,7 +71,7 @@ $Id: README.en,v 7.20 1996/05/15 19:28:24 morioka Exp $ You can edit tm/TM-CFG file. In default, tm is installed into /usr/local/. If you want to change, -please modify the variable `PREFIX'. +please modify the variable `PREFIX' and `EXEC_PREFIX'. 4.2 tm-gnus (optional) @@ -83,9 +83,9 @@ distribution, you must edit following files before make. If you use Emacs 18.* and GNUS 4.*, please edit tm/gnus/g4-path. - If you use Gnus 5.0.*, please edit tm/gnus/g5-path. + If you use Gnus 5.[01].*, please edit tm/gnus/g5-path. - If you use September Gnus, please edit tm/gnus/s-path. + If you use Gnus 5.2.*, please edit tm/gnus/s-path. 4.3 edit external methods (optional) @@ -134,31 +134,31 @@ mmencode. 6.1 automatic MIME preview support tm-gnus provides automatic MIME preview feature for GNUS 3.15 or -later, Gnus 5.0.*, Gnus 5.1, and September Gnus. +later, Gnus 5.0.*, Gnus 5.1, and Gnus 5.2. If you don't want to use automatic MIME preview feature, please insert following to ~/.emacs. (setq tm-gnus/automatic-mime-preview nil) - In addition, September Gnus has automatic MIME preview supporting -feature. Of course, tm-gnus provides this feature for other GNUS and -Gnus, but it is unnatural. + In addition, Gnus 5.2 has automatic MIME preview supporting feature. +Of course, tm-gnus provides this feature for other GNUS and Gnus, but +it is unnatural. When automatic MIME preview mode, GNUS and Gnus do MIME processing if a message has a Mime-Version field. If it does not have, GNUS and Gnus does not do MIME processing, in default. - Gnus 5.0.*, 5.1 and September Gnus have a variable -`gnus-strict-mime'. If you insert + Gnus 5.0.*, 5.1 and Gnus 5.2 have a variable `gnus-strict-mime'. If +you insert (setq gnus-strict-mime nil) Gnus do MIME processing even if a message does not have Mime-Version field. - In September Gnus, if `gnus-strict-mime' is not nil, variable -`gnus-decode-encoded-word-method' is called. tm-gnus uses it to decode + In Gnus 5.2, if `gnus-strict-mime' is not nil, variable +`gnus-decode-encoded-word-method' is called. tm-gnus uses it to decode RFC 1522 encoded-word. So it is not necessary to reset `gnus-strict-mime'. diff --git a/TM-CFG b/TM-CFG index 3593e94..658eb56 100644 --- a/TM-CFG +++ b/TM-CFG @@ -1,6 +1,6 @@ ;;; -*-Emacs-Lisp-*- ;;; -;;; $Id: TM-CFG,v 7.0 1996/05/20 16:24:30 morioka Exp morioka $ +;;; $Id: TM-CFG,v 7.1 1996/05/27 15:09:09 morioka Exp morioka $ ;;; (defvar default-load-path load-path) @@ -50,6 +50,14 @@ )) ; install to shared directory (maybe "/usr/local") ;;(setq PREFIX "~/") ; install to your home directory +;; Please specify install path prefix for binaries. +(setq EXEC_PREFIX + (if (or running-emacs-18 running-xemacs) + (expand-file-name "../../.." exec-directory) + (expand-file-name "../../../.." exec-directory) + )) +;;(setq EXEC_PREFIX "~/") ; install to your home directory + ;; Please specify tm package prefix [optional] (setq TM_PACKAGE_PREFIX "") @@ -95,7 +103,7 @@ ;;; ;; Please specify binary path. -(defvar BIN_DIR (expand-file-name "bin" PREFIX)) +(defvar BIN_DIR (expand-file-name "bin" EXEC_PREFIX)) ;; Please specify binary path. (for external method scripts) (setq METHOD_DIR (expand-file-name "share/tm" PREFIX)) @@ -157,7 +165,7 @@ (setq BIN_SRC_DIR "src") -(setq BINS '("src/ol2" "src/decode-b")) +(setq BINS '("ol2" "decode-b")) (setq METHOD_SRC_DIR "methods") (setq METHODS '("tm-au" "tm-file" "tm-html" "tm-image" "tm-mpeg" "tm-plain" diff --git a/gnus/ChangeLog b/gnus/ChangeLog index 4950816..b35341a 100644 --- a/gnus/ChangeLog +++ b/gnus/ChangeLog @@ -1,3 +1,16 @@ +Mon May 27 03:48:56 1996 MORIOKA Tomohiko + + * tm/gnus: Version 7.63 was released. + + * tm-sgnus.el (nnmail-find-file): New function. + +Sun May 26 04:36:12 1996 MORIOKA Tomohiko + + * tm-sgnus.el (nnheader-insert-file-contents-literally): + New function for Mule. + (nnheader-insert-raw-file-contents): New alias. + + Mon May 20 15:29:30 1996 MORIOKA Tomohiko * tm/gnus: Version 7.61 was released. diff --git a/gnus/Makefile b/gnus/Makefile index 1f385e1..ac15237 100644 --- a/gnus/Makefile +++ b/gnus/Makefile @@ -30,7 +30,7 @@ FILES = tm/gnus/Makefile tm/gnus/*-path tm/gnus/mk-tgnus \ tm/gnus/*.el tm/gnus/ChangeLog tm/doc/tm-gnus*.texi -TARFILE = tm-gnus7.61.tar +TARFILE = tm-gnus7.63.tar gnus: diff --git a/gnus/s-path b/gnus/s-path index d9c3c53..8a3cbf3 100644 --- a/gnus/s-path +++ b/gnus/s-path @@ -9,7 +9,8 @@ ;; please edit ;; It is for latest September Gnus. -(let ((path (get-latest-path "sgnus"))) +(let ((path (or (get-latest-path "gnus-5.2") + (get-latest-path "sgnus")))) (if path (add-path (expand-file-name "lisp/" path)) )) diff --git a/gnus/tm-sgnus.el b/gnus/tm-sgnus.el index 095be12..790830f 100644 --- a/gnus/tm-sgnus.el +++ b/gnus/tm-sgnus.el @@ -1,5 +1,5 @@ ;;; -;;; tm-sgnus.el --- tm-gnus module for September Gnus +;;; tm-sgnus.el --- MIME extender for Gnus 5.2 ;;; ;;; Copyright (C) 1995 Free Software Foundation, Inc. ;;; Copyright (C) 1995,1996 MORIOKA Tomohiko @@ -7,7 +7,7 @@ ;;; Author: MORIOKA Tomohiko ;;; Maintainer: MORIOKA Tomohiko ;;; Created: 1995/09/24 -;;; Version: $Revision: 7.61 $ +;;; Version: $Revision: 7.63 $ ;;; Keywords: news, MIME, multimedia, multilingual, encoded-word ;;; ;;; This file is part of tm (Tools for MIME). @@ -41,7 +41,7 @@ ;;; (defconst tm-gnus/RCS-ID - "$Id: tm-sgnus.el,v 7.61 1996/05/20 15:29:30 morioka Exp $") + "$Id: tm-sgnus.el,v 7.63 1996/05/27 03:48:56 morioka Exp $") (defconst tm-gnus/version (concat (get-version-string tm-gnus/RCS-ID) " for September")) @@ -237,16 +237,28 @@ This variable is set to `gnus-show-mime'.") (call-after-loaded 'nnheader (lambda () - (defun nnheader-find-file-noselect (filename &optional nowarn rawfile) + (defun nnmail-find-file (file) + "Insert FILE in server buffer safely. [tm-sgnus.el]" + (set-buffer nntp-server-buffer) + (erase-buffer) + (let ((format-alist nil) + (after-insert-file-functions nil) + (file-coding-system-for-read *noconv*)) + (condition-case () + (progn (insert-file-contents file) t) + (file-error nil)))) + (defun nnheader-insert-file-contents-literally + (filename &optional visit beg end replace) (let ((file-coding-system-for-read *noconv*)) - (find-file-noselect filename nowarn rawfile) + (insert-file-contents-literally filename visit beg end replace) )) - (defun nnheader-insert-raw-file-contents - (filename &optional visit beg end replace) + ;; compatibility for September Gnus 0.80 .. 0.94 + (fset 'nnheader-insert-raw-file-contents + 'nnheader-insert-file-contents-literally) + (defun nnheader-find-file-noselect (filename &optional nowarn rawfile) (let ((file-coding-system-for-read *noconv*)) - (insert-file-contents filename visit beg end replace) + (find-file-noselect filename nowarn rawfile) )) - ;;(fset 'nnheader-raw-write-region 'si:write-region) )) (defun tm-gnus/prepare-save-mail-function () (setq file-coding-system *noconv*) diff --git a/inst-tm b/inst-tm index b12c228..be32757 100644 --- a/inst-tm +++ b/inst-tm @@ -1,6 +1,6 @@ ;;; -*-Emacs-Lisp-*- ;;; -;;; $Id: inst-tm,v 7.0 1996/05/08 15:05:03 morioka Exp morioka $ +;;; $Id: inst-tm,v 7.2 1996/05/27 14:56:29 morioka Exp $ ;;; (load-file "TM-CFG") @@ -128,7 +128,15 @@ (if (file-exists-p src-file) (let ((full-path (expand-file-name file dest))) (copy-file src-file full-path t t) - (delete-file src-file) + (catch 'tag + (while t + (condition-case err + (progn + (delete-file src-file) + (throw 'tag nil) + ) + (error (princ (nth 1 err))) + ))) (princ (format "%s -> %s\n" file dest)) )) )) diff --git a/tm-bbdb.el b/tm-bbdb.el index fa0d84f..cf0ac19 100644 --- a/tm-bbdb.el +++ b/tm-bbdb.el @@ -8,7 +8,7 @@ ;;; Artur Pioro ;;; modified by Pekka Marjola ;;; Maintainer: KOBAYASHI Shuhei -;;; Version: $Id: tm-bbdb.el,v 7.8 1996/05/09 16:01:13 morioka Exp $ +;;; Version: $Id: tm-bbdb.el,v 7.9 1996/05/23 16:42:14 shuhei-k Exp $ ;;; Keywords: mail, news, MIME, multimedia, multilingual, BBDB ;;; ;;; This file is part of tm (Tools for MIME). @@ -193,6 +193,9 @@ displaying the record corresponding to the sender of the current message." (set-buffer b) record))) +(define-key mime/viewer-mode-map ";" 'tm-bbdb/edit-notes) +(define-key mime/viewer-mode-map ":" 'tm-bbdb/show-sender) + ;;; @ for signature.el ;;; diff --git a/tm-def.el b/tm-def.el index 576899f..32a815d 100644 --- a/tm-def.el +++ b/tm-def.el @@ -6,7 +6,7 @@ ;;; ;;; Author: MORIOKA Tomohiko ;;; Version: -;;; $Id: tm-def.el,v 7.42 1996/05/09 18:24:39 morioka Exp $ +;;; $Id: tm-def.el,v 7.44 1996/05/27 14:51:15 morioka Exp $ ;;; Keywords: mail, news, MIME, multimedia, definition ;;; ;;; This file is part of tm (Tools for MIME). @@ -73,30 +73,50 @@ a) )) nil - '(((lc-ascii) . "US-ASCII") - ((lc-ascii lc-ltn1) . "ISO-8859-1") - ((lc-ascii lc-ltn2) . "ISO-8859-2") - ((lc-ascii lc-ltn3) . "ISO-8859-3") - ((lc-ascii lc-ltn4) . "ISO-8859-4") -;;; ((lc-ascii lc-crl) . "ISO-8859-5") - ((lc-ascii lc-crl) . "KOI8-R") - ((lc-ascii lc-grk) . "ISO-8859-7") - ((lc-ascii lc-hbw) . "ISO-8859-8") - ((lc-ascii lc-ltn5) . "ISO-8859-9") - ((lc-ascii lc-jp) . "ISO-2022-JP") - ((lc-ascii lc-kr) . "EUC-KR") - ((lc-ascii - lc-big5-1 - lc-big5-2) . "BIG5") - ((lc-ascii - lc-jp lc-cn - lc-kr lc-jp2 - lc-ltn1 lc-grk) . "ISO-2022-JP-2") - ((lc-ascii - lc-jp lc-cn - lc-kr lc-jp2 - lc-cns1 lc-cns2 - lc-ltn1 lc-grk) . "ISO-2022-INT-1") + '(((charset-ascii) . "US-ASCII") + ((charset-ascii + charset-latin-1) . "ISO-8859-1") + ((charset-ascii + charset-latin-2) . "ISO-8859-2") + ((charset-ascii + charset-latin-3) . "ISO-8859-3") + ((charset-ascii + charset-latin-4) . "ISO-8859-4") +;;; ((charset-ascii +;;; charset-cyrillic) . "ISO-8859-5") + ((charset-ascii + charset-cyrillic) . "KOI8-R") + ((charset-ascii + charset-arabic) . "ISO-8859-6") + ((charset-ascii + charset-greek) . "ISO-8859-7") + ((charset-ascii + charset-hebrew) . "ISO-8859-8") + ((charset-ascii + charset-latin-5) . "ISO-8859-9") + ((charset-ascii + charset-jisx0208) . "ISO-2022-JP") + ((charset-ascii + charset-ksc5601) . "EUC-KR") + ((charset-ascii + charset-big5-1 + charset-big5-2) . "BIG5") + ((charset-ascii + charset-gb2312 + charset-jisx0208 + charset-ksc5601 + charset-jisx0212 + charset-latin-1 + charset-greek) . "ISO-2022-JP-2") + ((charset-ascii + charset-gb2312 + charset-jisx0208 + charset-ksc5601 + charset-jisx0212 + charset-cns11643-1 + charset-cns11643-2 + charset-latin-1 + charset-greek) . "ISO-2022-INT-1") ))) (defvar mime/unknown-charset "ISO-2022-INT-1") @@ -118,7 +138,7 @@ )) (defun mime/find-charset-region (beg end) - (mime/find-charset (cons lc-ascii (find-charset-region beg end))) + (mime/find-charset (cons charset-ascii (find-charset-region beg end))) ) (defvar mime/charset-type-list diff --git a/tm-edit.el b/tm-edit.el index 90c21fa..9f5df12 100644 --- a/tm-edit.el +++ b/tm-edit.el @@ -8,7 +8,7 @@ ;;; MORIOKA Tomohiko ;;; Maintainer: MORIOKA Tomohiko ;;; Created: 1994/08/21 renamed from mime.el -;;; Version: $Revision: 7.63 $ +;;; Version: $Revision: 7.64 $ ;;; Keywords: mail, news, MIME, multimedia, multilingual ;;; ;;; This file is part of tm (Tools for MIME). @@ -122,7 +122,7 @@ ;;; (defconst mime-editor/RCS-ID - "$Id: tm-edit.el,v 7.63 1996/05/22 02:25:54 morioka Exp $") + "$Id: tm-edit.el,v 7.64 1996/05/24 08:50:14 morioka Exp $") (defconst mime-editor/version (get-version-string mime-editor/RCS-ID)) @@ -133,9 +133,6 @@ (defvar mime-prefix "\C-c\C-x" "*Keymap prefix for MIME commands.") -;; (defvar mime-signature-file "~/.signature.rtf" -;; "*Signature file to be included as a part of a multipart message.") - (defvar mime-ignore-preceding-spaces nil "*Ignore preceding white spaces if non-nil.") @@ -526,6 +523,7 @@ Tspecials means any character that matches with it in header must be quoted.") (defconst mime-editor/mime-map (make-sparse-keymap) "Keymap for MIME commands.") + ;;; @ keymap and menu ;;; diff --git a/tm-file.el b/tm-file.el index 0517942..105f62b 100644 --- a/tm-file.el +++ b/tm-file.el @@ -2,12 +2,13 @@ ;;; tm-file.el --- tm-view internal method for file extraction ;;; ;;; Copyright (C) 1995 Free Software Foundation, Inc. -;;; Copyright (C) 1995 MORIOKA Tomohiko +;;; Copyright (C) 1995,1996 MORIOKA Tomohiko ;;; ;;; Author: MORIOKA Tomohiko ;;; modified by KOBAYASHI Shuhei +;;; Maintainer: KOBAYASHI Shuhei ;;; Version: -;;; $Id: tm-file.el,v 7.5 1996/04/16 18:21:23 morioka Exp $ +;;; $Id: tm-file.el,v 7.6 1996/05/27 07:58:21 morioka Exp $ ;;; Keywords: mail, news, MIME, multimedia ;;; ;;; This file is part of tm (Tools for MIME). @@ -61,7 +62,7 @@ (append-to-buffer tmp-buf (match-end 0) end) (save-excursion (set-buffer tmp-buf) - (mime/decode-region encoding (point-min)(point-max)) + (mime-decode-region (point-min)(point-max) encoding) (let ((mc-flag nil) ; for Mule (file-coding-system (if (featurep 'mule) *noconv*)) diff --git a/tm-html.el b/tm-html.el index 4a3c590..b690a4c 100644 --- a/tm-html.el +++ b/tm-html.el @@ -2,13 +2,13 @@ ;;; tm-html.el: a tm-view internal decoder for HTML ;;; ;;; Copyright (C) 1995 Free Software Foundation, Inc. -;;; Copyright (C) 1995 MORIOKA Tomohiko +;;; Copyright (C) 1995,1996 MORIOKA Tomohiko ;;; ;;; Author: MORIOKA Tomohiko ;;; Created: 1995/9/14 ;;; based on tm-latex.el by OKABE Yasuo ;;; Version: -;;; $Id: tm-html.el,v 7.5 1996/04/16 18:22:51 morioka Exp $ +;;; $Id: tm-html.el,v 7.6 1996/05/27 08:00:50 morioka Exp $ ;;; Keywords: mail, news, MIME, multimedia, HTML, WWW ;;; ;;; This file is part of tm (Tools for MIME). @@ -55,7 +55,7 @@ (re-search-forward "^$") (append-to-buffer new-buf (+ (match-end 0) 1) end) ))) - (mime/decode-region encoding (point-min)(point-max)) + (mime-decode-region (point-min)(point-max) encoding) (run-hooks 'mime-article/decode-html-hook) )) diff --git a/tm-image.el b/tm-image.el index 23c3fcd..2566c35 100644 --- a/tm-image.el +++ b/tm-image.el @@ -10,7 +10,7 @@ ;;; Maintainer: MORIOKA Tomohiko ;;; Created: 1995/12/15 ;;; Version: -;;; $Id: tm-image.el,v 7.3 1996/04/26 04:20:52 morioka Exp $ +;;; $Id: tm-image.el,v 7.5 1996/05/27 08:08:00 morioka Exp $ ;;; ;;; Keywords: mail, news, MIME, multimedia, image, picture ;;; @@ -46,21 +46,21 @@ (set-alist 'mime-viewer/content-filter-alist "image/jpeg" (if (featurep 'jpeg) ; Use built-in suport if available - (function mime-preview/filter-for-image/inline) + (function mime-preview/filter-for-inline-image) (function mime-preview/filter-for-image) )) (set-alist 'mime-viewer/content-filter-alist "image/gif" (if (featurep 'gif) ; Use built-in suport if available - (function mime-preview/filter-for-image/inline) + (function mime-preview/filter-for-inline-image) (function mime-preview/filter-for-image) )) (set-alist 'mime-viewer/content-filter-alist "image/x-xpixmap" (if (featurep 'xpm) ; Use built-in suport if available - (function mime-preview/filter-for-image/inline) + (function mime-preview/filter-for-inline-image) (function mime-preview/filter-for-image) )) @@ -197,7 +197,7 @@ (xbm-file (concat orig-file ".xbm")) gl annot) ;;(remove-text-properties beg end '(face nil)) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (write-region (point-min)(point-max) orig-file) (delete-region (point-min)(point-max)) (message "Now translating, please wait...") @@ -225,7 +225,7 @@ ;;; ;; (for XEmacs 19.14 or later) -(defun mime-preview/filter-for-image/inline (ctype params encoding) +(defun mime-preview/filter-for-inline-image (ctype params encoding) (let* ((mode mime::preview/original-major-mode) (m (assq mode mime-viewer/code-converter-alist)) (charset (assoc "charset" params)) @@ -233,7 +233,7 @@ (image-file (make-temp-name (expand-file-name "tm" mime/tmp-dir))) ) (remove-text-properties beg end '(face nil)) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (write-region (point-min)(point-max) image-file) (delete-region (point-min)(point-max)) (image-read-file ctype image-file) @@ -253,7 +253,7 @@ (xbm-file (make-temp-name (expand-file-name "tm" mime/tmp-dir))) ) (remove-text-properties beg end '(face nil)) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (write-region (point-min)(point-max) xbm-file) (delete-region (point-min)(point-max)) (bitmap-read-xbm xbm-file) diff --git a/tm-pgp.el b/tm-pgp.el index a9832eb..6ebbd72 100644 --- a/tm-pgp.el +++ b/tm-pgp.el @@ -8,7 +8,7 @@ ;;; Maintainer: MORIOKA Tomohiko ;;; Created: 1995/12/7 ;;; Version: -;;; $Id: tm-pgp.el,v 7.14 1996/05/09 18:43:14 morioka Exp $ +;;; $Id: tm-pgp.el,v 7.15 1996/05/27 08:16:38 morioka Exp $ ;;; Keywords: mail, news, MIME, multimedia, PGP, security ;;; ;;; This file is part of tm (Tools for MIME). @@ -195,7 +195,7 @@ end)) (set-buffer (setq kbuf (get-buffer-create mime/temp-buffer-name))) (insert str) - (mime/decode-region encoding (point-min)(point-max)) + (mime-decode-region (point-min)(point-max) encoding) (let ((mc-flag nil) ; for Mule (file-coding-system (if (featurep 'mule) *noconv*)) @@ -291,7 +291,7 @@ (if (re-search-forward "^\n" nil t) (delete-region (point-min) (match-end 0)) ) - (mime/decode-region encoding (point-min)(point-max)) + (mime-decode-region (point-min)(point-max) encoding) (mc-snarf-keys) (kill-buffer (current-buffer)) )) diff --git a/tm-text.el b/tm-text.el index 12bfc53..5b64ee9 100644 --- a/tm-text.el +++ b/tm-text.el @@ -8,7 +8,7 @@ ;;; ;;; Author: MORIOKA Tomohiko ;;; Version: -;;; $Id: tm-text.el,v 7.11 1996/05/09 18:47:32 morioka Exp $ +;;; $Id: tm-text.el,v 7.12 1996/05/27 08:14:11 morioka Exp $ ;;; Keywords: mail, news, MIME, multimedia, text ;;; ;;; This file is part of tm (Tools for MIME). @@ -45,7 +45,7 @@ )) (defun mime-preview/decode-text-region (beg end charset encoding) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (let* ((mode mime::preview/original-major-mode) (m (or (save-excursion (set-buffer mime::preview/article-buffer) @@ -94,7 +94,7 @@ (beg (point-min)) (end (point-max)) ) (remove-text-properties beg end '(face nil)) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (if (and m (fboundp (setq m (cdr m)))) (funcall m beg (point-max) charset encoding) (mime-viewer/default-code-convert-region beg (point-max) @@ -112,7 +112,7 @@ (beg (point-min)) (end (point-max)) ) (remove-text-properties beg end '(face nil)) - (mime/decode-region encoding beg end) + (mime-decode-region beg end encoding) (if (and m (fboundp (setq m (cdr m)))) (funcall m beg (point-max) charset encoding) (mime-viewer/default-code-convert-region beg (point-max) diff --git a/tm-view.el b/tm-view.el index b0f9996..30b5bd1 100644 --- a/tm-view.el +++ b/tm-view.el @@ -8,7 +8,7 @@ ;;; modified by Steven L. Baur ;;; Maintainer: MORIOKA Tomohiko ;;; Created: 1994/7/13 (1994/8/31 obsolete tm-body.el) -;;; Version: $Revision: 7.64 $ +;;; Version: $Revision: 7.65 $ ;;; Keywords: mail, news, MIME, multimedia ;;; ;;; This file is part of tm (Tools for MIME). @@ -45,7 +45,7 @@ ;;; (defconst mime-viewer/RCS-ID - "$Id: tm-view.el,v 7.64 1996/05/22 02:26:49 morioka Exp $") + "$Id: tm-view.el,v 7.65 1996/05/23 16:45:10 shuhei-k Exp $") (defconst mime-viewer/version (get-version-string mime-viewer/RCS-ID)) (defconst mime/viewer-version mime-viewer/version) @@ -721,6 +721,8 @@ The compressed face will be piped to this command.") "<" (function beginning-of-buffer)) (define-key mime/viewer-mode-map ">" (function end-of-buffer)) + (define-key mime/viewer-mode-map + "?" (function describe-mode)) (if mouse-button-2 (define-key mime/viewer-mode-map mouse-button-2 (function tm:button-dispatcher)) @@ -777,7 +779,8 @@ M-RET Move to previous line v Decode current content as `play mode' e Decode current content as `extract mode' C-c C-p Decode current content as `print mode' -f Display X-Face +a Followup to current content. +x Display X-Face q Quit button-2 Move to point under the mouse cursor and decode current content as `play mode' diff --git a/tm-vm.el b/tm-vm.el index dd876f7..98fa148 100644 --- a/tm-vm.el +++ b/tm-vm.el @@ -16,7 +16,7 @@ ;;; Rob Kooper ;;; Maintainer: KOBAYASHI Shuhei ;;; Created: 1994/10/29 -;;; Version: $Revision: 7.52 $ +;;; Version: $Revision: 7.53 $ ;;; Keywords: mail, MIME, multimedia, multilingual, encoded-word ;;; ;;; This file is part of tm (Tools for MIME). @@ -45,7 +45,7 @@ (require 'vm) (defconst tm-vm/RCS-ID - "$Id: tm-vm.el,v 7.52 1996/04/19 18:49:19 shuhei-k Exp $") + "$Id: tm-vm.el,v 7.53 1996/05/23 16:51:04 shuhei-k Exp $") (defconst tm-vm/version (get-version-string tm-vm/RCS-ID)) (define-key vm-mode-map "Z" 'tm-vm/view-message) @@ -107,7 +107,7 @@ If you use tiny-mime patch for VM (by RIKITAKE Kenji )) (defun tm-vm/decode-message-header (&optional count) - "Decode MIME header of current message through tiny-mime. + "Decode MIME header of current message. Numeric prefix argument COUNT means to decode the current message plus the next COUNT-1 messages. A negative COUNT means decode the current message and the previous COUNT-1 messages. @@ -569,7 +569,7 @@ tm-vm uses `vm-select-message-hook', use this hook instead.") (require 'vm-reply) -(defun vm-yank-message (message) +(defun vm-yank-message (&optional message) "Yank message number N into the current buffer at point. When called interactively N is always read from the minibuffer. When called non-interactively the first argument is expected to be a @@ -606,68 +606,185 @@ vm-included-text-prefix is prepended to every yanked line." prompt (last-command last-command) (this-command this-command)) - (save-excursion - (vm-select-folder-buffer) - (setq default (and vm-message-pointer - (vm-number-of (car vm-message-pointer))) - prompt (if default - (format "Yank message number: (default %s) " - default) - "Yank message number: ")) - (while (zerop result) - (setq result (read-string prompt)) - (and (string= result "") default (setq result default)) - (setq result (string-to-int result))) - (if (null (setq mp (nthcdr (1- result) vm-message-list))) - (error "No such message."))) - (car mp)))) - (if (not (bufferp vm-mail-buffer)) - (error "This is not a VM Mail mode buffer.")) - (if (null (buffer-name vm-mail-buffer)) - (error "The folder buffer containing message %d has been killed." - (vm-number-of message))) - (vm-display nil nil '(vm-yank-message) '(vm-yank-message composing-message)) - (setq message (vm-real-message-of message)) - (let ((b (current-buffer)) (start (point)) end) - (save-restriction - (widen) - (save-excursion - (set-buffer (vm-buffer-of message)) - (let* ((mbuf (current-buffer)) - (pbuf (and mime::article/preview-buffer - (get-buffer mime::article/preview-buffer))) - (pwin (and pbuf (vm-get-visible-buffer-window pbuf)))) - (if pwin - (if running-xemacs - (let ((tmp (generate-new-buffer "tm-vm/tmp"))) - (set-buffer pbuf) - (append-to-buffer tmp (point-min) (point-max)) - (set-buffer tmp) - (map-extents - '(lambda (ext maparg) - (set-extent-property ext 'begin-glyph nil))) - (append-to-buffer b (point-min) (point-max)) - (setq end (vm-marker (+ start (length (buffer-string))) b)) - (kill-buffer tmp)) - (set-buffer pbuf) - (append-to-buffer b (point-min) (point-max)) - (setq end (vm-marker (+ start (length (buffer-string))) b))) - (save-restriction - (widen) - (append-to-buffer - b (vm-headers-of message) (vm-text-end-of message)) - (setq end - (vm-marker (+ start (- (vm-text-end-of message) - (vm-headers-of message))) b)))))) - (push-mark end) - (cond (mail-citation-hook (run-hooks 'mail-citation-hook)) - (mail-yank-hooks (run-hooks 'mail-yank-hooks)) - (t (vm-mail-yank-default message)))))) + (if (bufferp vm-mail-buffer) + (save-excursion + (vm-select-folder-buffer) + (setq default (and vm-message-pointer + (vm-number-of (car vm-message-pointer))) + prompt (if default + (format "Yank message number: (default %s) " + default) + "Yank message number: ")) + (while (zerop result) + (setq result (read-string prompt)) + (and (string= result "") default (setq result default)) + (setq result (string-to-int result))) + (if (null (setq mp (nthcdr (1- result) vm-message-list))) + (error "No such message.")) + (car mp)) + nil)))) + (if (null message) + (if mail-reply-buffer + (tm-vm/yank-content) + (error "This is not a VM Mail mode buffer.")) + (if (null (buffer-name vm-mail-buffer)) + (error "The folder buffer containing message %d has been killed." + (vm-number-of message))) + (vm-display nil nil '(vm-yank-message) + '(vm-yank-message composing-message)) + (setq message (vm-real-message-of message)) + (let ((b (current-buffer)) (start (point)) end) + (save-restriction + (widen) + (save-excursion + (set-buffer (vm-buffer-of message)) + (let* ((mbuf (current-buffer)) + (pbuf (and mime::article/preview-buffer + (get-buffer mime::article/preview-buffer))) + (pwin (and pbuf (vm-get-visible-buffer-window pbuf)))) + (if pwin + (if running-xemacs + (let ((tmp (generate-new-buffer "tm-vm/tmp"))) + (set-buffer pbuf) + (append-to-buffer tmp (point-min) (point-max)) + (set-buffer tmp) + (map-extents + '(lambda (ext maparg) + (set-extent-property ext 'begin-glyph nil))) + (append-to-buffer b (point-min) (point-max)) + (setq end (vm-marker + (+ start (length (buffer-string))) b)) + (kill-buffer tmp)) + (set-buffer pbuf) + (append-to-buffer b (point-min) (point-max)) + (setq end (vm-marker + (+ start (length (buffer-string))) b))) + (save-restriction + (widen) + (append-to-buffer + b (vm-headers-of message) (vm-text-end-of message)) + (setq end + (vm-marker (+ start (- (vm-text-end-of message) + (vm-headers-of message))) b)))))) + (push-mark end) + (cond (mail-citation-hook (run-hooks 'mail-citation-hook)) + (mail-yank-hooks (run-hooks 'mail-yank-hooks)) + (t (vm-mail-yank-default message))) + )) + )) ;;; @ for tm-view ;;; +;;; based on vm-do-reply [vm-reply.el] +(defun tm-vm/do-reply (buf to-all include-text) + (save-excursion + (set-buffer buf) + (let ((dir default-directory) + to cc subject mp in-reply-to references newsgroups) + (cond ((setq to + (let ((reply-to (rfc822/get-field-body "Reply-To"))) + (if (vm-ignored-reply-to reply-to) + nil + reply-to)))) + ((setq to (rfc822/get-field-body "From"))) + ;; (t (error "No From: or Reply-To: header in message")) + ) + (if to-all + (setq cc (delq nil (cons cc (rfc822/get-field-bodies '("To" "Cc")))) + cc (mapconcat 'identity cc ",")) + ) + (setq subject (rfc822/get-field-body "Subject")) + (and subject vm-reply-subject-prefix + (let ((case-fold-search t)) + (not + (equal + (string-match (regexp-quote vm-reply-subject-prefix) + subject) + 0))) + (setq subject (concat vm-reply-subject-prefix subject))) + (setq in-reply-to (rfc822/get-field-body "Message-Id") + references (nconc + (rfc822/get-field-bodies '("References" "In-Reply-To")) + (list in-reply-to)) + newsgroups (list (or (and to-all + (rfc822/get-field-body "Followup-To")) + (rfc822/get-field-body "Newsgroups")))) + (setq to (vm-parse-addresses to) + cc (vm-parse-addresses cc)) + (if vm-reply-ignored-addresses + (setq to (vm-strip-ignored-addresses to) + cc (vm-strip-ignored-addresses cc))) + (setq to (vm-delete-duplicates to nil t)) + (setq cc (vm-delete-duplicates + (append (vm-delete-duplicates cc nil t) + to (copy-sequence to)) + t t)) + (and to (setq to (mapconcat 'identity to ",\n "))) + (and cc (setq cc (mapconcat 'identity cc ",\n "))) + (and (null to) (setq to cc cc nil)) + (setq references (delq nil references) + references (mapconcat 'identity references " ") + references (vm-parse references "[^<]*\\(<[^>]+>\\)") + references (vm-delete-duplicates references) + references (if references (mapconcat 'identity references "\n\t"))) + (setq newsgroups (delq nil newsgroups) + newsgroups (mapconcat 'identity newsgroups ",") + newsgroups (vm-parse newsgroups "[ \t\f\r\n,]*\\([^ \t\f\r\n,]+\\)") + newsgroups (vm-delete-duplicates newsgroups) + newsgroups (if newsgroups (mapconcat 'identity newsgroups ","))) + (vm-mail-internal + (if to + (format "reply to %s%s" + (rfc822/full-name-string + (car (rfc822/parse-address + (rfc822/lexical-analyze to)))) + (if cc ", ..." ""))) + to subject in-reply-to cc references newsgroups) + (setq mail-reply-buffer buf + ;; vm-system-state 'replying + default-directory dir)) + (if include-text + (save-excursion + (goto-char (point-min)) + (let ((case-fold-search nil)) + (re-search-forward + (concat "^" (regexp-quote mail-header-separator) "$") nil 0)) + (forward-char 1) + (tm-vm/yank-content))) + (run-hooks 'vm-reply-hook) + (run-hooks 'vm-mail-mode-hook) + )) + +(defun tm-vm/following-method (buf) + (tm-vm/do-reply buf 'to-all 'include-text) + ) + +(defun tm-vm/yank-content () + (interactive) + (let ((this-command 'vm-yank-message)) + (vm-display nil nil '(vm-yank-message) + '(vm-yank-message composing-message)) + (save-restriction + (narrow-to-region (point)(point)) + (insert-buffer mail-reply-buffer) + (goto-char (point-max)) + (push-mark) + (goto-char (point-min))) + (cond (mail-citation-hook (run-hooks 'mail-citation-hook)) + (mail-yank-hooks (run-hooks 'mail-yank-hooks)) + (t (mail-indent-citation))) + )) + +(set-alist 'mime-viewer/following-method-alist + 'vm-mode + (function tm-vm/following-method)) +(set-alist 'mime-viewer/following-method-alist + 'vm-virtual-mode + (function tm-vm/following-method)) + + (defun tm-vm/quit-view-message () "Quit MIME-viewer and go back to VM. This function is called by `mime-viewer/quit' command via -- 1.7.10.4