From: morioka Date: Tue, 10 Mar 1998 04:58:45 +0000 (+0000) Subject: tm 7.86. X-Git-Tag: tm7_86~1 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=327711693e20cc80cb741d6c97d2c1ae3f383a70;p=elisp%2Ftm.git tm 7.86. --- diff --git a/ChangeLog b/ChangeLog index a53aeaa..ab14135 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,66 @@ +Mon Sep 23 13:16:56 1996 MORIOKA Tomohiko + + * tl: Version 7.61.6 was released. + * tm: Version 7.86 was released. + * tm-vm: Version 7.64 was released. + * gnus-mime: Version 0.8 was released. + + * tm-file.el: Method setting were changed. + + * tm-view.el (mime/content-decoding-condition): declare `mode'. + + * tm-play.el (field-unifier-for-mode): New function. + +Sat Sep 21 17:51:46 1996 MORIOKA Tomohiko + + * mime-setup.el.in (mime-setup-use-sc, mime-setup-use-signature, + mime-setup-default-signature-key, mime-setup-signature-key-alist): + Add DOC-string. + +Sat Sep 21 16:01:44 1996 MORIOKA Tomohiko + + * tm-play.el: add `mime-viewer/external-progs' to environment + variable `PATH'. + (mime-article/start-external-method-region): Don't add + `mime-viewer/external-progs' to `PATH' of local + `process-environment'. + +Sat Sep 21 15:18:22 1996 MORIOKA Tomohiko + + * tm-view.el (mime/content-decoding-condition): add tm-ps for + application/postscript. + +Sat Sep 21 14:33:25 1996 MORIOKA Tomohiko + + * tm-edit.el (mime-editor/insert-binary-file): Use macro + `as-binary-input-file'. + +Fri Sep 20 07:27:41 1996 MORIOKA Tomohiko + + * tm-parse.el (mime/parse-message): parse content of message/news + as same as message/rfc822. + +Thu Sep 19 01:56:00 1996 Martin Buchholz + + * README.en: more natural for English native speakers. + (cf. [tm-en:787]) + +Tue Sep 17 06:33:57 1996 MORIOKA Tomohiko + + * tm-file.el (mime-article/extract-file): modified for mule merged + EMACS. + + * TM-ELS (tm-modules-to-compile): Add tm-image if running mule + merged EMACS. + + * tm-image.el: support mule merged EMACS. + +Mon Sep 16 08:59:18 1996 MORIOKA Tomohiko + + * tm-ew-e.el (tm-eword::char-type): Use function `char-charset' + instead of `char-leading-char'. + + Sun Sep 15 04:17:35 1996 MORIOKA Tomohiko * tl: Version 7.61.4 was released. diff --git a/Makefile b/Makefile index eb23ec8..a77327c 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ # $Id: Makefile,v 7.29 1996/09/07 17:20:36 morioka Exp morioka $ # -VERSION = 7.85 +VERSION = 7.86 SHELL = /bin/sh MAKE = make diff --git a/README.en b/README.en index cd474a2..cb03d61 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.22 1996/08/12 11:02:46 morioka Exp $ +$Id: README.en,v 7.23 1996/09/19 11:36:44 morioka Exp $ 1 What's tm? @@ -15,7 +15,7 @@ $Id: README.en,v 7.22 1996/08/12 11:02:46 morioka Exp $ 2 Documents - This package includes following documents. + This package includes the following documents. (1) English edition @@ -70,14 +70,14 @@ $Id: README.en,v 7.22 1996/08/12 11:02:46 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' and `EXEC_PREFIX'. + By default, tm is installed into /usr/local/. If you want to change this, +please modify the variables `PREFIX' and `EXEC_PREFIX'. 4.2 tm-gnus (optional) - If you use optional GNUS or Gnus, which is not included in Emacs -distribution, you must edit following files before make. + If you use optional GNUS or Gnus, which is not included in the Emacs +distribution, you must edit the following files before running make. If you use Emacs 18.* and GNUS 3.*, please edit tm/gnus/g3-path. @@ -101,17 +101,18 @@ environment. tm/methods/tm-html for HTML tm/methods/tmdecode decoder - In default, tmdecode uses `mmencode' command. If you don't have -metamail package, please modify tmdecode to use decode-b instead of -mmencode. + By default, tmdecode uses the `mmencode' command, which is part of +the metamail package (available by anonymous ftp from +ftp://thumper.bellcore.com/pub/nsb). If you don't have the metamail +package, please modify tmdecode to use decode-b instead of mmencode. 4.4 make Run `make all'. - You can specify Emacs command name, for example if you want to use -`mule' as Emacs command: + You can specify the Emacs command name, for example if you want to use +`mule' as the Emacs command: % make all EMACS=mule @@ -120,8 +121,8 @@ mmencode. Run `make install'. - You can specify Emacs command name, for example if you want to use -`xemacs' as Emacs command: + You can specify the Emacs command name, for example if you want to use +`xemacs' as the Emacs command: % make install EMACS=xemacs @@ -137,7 +138,7 @@ mmencode. 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. +insert in ~/.emacs: (setq tm-gnus/automatic-mime-preview nil) @@ -146,20 +147,20 @@ 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. +if a message has a Mime-Version field. If it does not have one, GNUS +and Gnus does not do MIME processing, in default. 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. +Gnus does MIME processing even if a message does not have a +Mime-Version field. 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 +RFC 1522 encoded-words. So it is not necessary to reset `gnus-strict-mime'. @@ -173,11 +174,11 @@ RFC 1522 encoded-word. So it is not necessary to reset 6.3 PGP - If you have PGP and Mailcrypt package, you can use PGP on + If you have the PGP and Mailcrypt packages, you can use PGP with MIME. Currently, 2 drafts (draft-elkins-pem-pgp-02.txt and -draft-kazu-pgp-mime-00.txt) are proposed, so tm provides both way. +draft-kazu-pgp-mime-00.txt) are proposed, so tm provides both ways. - For decoding, please insert following into ~/.emacs: + For decoding, please insert the following into ~/.emacs: ====================================================================== (call-after-loaded @@ -188,14 +189,14 @@ draft-kazu-pgp-mime-00.txt) are proposed, so tm provides both way. ))) ====================================================================== -tm-pgp.el is a internal method modules to support PGP. +tm-pgp.el is an internal method module to support PGP. - For encoding, tm-edit provides 2 mechanism. One is for signing or -encrypting for message as application/pgp. There are two command + For encoding, tm-edit provides 2 mechanisms. One is for signing or +encrypting for message as application/pgp. There are two commands, `mime-editor/set-sign' and `mime-editor/set-encrypt'. They set a -message is signed, encrypted or not. +message as signed, encrypted or not. - Another one is for content. There are 2 kinds of enclosure for PGP: + Another one is for content. There are 2 kinds of enclosures for PGP: ``signed'' and ``encrypted''. Their enclosure are bound to key and menu. If you use this mechanism, please specify 2 variables: `mime-editor/signing-type' and `mime-editor/encrypting-type'. They @@ -206,7 +207,7 @@ requires following values: nil not processed If you use ``signed'' and ``encrypted'' as draft-elkins-pem-pgp-02.txt, -please insert following into ~/.emacs: +please insert into ~/.emacs: ====================================================================== (setq mime-editor/signing-type 'pgp-elkins) @@ -214,7 +215,7 @@ please insert following into ~/.emacs: ====================================================================== If you use ``signed'' and ``encrypted'' as draft-kazu-pgp-mime-00.txt, -please insert following into ~/.emacs: +please insert into ~/.emacs: ====================================================================== (setq mime-editor/signing-type 'pgp-kazu) @@ -222,7 +223,7 @@ please insert following into ~/.emacs: ====================================================================== -6.4 setting sample for hilit19 +6.4 code sample for hilit19 ====================================================================== (cond (window-system @@ -262,11 +263,11 @@ please insert following into ~/.emacs: ====================================================================== -6.5 setting sample for browse-url +6.5 code sample for browse-url If you have browse-url.el (included in Gnus 5.*, September Gnus and Emacs 19.30 or later), you can use URL button in -mime/viewer-mode. Following is setting sample: +mime/viewer-mode. Sample code follows: ====================================================================== (setq browse-url-browser-function @@ -280,8 +281,8 @@ mime/viewer-mode. Following is setting sample: 7 How to use mime/viewer-mode -In tm-MUAs, you can use mime/viewer-mode if you press `v' key (in VM, -`Z' key) in Summary mode. Or automatic MIME previewed buffer's +In tm-MUAs, you can use mime/viewer-mode if you press the `v' key (in +VM, `Z' key) in Summary mode. Or automatic MIME previewed buffer's major-mode is mime/viewer-mode. mime/viewer-mode has following functions: @@ -323,7 +324,7 @@ Since the user registration is manually done, please write the mail body in human-recognizable language (^_^). -9 How to get new version +9 How to get the latest version tm is available from following anonymous ftp site: @@ -337,7 +338,7 @@ and its mirrors: 10 TODO -- MUA specific key bind system for mime/viewer-mode +- MUA specific key binding system for mime/viewer-mode - better identification calculus system as successor of atype system - development of internal method for message/external-body based on tm-ftp diff --git a/TM-CFG b/TM-CFG index 71745fa..4609e3d 100644 --- a/TM-CFG +++ b/TM-CFG @@ -230,7 +230,8 @@ (setq BINS '("ol2" "decode-b")) (setq METHOD_SRC_DIR "methods") (setq METHODS - '("tm-au" "tm-file" "tm-html" "tm-image" "tm-mpeg" "tm-plain" + '("tm-au" "tm-file" "tm-html" "tm-image" "tm-mpeg" + "tm-plain" "tm-ps" "tmdecode")) ;;; TM-CFG ends here diff --git a/TM-ELS b/TM-ELS index 0604599..bae3bca 100644 --- a/TM-ELS +++ b/TM-ELS @@ -1,6 +1,6 @@ ;;; -*-Emacs-Lisp-*- ;;; -;;; $Id: TM-ELS,v 7.3 1996/09/06 15:40:10 morioka Exp $ +;;; $Id: TM-ELS,v 7.4 1996/09/17 04:39:33 morioka Exp $ ;;; (setq tm-modules-to-compile @@ -38,8 +38,7 @@ ) (if (or (string-match "XEmacs" emacs-version) - (boundp 'MULE) - ) + (featurep 'mule)) (setq tm-modules-to-compile (nconc tm-modules-to-compile '(tm-image))) ) diff --git a/methods/ChangeLog b/methods/ChangeLog index 983d723..4829219 100644 --- a/methods/ChangeLog +++ b/methods/ChangeLog @@ -1,12 +1,20 @@ -Thu Aug 8 15:58:28 1996 MORIOKA Tomohiko +Sat Sep 21 15:14:49 1996 MORIOKA Tomohiko - * tm-html: `grep -s' seems not work fine. + * tm-mpeg: Comment was modified. + +Sat Sep 21 15:12:12 1996 MORIOKA Tomohiko + + * tm-image: Comment was modified. + +Sat Sep 21 15:08:47 1996 MORIOKA Tomohiko -Mon Mar 25 12:35:55 1996 MORIOKA Tomohiko + * tmdecode: add x-gzip64. - * tm-au: Rob Kooper 's patch was applied for - SGI machine - (cf. [tm-en:392]) + * tm-ps: New file. + +Thu Aug 8 15:58:28 1996 MORIOKA Tomohiko + + * tm-html: `grep -s' seems not work fine. Sun Mar 24 22:40:03 1996 Rob Kooper @@ -16,13 +24,13 @@ Mon Mar 11 15:05:27 1996 MORIOKA Tomohiko * tm-html: When starting netscape to view a html message it would always start a new netscape browser. Following patch to - tm/methods/tm-html will prevent this. (cf.[bug-tm-en:373]) + tm/methods/tm-html will prevent this. (cf. [bug-tm-en:373]) Mon Mar 10 23:07:42 1996 Rob Kooper * tm-html: When starting netscape to view a html message it would always start a new netscape browser. Following patch to - tm/methods/tm-html will prevent this. (cf.[bug-tm-en:373]) + tm/methods/tm-html will prevent this. (cf. [bug-tm-en:373]) Fri Feb 23 18:26:23 1996 Morioka Tomohiko diff --git a/methods/tm-image b/methods/tm-image index 4a0336b..5691bd2 100755 --- a/methods/tm-image +++ b/methods/tm-image @@ -1,4 +1,24 @@ -#!/bin/sh +#!/bin/sh - +# +# $Id: tm-image,v 1.1 1996/09/21 15:12:12 morioka Exp $ +# +# Copyright 1994, 1995, 1996 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Emacs; see the file COPYING. If not, write to the +# Free Software Foundation, Inc., 59 Temple Place - Suite 330, +# Boston, MA 02111-1307, USA. + if [ "$TM_TMP_DIR" = "" ]; then TM_TMP_DIR=/tmp export TM_TMP_DIR @@ -41,7 +61,7 @@ tmdecode $3 $1 $filename case "$4" in "play") xv -geometry +1+1 $filename - /bin/rm $filename + trap 'rm -f $filename' 0 1 2 3 13 15 ;; "extract") echo "extract to $filename" diff --git a/methods/tm-mpeg b/methods/tm-mpeg index c9d51ff..20231aa 100755 --- a/methods/tm-mpeg +++ b/methods/tm-mpeg @@ -1,4 +1,24 @@ -#!/bin/sh +#!/bin/sh - +# +# $Id: tm-mpeg,v 1.1 1996/09/21 15:14:49 morioka Exp $ +# +# Copyright 1994, 1995, 1996 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Emacs; see the file COPYING. If not, write to the +# Free Software Foundation, Inc., 59 Temple Place - Suite 330, +# Boston, MA 02111-1307, USA. + if [ "$TM_TMP_DIR" = "" ]; then TM_TMP_DIR=/tmp export TM_TMP_DIR @@ -20,7 +40,7 @@ case "$4" in export VIDEO_DITHER fi mpeg_play -dither $VIDEO_DITHER $filename - /bin/rm $filename + trap 'rm -f $filename' 0 1 2 3 13 15 ;; "extract") echo "extract to $filename" diff --git a/methods/tm-ps b/methods/tm-ps new file mode 100755 index 0000000..e413fb1 --- /dev/null +++ b/methods/tm-ps @@ -0,0 +1,48 @@ +#!/bin/sh - +# +# $Id: tm-ps,v 1.1 1996/09/21 15:07:41 morioka Exp $ +# +# Copyright 1994, 1995, 1996 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Emacs; see the file COPYING. If not, write to the +# Free Software Foundation, Inc., 59 Temple Place - Suite 330, +# Boston, MA 02111-1307, USA. + +if [ "$TM_TMP_DIR" = "" ]; then + TM_TMP_DIR=/tmp + export TM_TMP_DIR +fi +if [ "$5" = "" ]; then + filename="$TM_TMP_DIR/mime$$.pln" +else + filename="$TM_TMP_DIR/$5" +fi + +case "$4" in +"play") + echo "$2; $3 -> $filename" + tmdecode $3 $1 $filename + ghostview $filename + trap 'rm -f $filename' 0 1 2 3 13 15 + ;; +"extract") + echo "$2; $3 -> $filename" + echo "extract to $filename" + tmdecode "$3" "$1" $filename + ;; +"print") + echo "$2; $3 ->" + tmdecode "$3" "$1" /dev/stdout | lpr + ;; +esac diff --git a/methods/tmdecode b/methods/tmdecode index 65fbe0c..5f251b9 100755 --- a/methods/tmdecode +++ b/methods/tmdecode @@ -1,7 +1,23 @@ #!/bin/sh - # -# $Id: tmdecode,v 3.0 1995/12/18 11:36:36 morioka Exp morioka $ +# $Id: tmdecode,v 4.0 1996/09/21 15:08:47 morioka Exp $ # +# Copyright 1994, 1995, 1996 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2, or (at your option) +# any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GNU Emacs; see the file COPYING. If not, write to the +# Free Software Foundation, Inc., 59 Temple Place - Suite 330, +# Boston, MA 02111-1307, USA. trap 'rm -f $2' 0 1 2 3 13 15 diff --git a/mime-setup.el.in b/mime-setup.el.in index 3ea32fb..d9fe8d1 100644 --- a/mime-setup.el.in +++ b/mime-setup.el.in @@ -3,9 +3,8 @@ ;; Copyright (C) 1995,1996 Free Software Foundation, Inc. ;; Author: MORIOKA Tomohiko -;; Maintainer: Shuhei KOBAYASHI ;; Version: -;; $Id: mime-setup.el.in,v 7.27 1996/09/04 16:14:03 morioka Exp $ +;; $Id: mime-setup.el.in,v 7.28 1996/09/21 17:51:46 morioka Exp $ ;; Keywords: mail, news, MIME, multimedia, multilingual, encoded-word ;; This file is part of tm (Tools for MIME). @@ -21,8 +20,8 @@ ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. ;;; Code: @@ -56,10 +55,18 @@ ;;; @ variables ;;; -(defvar mime-setup-use-sc nil) -(defvar mime-setup-use-signature t) -(defvar mime-setup-default-signature-key "\C-c\C-s") -(defvar mime-setup-signature-key-alist '((mail-mode . "\C-c\C-w"))) +(defvar mime-setup-use-sc nil + "If it is not nil, mime-setup requires sc-setup. [mime-setup.el]") + +(defvar mime-setup-use-signature t + "If it is not nil, mime-setup sets up to use signature.el. +\[mime-setup.el]") + +(defvar mime-setup-default-signature-key "\C-c\C-s" + "*Key to insert signature. [mime-setup.el]") + +(defvar mime-setup-signature-key-alist '((mail-mode . "\C-c\C-w")) + "Alist of major-mode vs. key to insert signature. [mime-setup.el]") ;;; @ for signature diff --git a/tm-edit.el b/tm-edit.el index 73c9f49..f62b31c 100644 --- a/tm-edit.el +++ b/tm-edit.el @@ -6,7 +6,7 @@ ;; MORIOKA Tomohiko ;; Maintainer: MORIOKA Tomohiko ;; Created: 1994/08/21 renamed from mime.el -;; Version: $Revision: 7.85 $ +;; Version: $Revision: 7.86 $ ;; Keywords: mail, news, MIME, multimedia, multilingual ;; This file is part of tm (Tools for MIME). @@ -121,7 +121,7 @@ ;;; (defconst mime-editor/RCS-ID - "$Id: tm-edit.el,v 7.85 1996/09/15 04:17:35 morioka Exp $") + "$Id: tm-edit.el,v 7.86 1996/09/21 14:33:25 morioka Exp $") (defconst mime-editor/version (get-version-string mime-editor/RCS-ID)) @@ -1031,15 +1031,8 @@ Optional argument ENCODING specifies an encoding method such as base64." (save-excursion (set-buffer tmpbuf) (erase-buffer) - (let ((mc-flag nil) ;Mule - (file-coding-system-for-read - (if (featurep 'mule) *noconv*)) - (kanji-flag nil) ;NEmacs - (emx-binary-mode t) ;Stop CRLF to LF conversion in OS/2 - ) - (let (jka-compr-compression-info-list - jam-zcat-filename-list) - (insert-file-contents file)))) + (as-binary-input-file (insert-file-contents file)) + ) (prog1 (if (and (stringp encoding) (string-equal (downcase encoding) "x-uue")) diff --git a/tm-ew-e.el b/tm-ew-e.el index d78a5cb..255b569 100644 --- a/tm-ew-e.el +++ b/tm-ew-e.el @@ -3,7 +3,7 @@ ;; Copyright (C) 1995,1996 Free Software Foundation, Inc. ;; Author: MORIOKA Tomohiko -;; Version: $Revision: 7.53 $ +;; Version: $Revision: 7.54 $ ;; Keywords: mail, news, MIME, RFC 1522, multilingual, encoded-word ;; This file is part of tm (Tools for MIME). @@ -35,7 +35,7 @@ ;;; (defconst tm-ew-e/RCS-ID - "$Id: tm-ew-e.el,v 7.53 1996/09/04 22:02:02 morioka Exp $") + "$Id: tm-ew-e.el,v 7.54 1996/09/16 08:59:18 morioka Exp $") (defconst mime-eword/encoder-version (get-version-string tm-ew-e/RCS-ID)) @@ -118,7 +118,7 @@ when Subject field is encoded by `mime/encode-message-header'. (defun tm-eword::char-type (chr) (if (or (= chr 32)(= chr ?\t)) nil - (char-leading-char chr) + (char-charset chr) )) (defun tm-eword::parse-lc-word (str) diff --git a/tm-file.el b/tm-file.el index 105f62b..7801ca7 100644 --- a/tm-file.el +++ b/tm-file.el @@ -1,32 +1,29 @@ -;;; ;;; tm-file.el --- tm-view internal method for file extraction -;;; -;;; Copyright (C) 1995 Free Software Foundation, Inc. -;;; Copyright (C) 1995,1996 MORIOKA Tomohiko -;;; -;;; Author: MORIOKA Tomohiko -;;; modified by KOBAYASHI Shuhei -;;; Maintainer: KOBAYASHI Shuhei -;;; Version: -;;; $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). -;;; -;;; This program is free software; you can redistribute it and/or -;;; modify it under the terms of the GNU General Public License as -;;; published by the Free Software Foundation; either version 2, or -;;; (at your option) any later version. -;;; -;;; This program is distributed in the hope that it will be useful, -;;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -;;; General Public License for more details. -;;; -;;; You should have received a copy of the GNU General Public License -;;; along with This program. If not, write to the Free Software -;;; Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. -;;; + +;; Copyright (C) 1995,1996 Free Software Foundation, Inc. + +;; Author: MORIOKA Tomohiko +;; modified by Shuhei KOBAYASHI +;; Version: $Id: tm-file.el,v 7.8 1996/09/23 13:16:56 morioka Exp $ +;; Keywords: mail, news, MIME, multimedia, file, extract + +;; This file is part of tm (Tools for MIME). + +;; This program is free software; you can redistribute it and/or +;; modify it under the terms of the GNU General Public License as +;; published by the Free Software Foundation; either version 2, or (at +;; your option) any later version. + +;; This program is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; Boston, MA 02111-1307, USA. + ;;; Code: (require 'tm-view) @@ -63,7 +60,8 @@ (save-excursion (set-buffer tmp-buf) (mime-decode-region (point-min)(point-max) encoding) - (let ((mc-flag nil) ; for Mule + (let ((coding-system-for-write 'no-conversion) + (mc-flag nil) ; for Mule (file-coding-system (if (featurep 'mule) *noconv*)) kanji-flag ; for NEmacs @@ -81,14 +79,20 @@ ;;; (set-atype 'mime/content-decoding-condition - '((mode . "extract") + '((type . "application/octet-stream") (method . mime-article/extract-file) - )) + ) + 'ignore '(method) + 'replacement) (set-atype 'mime/content-decoding-condition - '((type . "application/octet-stream") + '((mode . "extract") (method . mime-article/extract-file) - )) + ) + 'remove + '((method "tm-file" nil 'file 'type 'encoding 'mode 'name) + (mode . "extract")) + 'replacement) ;;; @ end diff --git a/tm-image.el b/tm-image.el index 84c109b..74e1692 100644 --- a/tm-image.el +++ b/tm-image.el @@ -7,7 +7,7 @@ ;; Dan Rich ;; Maintainer: MORIOKA Tomohiko ;; Created: 1995/12/15 -;; Version: $Id: tm-image.el,v 7.14 1996/08/28 18:43:29 morioka Exp $ +;; Version: $Id: tm-image.el,v 7.15 1996/09/17 04:38:00 morioka Exp $ ;; Keywords: mail, news, MIME, multimedia, image, picture, X-Face @@ -108,7 +108,8 @@ (highlight-headers (point-min) (re-search-forward "^$" nil t) t) ) ) - ((boundp 'MULE) + ((featurep 'mule) + ;; for MULE 2.* or mule merged EMACS (require 'x-face-mule) (defvar tm-image/inline-image-types '("image/x-mag" "image/x-xbm")) diff --git a/tm-parse.el b/tm-parse.el index 01ae867..e5a390f 100644 --- a/tm-parse.el +++ b/tm-parse.el @@ -3,8 +3,7 @@ ;; Copyright (C) 1994,1995,1996 Free Software Foundation, Inc. ;; Author: MORIOKA Tomohiko -;; Version: -;; $Id: tm-parse.el,v 7.12 1996/09/14 08:51:36 morioka Exp $ +;; Version: $Id: tm-parse.el,v 7.13 1996/09/20 07:27:41 morioka Exp $ ;; Keywords: mail, news, MIME, multimedia ;; This file is part of tm (Tools for MIME). @@ -186,7 +185,9 @@ and return parsed it. [tm-parse.el]" (setq boundary (std11-strip-quoted-string (cdr boundary))) (mime/parse-multipart boundary ctype params encoding rcnum) ) - ((string-equal ctype "message/rfc822") + ((or (string-equal ctype "message/rfc822") + (string-equal ctype "message/news") + ) (goto-char (point-min)) (mime::content-info/create rcnum (point-min) (point-max) diff --git a/tm-play.el b/tm-play.el index 01eefef..acbf645 100644 --- a/tm-play.el +++ b/tm-play.el @@ -4,7 +4,7 @@ ;; Author: MORIOKA Tomohiko ;; Created: 1995/9/26 (separated from tm-view.el) -;; Version: $Id: tm-play.el,v 7.27 1996/09/14 08:53:38 morioka Exp $ +;; Version: $Id: tm-play.el,v 7.29 1996/09/23 13:14:07 morioka Exp $ ;; Keywords: mail, news, MIME, multimedia ;; This file is part of tm (Tools for MIME). @@ -20,8 +20,8 @@ ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with this program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. ;;; Code: @@ -33,7 +33,15 @@ (add-to-list 'exec-path mime-viewer/external-progs) - +(let ((paths (parse-colon-path (getenv "PATH")))) + (or (member mime-viewer/external-progs paths) + (setenv "PATH" + (mapconcat (function identity) + (append paths (list mime-viewer/external-progs)) + path-separator)) + )) + + ;;; @ content decoder ;;; @@ -96,6 +104,15 @@ ) )) +(defun field-unifier-for-mode (a b) + (let ((va (cdr a))) + (if (if (consp va) + (member (cdr b) va) + (equal va (cdr b)) + ) + (list nil b nil) + ))) + (defun mime/get-content-decoding-alist (al) (get-unified-alist mime/content-decoding-condition al) ) @@ -137,34 +154,7 @@ (mime-article/make-method-args cal (cdr (cdr method))) )) - (let ((process-environment - (let* ((rest process-environment) - (dest (cons nil nil)) - (prest dest) - (path nil) - cell) - (while (and (setq cell (car rest)) - (not - (if (string-match "^PATH=" cell) - (setq path - (format - "PATH=%s:%s" - mime-viewer/external-progs - (substring cell (match-end 0)) - ))))) - (setcar prest cell) - (setcdr prest (cons nil nil)) - (setq rest (cdr rest) - prest (cdr prest)) - ) - (setcar - prest - (or path - (format "PATH=%s" mime-viewer/external-progs))) - (setcdr prest (cdr rest)) - dest))) - (apply (function start-process) args) - ) + (apply (function start-process) args) (mime-article/show-output-buffer) )) )))) diff --git a/tm-view.el b/tm-view.el index e8b817c..e1c6415 100644 --- a/tm-view.el +++ b/tm-view.el @@ -4,7 +4,7 @@ ;; Author: MORIOKA Tomohiko ;; Created: 1994/7/13 (1994/8/31 obsolete tm-body.el) -;; Version: $Revision: 7.75 $ +;; Version: $Revision: 7.77 $ ;; Keywords: mail, news, MIME, multimedia ;; This file is part of tm (Tools for MIME). @@ -20,8 +20,8 @@ ;; General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with This program; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330, +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, ;; Boston, MA 02111-1307, USA. ;;; Code: @@ -42,7 +42,7 @@ ;;; (defconst mime-viewer/RCS-ID - "$Id: tm-view.el,v 7.75 1996/09/14 08:56:05 morioka Exp $") + "$Id: tm-view.el,v 7.77 1996/09/23 13:15:09 morioka Exp $") (defconst mime-viewer/version (get-version-string mime-viewer/RCS-ID)) (defconst mime/viewer-version mime-viewer/version) @@ -53,50 +53,84 @@ (defvar mime/content-decoding-condition '(((type . "text/plain") - (method "tm-plain" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-plain" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "text/html") (method "tm-html" nil 'file 'type 'encoding 'mode 'name) - (mode . "play")) + (mode . "play") + ) ((type . "text/x-rot13-47") - (method . mime-article/decode-caesar)) - + (method . mime-article/decode-caesar) + (mode . "play") + ) ((type . "audio/basic") - (method "tm-au" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-au" nil 'file 'type 'encoding 'mode 'name) + (mode . "play") + ) ((type . "image/jpeg") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/gif") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/tiff") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/x-tiff") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/x-xbm") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/x-pic") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "image/x-mag") - (method "tm-image" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-image" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "video/mpeg") - (method "tm-mpeg" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-mpeg" nil 'file 'type 'encoding 'mode 'name) + (mode . "play") + ) + ((type . "application/postscript") + (method "tm-ps" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ((type . "application/octet-stream") - (method "tm-file" nil 'file 'type 'encoding 'mode 'name)) + (method "tm-file" nil 'file 'type 'encoding 'mode 'name) + (mode "play" "print") + ) ;;((type . "message/external-body") ;; (method "xterm" nil ;; "-e" "showexternal" ;; 'file '"access-type" '"name" '"site" '"directory")) ((type . "message/rfc822") - (method . mime-article/view-message/rfc822)) + (method . mime-article/view-message/rfc822) + (mode . "play") + ) ((type . "message/partial") - (method . mime-article/decode-message/partial)) + (method . mime-article/decode-message/partial) + (mode . "play") + ) - ((method "metamail" t - "-m" "tm" "-x" "-d" "-z" "-e" 'file)(mode . "play")) + ((method "metamail" t "-m" "tm" "-x" "-d" "-z" "-e" 'file) + (mode . "play") + ) ((method "tm-file" nil 'file 'type 'encoding 'mode 'name) - (mode . "extract")) + (mode . "extract") + ) )) (defvar mime-viewer/childrens-header-showing-Content-Type-list