This commit was generated by cvs2svn to compensate for changes in r542,
[elisp/tm.git] / doc / tm-view_en.texi
1 @c{$Id: tm-view_en.texi,v 7.3 1995/12/13 09:30:34 morioka Exp $}
2
3 @node tm-view, encoded-word, tm-MUA, Top
4 @comment  node-name,  next,  previous,  up
5 @chapter tm-view
6 @cindex tm-view
7
8 The tm-view is a general MIME viewer running on GNU Emacs.
9
10 tm-view provides the major-mode called @code{mime/viewer-mode} to read
11 MIME message for MUA. MUA implementer can use it to add MIME function.
12
13 tm-view is a user interface kernel to view and navigate MIME message.
14 tm-view drives some programs to navigate each content-type/sub-types,
15 they are called @strong{method}. tm-view calls some programs to
16 display each content-type/sub-types in preview buffer, they are called 
17 @strong{filter}. @strong{method} and @strong{filter} are tm-view
18 application program. They expand tm-view to treat various kinds of
19 MIME types.
20
21 @menu
22 * Mechanism of tm-view::
23 * mime/viewer-mode::
24 @end menu
25
26
27 @node Mechanism of tm-view, Functions of tm-view, tm-view, tm-view
28 @comment  node-name,  next,  previous,  up
29 @chapter Mechanism of tm-view
30 @cindex mechanism of tm-view
31
32 tm-view managements two buffers, one is for raw message called
33 @strong{article buffer}, another one is to preview for user called
34 @strong{preview buffer}.
35
36 When called @code{mime/viewer-mode}, tm-view analyzes article buffer,
37 and sets its result to the variable @code{mime::article/content-info}.
38
39 After that, tm-view create a preview buffer corresponded to the
40 article buffer. As this time, tm-view modifies header and body of each
41 contents of the message. It is done by definition for Content-Types.
42
43 On the preview buffer created by tm-view, user can manipulate a
44 message to decode, such as run external vewer, extract files, or
45 print.
46
47 Notice: In this document, I call @strong{content-type} as
48 content-type/subtype of Content-Type field.
49
50
51 @menu
52 * Functions of tm-view::
53 * article-buffer::
54 * preview-buffer::
55 * method::
56 @end menu
57
58
59 @node Functions of tm-view, function to preview, Mechanism of tm-view, Mechanism of tm-view
60 @comment  node-name,  next,  previous,  up
61 @subsection Functions of tm-view
62
63 tm-view provides some available functions to decode and navigate MIME
64 message to each MUAs.
65
66 There are 2 kinds of functions, one is for MIME preview, another one
67 is to decode RFC 1522 encoded-word.
68
69 Memo: Old tiny-mime.el was abolished. Functions to decode RFC 1522
70 encoded-word are took over to tm-view.
71
72
73 @menu
74 * function to preview::
75 * encoded-word decoding::
76 @end menu
77
78
79 @node function to preview, encoded-word decoding, Functions of tm-view, Functions of tm-view
80 @comment  node-name,  next,  previous,  up
81 @subsubsection function to preview MIME message
82 @cindex mime/viewer-mode
83
84 @deffn{Command} mime/viewer-mode &optional mother ctl encoding
85
86 Parse current-buffer as a MIME message, and create preview buffer to
87 display to user, then enter @code{mime/viewer-mode}.
88
89 @var{mother} is used to specify original article buffer. It may be
90 useful when an article buffer is assembled from message/partial.
91
92 @var{ctl} is used to specify Content-Type field information. Its
93 format is output format of @code{mime/Content-Type}. When @var{ctl} is 
94 specified, tm-view uses it instead of Content-Type field of the
95 article buffer.
96
97 @var{encoding} is used to specify field-body of
98 Content-Transfer-Encoding field. When is is specified, tm-view uses it
99 instead of Content-Type field of the article buffer.
100 @end deffn
101
102
103 @include{tm-ew-d_en.texi}
104
105
106 @include{tm-view-a_en.texi}
107
108 @include{tm-view-p_en.texi}
109
110 @include{tm-view-m_en.texi}
111
112
113
114 @node mime/viewer-mode, environment variables, Functions of tm-view, tm-view
115 @comment  node-name,  next,  previous,  up
116 @section mime/viewer-mode
117 @cindex mime/viewer-mode
118
119 @code{mime/viewer-mode} is a major-mode to preview MIME message. In
120 MIME viewer mode, you can navigate MIME message interactively.
121
122 @menu
123 * MIME display::
124 * MIME navigation::
125 @end menu
126
127 @node MIME display, content-body, mime/viewer-mode, mime/viewer-mode
128 @comment  node-name,  next,  previous,  up
129 @chapter Screen design of preview buffer
130 @cindex Screen design of preview buffer
131
132 In preview buffer, following are displayed for each content:
133
134 @example
135         [content-subject]
136         (content-header)
137         
138         (content-body)
139         (content-separator)
140 @end example
141
142 You can change design or stop to display if you specify for each
143 content-types.
144
145 Example:
146
147 @example
148 From: MORIOKA Tomohiko <morioka@@jaist.ac.jp>
149 Newsgroups: zxr.comp.emacs.tm-english
150 Subject: tm6.63.tar.gz
151 Date: Mon, 26 Jun 1995 17:39:50 JST
152 Organization: Chamonix, JAIST, Tatsunokuchi, Ishikawa, Japan
153 Reply-To: tm-eng@@chamonix.jaist.ac.jp
154 To: tm-eng@@chamonix.jaist.ac.jp
155 In-Reply-To: Your message of "Sun, 25 Jun 1995 23:20:49 MST"
156 X-Mua: mh-e 4.1 + tm 6.63 / Mule 2.2 (WAKAMURASAKI) PL02
157 X-Mime-Composer: mime.el + tiny-mime 5.12
158 X-Ml-Count: 32
159
160 [1  (text/plain)]
161   I put tm6.63.tar.gz in ftp.jaist.ac.jp.
162
163   In this version, tm-view uses new MIME encoding/decoding engine
164 ``mel (MIME encoding library''. This library has internal/external
165 encoding/decoding engine. If data is smaller than a limit, tm-view
166 uses internal decoder, otherwise external decoder.
167
168 [2 tm6.63.tar.gz ([anon-ftp] ftp.jaist.ac.jp:/pub/GNU/elisp/mime/alpha)]
169
170 [3  (text/plain)]
171 ----
172 MORIOKA, Tomohiko <morioka@@jaist.ac.jp>
173 @end example
174
175
176 @menu
177 * content-subject::
178 * content-header::
179 * content-body::
180 * content-separator::
181 @end menu
182
183 @include{tm-view-cs_en.texi}
184 @include{tm-view-ch_en.texi}
185 @include{tm-view-cb_en.texi}
186
187
188 @node content-separator, , content-body, Preview Buffer
189 @comment  node-name,  next,  previous,  up
190 @section content-separator
191 @cindex content-separator
192
193 Content-separator is displayed to represent boundary of contents.
194
195 Content-separator is displayed by function
196 @code{mime-viewer/default-content-separator}. In default, it displays
197 line-break when content-header and content-body are not displayed.
198
199 If you want to change this condition, please redefine this function.
200
201
202 @deffn{Function} mime-viewer/default-content-separator cnum cinfo ctype params subj
203
204 Display content-separator. @var{cnum} is content-number of a
205 content. @var{cinfo} is content-info of the message. @var{ctype} is
206 content-type of a content. @var{params} is Content-Type field
207 parameters of a content. @var{subj} is subject.
208
209 In default, it displays line-break when content-header and
210 content-body are not displayed.
211 @end deffn
212
213
214 @node MIME navigation, method, content-body, mime/viewer-mode
215 @comment  node-name,  next,  previous,  up
216 @chapter Commands of mime/viewer-mode
217 @cindex Commands of mime/viewer-mode
218
219 @code{mime/viewer-mode} has following functions:
220
221 @table @kbd 
222 @item @key{u}
223 goes to the upper content (returns to the Summary mode if the cursor
224 is sitting on the top content (*1))
225
226 @item @key{p}
227 goes to the previous content
228
229 @item @key{n}
230 goes to the next content
231
232 @item @key{SPC}
233 scrolls up
234
235 @item @key{M-SPC}
236 scrolls down
237
238 @item @key{DEL}
239 scrolls down
240
241 @item @key{RET}
242 goes to the next line
243
244 @item @key{M-RET}
245 goes to the previous line
246
247 @item @key{<}
248 goes to the beginning of message
249
250 @item @key{>}
251 goes to the end of message
252
253 @item @key{v}
254 playbacks a content            (*2)
255
256 @item @key{e}
257 extracts a file from a content (*2)
258
259 @item @key{C-c C-p}
260 prints a content               (*2)
261
262 @item @key{f}
263 displays X-Face in the message
264
265 @item @key{mouse-button-2}
266 drives mouse button.
267
268 If you press content-subject, it playbacks the content. (*2)
269
270 If you press URL-button, it runs WWW browser.
271 @end table
272
273
274 @b{[Notice]}
275 @enumerate
276 @item
277 Not return to the Summary mode unless tm-view has been setup using
278 tm-mh-e, tm-gnus, tm-rmail etc.
279
280 @item
281 Actual playback/extract/print will be performed by a method.
282 @end enumerate