tm 7.80.
[elisp/tm.git] / README.en
1 [README for tm (English Version)]
2 by MORIOKA Tomohiko <morioka@jaist.ac.jp>
3 and KOBAYASHI Shuhei <shuhei-k@jaist.ac.jp>
4 $Id: README.en,v 7.22 1996/08/12 11:02:46 morioka Exp $
5
6 1 What's tm?
7
8   tm is a MIME package for GNU Emacs. tm has following functions:
9
10         - MIME style multilingual header
11         - MIME message viewer (mime/viewer-mode)
12         - MIME message composer (mime/editor-mode)
13         - MIME extenders for mh-e, GNUS, Gnus, RMAIL and VM
14
15
16 2 Documents
17
18   This package includes following documents.
19
20 (1) English edition
21
22 - tm/doc/tm_en.texi     : tm Reference Manual (TeXinfo)
23 - tm/doc/tm-gnus_en.texi: tm-gnus Reference Manual (TeXinfo)
24 - tm/doc/tm-mh-e_en.texi: tm-mh-e Reference Manual (TeXinfo)
25
26 (2) Japanese edition
27
28 - tm/doc/tm_ja.tex       : tm Reference Manual (TeXinfo)
29 - tm/doc/tm-gnus_ja.texi : tm-gnus Reference Manual (TeXinfo)
30 - tm/doc/tm-mh-e_ja.texi : tm-mh-e Reference Manual (TeXinfo)
31 - tm/doc/signature-jp.ol : signature.el Reference Manual (Emacs Outline)
32 - tm/doc/signature-jp.tex: signature.el Reference Manual (LaTeX)
33
34
35 3 Modules
36
37   tm has following modules:
38
39         - tm-view : MIME viewer
40                 - tm-parse.el : MIME message parser
41                 - tm-play.el  : MIME content player
42                 - tm-ew-d.el : MIME encoded-word decoder
43         - preview filter for tm-view
44                 - tm-text    : for text/*
45                 - tm-image   : for image/* and X-Face
46         - internal methods for tm-view
47                 - tm-partial : automatic assembler for message/partial
48                 - tm-ftp     : for anonymous ftp
49                 - tm-file    : for file extraction
50                 - tm-tar     : for tar content
51                 - tm-latex   : for LaTeX
52                 - tm-html    : for text/html
53                 - tm-pgp     : for PGP
54         - tm-edit : MIME composer (mime.el and tm-comp.el were merged)
55                 - tm-ew-e.el : MIME encoded-word encoder
56         - tm-def  : definition module for tm
57         - tm-MUAs : MIME extender for MUAs
58                 - tm-mh-e  : tm-MUA for mh-e
59                 - tm-gnus  : tm-MUA for GNUS
60                 - tm-rmail : tm-MUA for RMAIL
61                 - tm-vm    : tm-MUA for vm
62                 - tm-mail  : tm-MUA library module for mail-mode
63         - mime-setup: set up module for MIME
64                 - tm-setup: set up only reading
65
66
67 4 Install
68
69 4.1 edit tm/TM-CFG (optional)
70
71   You can edit tm/TM-CFG file.
72
73   In default, tm is installed into /usr/local/. If you want to change,
74 please modify the variable `PREFIX' and `EXEC_PREFIX'.
75
76
77 4.2 tm-gnus (optional)
78
79   If you use optional GNUS or Gnus, which is not included in Emacs
80 distribution, you must edit following files before make.
81
82     If you use Emacs 18.* and GNUS 3.*, please edit tm/gnus/g3-path.
83
84     If you use Emacs 18.* and GNUS 4.*, please edit tm/gnus/g4-path.
85
86     If you use Gnus 5.[01].*, please edit tm/gnus/g5-path.
87
88     If you use Gnus 5.2.*, please edit tm/gnus/s-path.
89
90
91 4.3 edit external methods (optional)
92
93   You can edit external methods in `tm/methods/' directory for your
94 environment.
95
96         tm/methods/tm-au        for audio
97         tm/methods/tm-file      for file extraction
98         tm/methods/tm-image     for image
99         tm/methods/tm-mpeg      for MPEG
100         tm/methods/tm-plain     for plain text
101         tm/methods/tm-html      for HTML
102         tm/methods/tmdecode     decoder
103
104   In default, tmdecode uses `mmencode' command. If you don't have
105 metamail package, please modify tmdecode to use decode-b instead of
106 mmencode.
107
108
109 4.4 make
110
111   Run `make all'.
112
113   You can specify Emacs command name, for example if you want to use
114 `mule' as Emacs command:
115
116         % make all EMACS=mule
117
118
119 4.5 install
120
121   Run `make install'.
122
123   You can specify Emacs command name, for example if you want to use
124 `xemacs' as Emacs command:
125
126         % make install EMACS=xemacs
127
128
129 6 .emacs
130
131   Please insert `(load "mime-setup")' in ~/.emacs.
132
133
134 6.1 automatic MIME preview support
135
136   tm-gnus provides automatic MIME preview feature for GNUS 3.15 or
137 later, Gnus 5.0.*, Gnus 5.1, and Gnus 5.2.
138
139   If you don't want to use automatic MIME preview feature, please
140 insert following to ~/.emacs.
141
142         (setq tm-gnus/automatic-mime-preview nil)
143
144   In addition, Gnus 5.2 has automatic MIME preview supporting feature. 
145 Of course, tm-gnus provides this feature for other GNUS and Gnus, but
146 it is unnatural.
147
148   When automatic MIME preview mode, GNUS and Gnus do MIME processing
149 if a message has a Mime-Version field. If it does not have, GNUS and
150 Gnus does not do MIME processing, in default.
151
152   Gnus 5.0.*, 5.1 and Gnus 5.2 have a variable `gnus-strict-mime'. If
153 you insert
154
155         (setq gnus-strict-mime nil)
156
157 Gnus do MIME processing even if a message does not have Mime-Version
158 field.
159
160   In Gnus 5.2, if `gnus-strict-mime' is not nil, variable
161 `gnus-decode-encoded-word-method' is called. tm-gnus uses it to decode
162 RFC 1522 encoded-word. So it is not necessary to reset
163 `gnus-strict-mime'.
164
165
166 6.2 VM
167
168   If you use vm, please insert `(require 'tm-vm)' in ~/.vm.
169
170   tm works well with BBDB: If you use VM, please insert
171 (require 'tm-vm) *after* (bbdb-insinuate-vm).
172
173
174 6.3 PGP
175
176   If you have PGP and Mailcrypt package, you can use PGP on
177 MIME. Currently, 2 drafts (draft-elkins-pem-pgp-02.txt and
178 draft-kazu-pgp-mime-00.txt) are proposed, so tm provides both way.
179
180   For decoding, please insert following into ~/.emacs:
181
182 ======================================================================
183 (call-after-loaded
184  'tm-view
185  (function
186   (lambda ()
187     (require 'tm-pgp)
188     )))
189 ======================================================================
190
191 tm-pgp.el is a internal method modules to support PGP.
192
193   For encoding, tm-edit provides 2 mechanism. One is for signing or
194 encrypting for message as application/pgp. There are two command
195 `mime-editor/set-sign' and `mime-editor/set-encrypt'. They set a
196 message is signed, encrypted or not.
197
198   Another one is for content. There are 2 kinds of enclosure for PGP:
199 ``signed'' and ``encrypted''. Their enclosure are bound to key and
200 menu. If you use this mechanism, please specify 2 variables:
201 `mime-editor/signing-type' and `mime-editor/encrypting-type'. They
202 requires following values:
203
204         pgp-elkins      processed as draft-elkins-pem-pgp-02.txt
205         pgp-kazu        processed as draft-kazu-pgp-mime-00.txt
206         nil             not processed
207
208 If you use ``signed'' and ``encrypted'' as draft-elkins-pem-pgp-02.txt,
209 please insert following into ~/.emacs:
210
211 ======================================================================
212 (setq mime-editor/signing-type    'pgp-elkins)
213 (setq mime-editor/encrypting-type 'pgp-elkins)
214 ======================================================================
215
216 If you use ``signed'' and ``encrypted'' as draft-kazu-pgp-mime-00.txt,
217 please insert following into ~/.emacs:
218
219 ======================================================================
220 (setq mime-editor/signing-type    'pgp-kazu)
221 (setq mime-editor/encrypting-type 'pgp-kazu)
222 ======================================================================
223
224
225 6.4 setting sample for hilit19
226
227 ======================================================================
228 (cond (window-system
229        (require 'hilit19)
230        (let* ((csubject-patterns '(("^\\[.+\\]$" nil msg-subject)))
231               (header-patterns '(("^Subject:.*$" nil msg-subject)
232                                  ("^From:.*$" nil msg-from)
233                                  ("^--text follows this line--$"
234                                   nil msg-separator)
235                                  ("^[A-Za-z][A-Za-z0-9-]+:" nil msg-header)
236                                  ))
237               (body-patterns '(("^\\(In article\\|[ \t]*\\w*[]<>}|]\\).*$"
238                                 nil msg-quote)))
239               (message-patterns (append ;;csubject-patterns
240                                  header-patterns
241                                  body-patterns))
242               )
243          (hilit-set-mode-patterns 'msg-header header-patterns)
244          (hilit-set-mode-patterns 'msg-body body-patterns)
245          (hilit-set-mode-patterns 'mime/viewer-mode
246                                   message-patterns
247                                   'hilit-rehighlight-message)
248          )
249        (add-hook 'mime-viewer/content-header-filter-hook
250                  (lambda ()
251                    (if (not (eq mime::preview/original-major-mode
252                                 'gnus-original-article-mode))
253                        (hilit-rehighlight-buffer-quietly)
254                      )))
255        (add-hook 'mime-viewer/plain-text-preview-hook
256                  (lambda ()
257                    (if (not (eq mime::preview/original-major-mode
258                                 'gnus-original-article-mode))
259                        (hilit-rehighlight-buffer-quietly)
260                      )))
261        ))
262 ======================================================================
263
264
265 6.5 setting sample for browse-url
266
267   If you have browse-url.el (included in Gnus 5.*, September Gnus and
268 Emacs 19.30 or later), you can use URL button in
269 mime/viewer-mode. Following is setting sample:
270
271 ======================================================================
272 (setq browse-url-browser-function
273       (if (eq window-system 'x)
274           'browse-url-netscape
275         'browse-url-w3))
276 (autoload browse-url-browser-function "browse-url"
277   "Ask a WWW browser to show a URL." t)
278 ======================================================================
279
280
281 7 How to use mime/viewer-mode
282
283 In tm-MUAs, you can use mime/viewer-mode if you press `v' key (in VM,
284 `Z' key) in Summary mode. Or automatic MIME previewed buffer's
285 major-mode is mime/viewer-mode. mime/viewer-mode has following
286 functions:
287
288         q         quit from mime/viewer-mode
289         u         move to upper content
290         p         move to previous content
291         n         move to next content
292         SPC       scroll up or move to next content
293         M-SPC     scroll down or move to previous content
294         DEL       scroll down or move to previous content
295         RET       move to next line
296         M-RET     move to previous line
297         <         move to beginning of message
298         >         move to end of message
299         v         play current content
300         e         extract as file current content
301         C-c C-p   print current content
302         f         display X-Face in current message
303         button-2  move to point under the mouse cursor and play
304                   current content or browse URL
305
306
307 8 Bug report
308
309 If you write bug-reports and/or propositions for improvement, please
310 send to tm ML:
311
312         bug-tm-en@chamonix.jaist.ac.jp  (English)
313         bug-tm-ja@chamonix.jaist.ac.jp  (Japanese)
314
315 Via tm ML, You can report bugs of tm, obtain the latest release of tm
316 package, and discuss the future enhancements to tm. To join tm ML,
317 send a mail to
318
319         tm-ja-admin@chamonix.jaist.ac.jp        (Japanese)
320         tm-en-admin@chamonix.jaist.ac.jp        (English)
321
322 Since the user registration is manually done, please write the mail
323 body in human-recognizable language (^_^).
324
325
326 9 How to get new version
327
328 tm is available from following anonymous ftp site:
329
330         ftp://ftp.jaist.ac.jp/pub/GNU/elisp/mime/       (Japan)
331
332 and its mirrors:
333
334         ftp://ftp.nis.co.jp/pub/gnu/emacs-lisp/tm/      (Japan)
335         ftp://ftp.nisiq.net/pub/gnu/emacs-lisp/tm/      (US)
336
337
338 10 TODO
339
340 - MUA specific key bind system for mime/viewer-mode
341 - better identification calculus system as successor of atype system
342 - development of internal method for message/external-body based on
343   tm-ftp
344 - better automatic MIME preview support
345 - etc.