tm 7.100.
[elisp/tm.git] / doc / tm-view-en.info
1 This is Info file tm-view-en.info, produced by Makeinfo-1.63 from the
2 input file tm-view-en.texi.
3
4 \1f
5 File: tm-view-en.info,  Node: Top,  Next: Introduction,  Prev: (dir),  Up: (dir)
6
7 tm-view 7.79 Reference Manual (English Version)
8 ***********************************************
9
10    This file documents tm-view, a MIME Viewer for GNU Emacs.
11
12 * Menu:
13
14 * Introduction::                What is tm-view?
15 * MIME display::                Structure of display in mime/viewer-mode
16 * mime/viewer-mode::            Navigation in mime/viewer-mode
17 * method::                      Mechanism of decoding
18 * Two buffers for an article::  raw-article-buffer and preview-buffer
19 * API::                         Functions to decode MIME message
20 * Acknowledgments::
21 * Concept Index::
22 * Function Index::
23 * Variable Index::
24
25 \1f
26 File: tm-view-en.info,  Node: Introduction,  Next: MIME display,  Prev: Top,  Up: Top
27
28 What is tm-view?
29 ****************
30
31    The tm-view is a general MIME viewer running on GNU Emacs.
32
33    tm-view provides the major-mode called `mime/viewer-mode' (*Note
34 mime/viewer-mode::) to read MIME message for MUA.  MUA (*Note
35 (tm-en)MUA::) implementer can use it to add MIME function.
36
37    tm-view is a user interface kernel to view and navigate MIME message.
38 tm-view drives some programs to navigate each content-type (*Note
39 (tm-en)content-type::)s, they are called *method* (*Note method::).
40 tm-view calls some programs to display each contents and headers in
41 preview buffer, they are called *filter* (*Note Two buffers for an
42 article::).  Method and filters are tm-view application program.  They
43 expand tm-view to treat various kinds of MIME types.
44
45 \1f
46 File: tm-view-en.info,  Node: MIME display,  Next: mime/viewer-mode,  Prev: Introduction,  Up: Top
47
48 Structure of display in mime/viewer-mode
49 ****************************************
50
51    In mime/viewer-mode (*Note mime/viewer-mode::), following are
52 displayed for each parts:
53
54         [content-button]
55         (content-header)
56      
57         (content-body)
58         (content-separator)
59
60    You can change design or stop to display if you specify for each
61 conditions, such as content-types.
62
63    Example:
64
65      From: morioka@jaist.ac.jp (MORIOKA Tomohiko)
66      Subject: Re: Question
67      Newsgroups: zxr.message.mime
68      Date: 22 Oct 93 11:02:44
69      Mime-Version: 1.0
70      Organization: Japan Advanced Institute of Science and Technology,
71              Ishikawa, Japan
72      
73      [1  (text/plain)]
74        How to compose MIME message in MIME-Edit mode.
75      
76        Press `C-c C-x ?' then help message will be displayed:
77      
78      C-c C-x C-t        insert a text message.
79      C-c C-x TAB        insert a (binary) file.
80      C-c C-x C-e        insert a reference to external body.
81      C-c C-x C-v        insert a voice message.
82      C-c C-x C-y        insert a mail or news message.
83      C-c C-x RET        insert a mail message.
84      C-c C-x C-s        insert a signature file at end.
85      C-c C-x t  insert a new MIME tag.
86      C-c C-x a  enclose as multipart/alternative.
87      C-c C-x p  enclose as multipart/parallel.
88      C-c C-x m  enclose as multipart/mixed.
89      C-c C-x d  enclose as multipart/digest.
90      C-c C-x s  enclose as PGP signed.
91      C-c C-x e  enclose as PGP encrypted.
92      C-c C-x C-k        insert PGP public key.
93      C-c C-x C-p        preview editing MIME message.
94      ...
95      
96      So press `C-c C-x C-i' and specify file name you want to include.
97      
98        MIME encoding for binary file is normally Base64.
99      
100      [2  (image/gif)]
101      
102      [3  (text/plain)]
103      
104        In this way, it is finish a message attaching a picture.
105      
106      ======================== A cup of Russian tea ========================
107      ============  * not by jam, not by marmalade, by honey *  ============
108      ============               MORIOKA Tomohiko               ============
109      =============== Internet E-mail: <morioka@jaist.ac.jp> ===============
110
111 * Menu:
112
113 * content-button::
114 * content-header::
115 * content-body::
116 * content-separator::
117
118 \1f
119 File: tm-view-en.info,  Node: content-button,  Next: content-header,  Prev: MIME display,  Up: MIME display
120
121 content-button
122 ==============
123
124    content-subject displays abstract for the part.  It is placed in top
125 of the part.
126
127    In default, it is displayed following design:
128
129              [1.3 test (text/plain)]
130
131    First number field represents position of a content in the part.  It
132 is called *content-number*.  It can be considered as the chapter number
133 in the message.
134
135    Second string part represents title.  It is created by following:
136
137   1. name paramater or x-name parameter in Content-Type field (*Note
138      (tm-en)Content-Type field::)
139
140   2. Content-Description field (*Note (tm-en)Content-Description
141      field::) or Subject field
142
143   3.  filename of uuencode
144
145    If they are not exists, space is displayed.
146
147    Third parenthesis part represents content-type/subtype of the part.
148 If it is non-MIME part, `nil' is displayed.
149
150    Content-button is used like icon when content-header (*Note
151 content-header::) and content-body (*Note content-body::) are hidden.
152 For example:
153
154              [2  (image/gif)]
155
156 if you press `v' key, GIF image is displayed.
157
158    If mouse operations are available, you can press content-button by
159 mouse button-2 (center button of 3 button-mouse) to play, similarly to
160 press `v' key. (cf. *Note mime/viewer-mode::)
161
162    By the way, it is annoying to display content-button if
163 content-header is displayed.  So tm-view provides a mechanism to
164 specify conditions to display content-button.
165
166  - Variable: mime-viewer/content-button-ignored-ctype-list
167      List of content-types.
168
169      If content-type of a part is a member of this list, its
170      content-button is not displayed.
171
172 \1f
173 File: tm-view-en.info,  Node: content-header,  Next: content-body,  Prev: content-button,  Up: MIME display
174
175 content-header
176 ==============
177
178    A content header displays the header portion of a part in the
179 preview-buffer.  However it is annoying to display header for every
180 parts, so tm-view provides a mechanism to specify its condition.
181
182    When the function `mime-viewer/header-visible-p' returns `t' for
183 reversed-content-number of a part, content-header is displayed.
184
185    This judge function returns `t' when a part is root or content-type
186 of its parent is a member of the variable
187 `mime-viewer/childrens-header-showing-Content-Type-list'.
188
189    If you want to change this condition, please redefine it.  Notice
190 that it refers variable
191 `mime-viewer/childrens-header-showing-Content-Type-list', however if
192 you redefine function `mime-viewer/header-visible-p', it may not work.
193 So if you want to redefine it, it should be refer variable
194 `mime-viewer/childrens-header-showing-Content-Type-list'.
195
196    When content-header is displayed, content-header are formated by the
197 program called by *content-header-filter*.  Content-header-filter is
198 searched from variable `mime-viewer/content-header-filter-alist'.  Its
199 key is major-mode of the raw-article-buffer (*Note
200 raw-article-buffer::).  If not found, function
201 `mime-viewer/default-content-header-filter' is called.
202
203  - Variable: mime-viewer/childrens-header-showing-Content-Type-list
204      List of content-types.  If content-type of parent of a part is a
205      member of this variable, its content-header is displayed.  Default
206      value is `'("message/rfc822" "message/news")'.
207
208      This variable is referred by the function
209      `mime-viewer/header-visible-p'.
210
211  - Function: mime-viewer/header-visible-p RCNUM CINFO &optional CTYPE
212      Returns `t' if a part which reversed-content-number is RCNUM in
213      content-info CINFO is displayed.
214
215      If you know content-type, you can specify by CTYPE.
216
217  - Variable: mime-viewer/content-header-filter-alist
218      Association-list whose key is major-mode of a raw-article-buffer,
219      value is content-header-filter.
220
221  - Function: mime-viewer/default-content-header-filter
222      It is called when content-header-filter is not found in variable
223      `mime-viewer/content-header-filter-alist'.
224
225      It refers `mime-viewer/ignored-field-regexp'.
226
227  - Variable: mime-viewer/ignored-field-list
228      List of regular expression to represent invisible fields even if
229      content-header is displayed.
230
231      Variable `mime-viewer/ignored-field-regexp' is created from it.
232
233      Please use function `tm:add-fields' or `tm:delete-fields' to set
234      it.
235
236 \1f
237 File: tm-view-en.info,  Node: content-body,  Next: content-separator,  Prev: content-header,  Up: MIME display
238
239 content-body
240 ============
241
242    *content-body* represents content of the part.
243
244    tm-view does not display raw content body.  For example, if a content
245 has binary, it is hidden.  If a content has text/enriched, it is
246 formated.  Namely content body is hidden or formated.
247
248    Function `mime-viewer/body-visible-p' is a judge function whether
249 content-body of a content is displayed.  If it returns `nil',
250 content-body is hidden.  In default, it returns non-`nil' when
251 content-type of a part is a member of variable
252 `mime-viewer/default-showing-Content-Type-list'.
253
254    When content-body of a content is displayed, content-body is
255 formated by *content-filter*.  Content-filter is searched from variable
256 `mime-viewer/content-filter-alist'.  At this time, major-mode of the
257 raw-article-buffer (*Note raw-article-buffer::) is used as the key.
258
259    If it is not found, function `mime-viewer/default-content-filter' is
260 called.
261
262  - Variable: mime-viewer/default-showing-Content-Type-list
263      List of content-type.  If content-type of a part is a member of
264      this variable, its body is displayed.
265
266  - Function: mime-viewer/body-visible-p RCNUM CINFO &optional CTYPE
267      Return non-`nil', if content-type of a part is displayed.  RCNUM
268      is reversed-content-number of a part.  CINFO is content-info of
269      the message.  If you know content-type of a part, you can specify
270      it as argument CTYPE.
271
272  - Variable: mime-viewer/content-filter-alist
273      Association-list whose key is major-mode of a raw-article-buffer,
274      value is content-filter.
275
276  - Function: mime-viewer/default-content-filter RCNUM CINFO CTYPE
277           PARAMS SUBJ
278      It is called when content-body of a part should be displayed and
279      content-filter is not found in `mime-viewer/content-filter-alist'.
280
281      In default, it does nothing.
282
283 \1f
284 File: tm-view-en.info,  Node: content-separator,  Prev: content-body,  Up: MIME display
285
286 content-separator
287 =================
288
289    *content-separator* is displayed to represent boundary of contents.
290
291    Content-separator is displayed by function
292 `mime-viewer/default-content-separator'.  In default, it displays
293 line-break when content-header and content-body are not displayed.
294
295    If you want to change this condition, please redefine this function.
296
297  - Function: mime-viewer/default-content-separator RCNUM CINFO CTYPE
298           PARAMS SUBJ
299      Display content-separator.  CNUM is content-number of a content.
300      CINFO is content-info of the message.  CTYPE is content-type of a
301      content.  PARAMS is Content-Type field parameters of a content.
302      SUBJ is subject.
303
304      In default, it displays line-break when content-header and
305      content-body are not displayed.
306
307 \1f
308 File: tm-view-en.info,  Node: mime/viewer-mode,  Next: method,  Prev: MIME display,  Up: Top
309
310 Navigation in mime/viewer-mode
311 ******************************
312
313    `mime/viewer-mode' has following functions:
314
315 `u'
316      goes to the upper content (returns to the Summary mode if the
317      cursor is sitting on the top content (*1))
318
319 `p'
320      goes to the previous content
321
322 `n'
323      goes to the next content
324
325 `SPC'
326      scrolls up
327
328 `M-SPC'
329      scrolls down
330
331 `DEL'
332      scrolls down
333
334 `RET'
335      goes to the next line
336
337 `M-RET'
338      goes to the previous line
339
340 `<'
341      goes to the beginning of message
342
343 `>'
344      goes to the end of message
345
346 `v'
347      playbacks a part (*2)
348
349 `e'
350      extracts a file from a part (*2)
351
352 `C-c C-p'
353      prints a part (*2)
354
355 `f'
356      displays X-Face in the message
357
358 `mouse-button-2'
359      drives mouse button in preview-buffer.
360
361      For content-button, it playbacks a part (*2)
362
363      For URL-button, it drives WWW browser
364
365 *[Notice]*
366      (*1) Not return to the Summary mode unless tm-view has been setup
367      using tm-mh-e, tm-vm, gnus-mime, tm-gnus, tm-rmail etc.
368
369      (*2) Actual playback/extract/print will be performed by a method.
370
371 \1f
372 File: tm-view-en.info,  Node: method,  Next: Two buffers for an article,  Prev: mime/viewer-mode,  Up: Top
373
374 Mechanism of decoding
375 *********************
376
377    In `mime/viewer-mode', you can do play (`v'), extract (`e'), or
378 print (`C-c C-p') for each parts.  These operations are called
379 *decoding operation(s) (for a part)*.  And kind of decoding operations
380 are called *decoding-mode*.
381
382    When decoding operation is driven, tm-view calls a procedure matched
383 for the condition, such as content-type (*Note (tm-en)content-type::)
384 of the part or its environment.  This procedure is called *method*.
385
386    There are two kinds of methods.  One is Emacs Lisp function, called
387 *internal method*.  Another one is external program, called *external
388 method*.
389
390    Internal method operates in Emacs, so it can do carefully.
391
392    External method is called as asynchronous process, so Emacs does not
393 wait while method is running.  So it is good for big data, such as
394 audio, image or video.
395
396 * Menu:
397
398 * decoding-condition::          Setting decoding condition for parts
399 * environment variables::       Environment variables
400
401 \1f
402 File: tm-view-en.info,  Node: decoding-condition,  Next: environment variables,  Prev: method,  Up: method
403
404 Setting decoding condition for parts
405 ====================================
406
407    When decoding operation is driven, tm-view calls a method matched for
408 the condition searched from the variable
409 `mime/content-decoding-condition'.
410
411    Variable `mime/content-decoding-condition' is defined as a list with
412 the following syntax:
413
414              (condition_1 condition_2 ...)
415
416    Each condition are association-list with the following syntax:
417
418              ((field-type_1 . value_1)
419               (field-type_2 . value_2)
420               ...)
421
422    For example, if you want to call the external method named tm-plain
423 to decode every text/plain (*Note (tm-en)text/plain::) type parts, you
424 can define the condition like:
425
426              ((type . "text/plain")
427               (method "tm-plain" nil 'file 'type 'encoding 'mode 'name))
428
429    This condition definition will match all parts whose content-type
430 (*Note (tm-en)content-type::) are text/plain.  Here is an another
431 example:
432
433              ((type . "text/plain")
434               (method "tm-plain" nil 'file 'type 'encoding 'mode 'name)
435               (mode . "play"))
436
437    This will match the part whose type is text/plain and the mode is
438 play.
439
440    Here is an another example:
441
442              ((method "metamail" t "-m" "tm" "-x" "-d" "-z" "-e" 'file)
443               (mode . "play"))
444
445    This will match all parts which have a mode of play.
446
447    The conditions defined in a variable
448 `mime/content-decoding-condition' are examined from top to bottom.  The
449 first matching condition becomes valid and the method specified in that
450 condition definition will be executed.
451
452 * Menu:
453
454 * method value::                Format of method value
455 * Example of decoding-condition::
456
457 \1f
458 File: tm-view-en.info,  Node: method value,  Next: Example of decoding-condition,  Prev: decoding-condition,  Up: decoding-condition
459
460 Format of method value
461 ----------------------
462
463    You can specify the method field of the decoding-condition
464 definition in two different ways,
465
466              (method . SYMBOL)
467
468 or
469
470              (method  STRING  FLAG  arg1  arg2  ...)
471
472 can be accepted.
473
474    When a symbol is specified in the method field, a function whose
475 name is SYMBOL will be called as an internal method.
476
477    When a list is specified in the method field, it will be called as an
478 external method.
479
480    The list below shows the meaning of the parameters when the external
481 method is specified in the method field.
482
483 `STRING'
484      name of an external method
485
486 `FLAG'
487      If `t', both the content-header and the content-body are passed to
488      an external method.
489
490      If `nil', only the content-body is passed to an external method.
491
492 `ARGUMENTs'
493      list of arguments passed to an external method
494
495    An argument passed to an external method can be in one of the
496 following formats:
497
498 `STRING'
499      string itself
500
501 `'SYMBOL'
502      value gotten using SYMBOL as a key from decoding-condition
503
504 `'STRING'
505      value gotten using STRING as a key from decoding-condition
506
507    `'SYMBOL' can be one of the following:
508
509 `'file'
510      name of a file holding the original content
511
512 `'type'
513      content-type/sub-type of Content-Type field
514
515 `'encoding'
516      field body of Content-Transfer-Encoding field
517
518 `'mode'
519      decoding-mode
520
521 `'name'
522      name of a file created by decode operation
523
524    `'STRING' is used to search a parameter of the Content-Type field
525 whose name matches with it, and pass the value of that parameter to the
526 external method.
527
528 \1f
529 File: tm-view-en.info,  Node: Example of decoding-condition,  Prev: method value,  Up: decoding-condition
530
531 Example of decoding-condition
532 -----------------------------
533
534    Following is an example of decoding-condition:
535
536      (defvar mime/content-decoding-condition
537        '(((type . "text/plain")
538           (method "tm-plain" nil 'file 'type 'encoding 'mode 'name))
539          ((type . "text/x-latex")
540           (method "tm-latex" nil 'file 'type 'encoding 'mode 'name))
541          ((type . "audio/basic")
542           (method "tm-au"    nil 'file 'type 'encoding 'mode 'name))
543          ((type . "image/gif")
544           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
545          ((type . "image/jpeg")
546           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
547          ((type . "image/tiff")
548           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
549          ((type . "image/x-tiff")
550           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
551          ((type . "image/x-xbm")
552           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
553          ((type . "image/x-pic")
554           (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
555          ((type . "video/mpeg")`
556           (method "tm-mpeg"  nil 'file 'type 'encoding 'mode 'name))
557          ((type . "application/octet-stream")
558           (method "tm-file"  nil 'file 'type 'encoding 'mode 'name))
559          ((type . "message/partial")
560           (method . mime/decode-message/partial-region))
561          ((method "metamail" t
562                   "-m" "tm" "-x" "-d" "-z" "-e" 'file)(mode . "play"))
563          ))
564
565    For example, if you want to use metamail to decode any contents,
566
567      (setq mime/content-decoding-condition
568            '(
569              ((method "metamail" t "-m" "tm" "-x" "-d" "-z" "-e" 'file))
570             ))
571
572 will work.
573
574    Variable `mime/content-decoding-condition' provides you of very
575 flexible way to define the conditions of decoding.  It can be simple if
576 you only need the a few decoding methods, while it can be very
577 complicated if you want to use the separate decoding method for each
578 type/mode combination.
579
580    Following function may be useful to set decoding-condition.  It is a
581 function of `tl-atype.el'.
582
583  - Function: set-atype SYMBOL ALIST
584      Add condition ALIST to SYMBOL.
585
586      *[Example]*
587                (set-atype 'mime/content-decoding-condition
588                    '((type . "message/external-body")
589                      ("access-type" . "anon-ftp")
590                      (method . mime/decode-message/external-ftp)
591                      ))
592
593 \1f
594 File: tm-view-en.info,  Node: environment variables,  Prev: decoding-condition,  Up: method
595
596 Environment variables
597 =====================
598
599    Standard methods of tm-view reference some environment variables.
600 You can specify them to customize.
601
602 TM_TMP_DIR
603      Directory for temporary files or extracted files.  If it is
604      omitted, `/tmp/' is used.
605
606 VIDEO_DITHER
607      Dither for mpeg_play.  If it is omitted, `gray' is used.
608
609 TM_WWW_BROWSER
610      WWW browser name.  If it is omitted, `netscape' is used.
611
612 \1f
613 File: tm-view-en.info,  Node: Two buffers for an article,  Next: API,  Prev: method,  Up: Top
614
615 raw-article-buffer and preview-buffer
616 *************************************
617
618    tm-view managements two buffers, one is for raw message called
619 *raw-article-buffer*, another one is to preview for user called
620 *preview-buffer*.  major-mode of raw-article-buffer is same as
621 major-mode for article of original MUA, major-mode of preview-buffer is
622 `mime/viewer-mode' (*Note mime/viewer-mode::).
623
624    When called `mime/viewer-mode', tm-view analyzes raw-article-buffer,
625 and sets its result to the variable `mime::article/content-info'.
626
627    After that, tm-view create a preview-buffer corresponded to the
628 raw-article-buffer.  As this time, tm-view modifies header and body of
629 each parts of the message by specified conditions.  Filter program for
630 header is called *header-filter* (*Note content-header::), filter
631 program for body is called *content-filter* (*Note content-body::), and
632 they are called *filter*.
633
634    When preview-buffer is made, buffer local variable of preview-buffer
635 `mime::preview/content-list' is made to register structure of
636 preview-buffer.  tm-view manages message by
637 `mime::article/content-info' in raw-article-buffer and
638 `mime::preview/content-list' in preview-buffer.
639
640 *[Notice]*
641      In this document, I call "content-type" as content-type/subtype of
642      Content-Type field.
643
644 * Menu:
645
646 * raw-article-buffer::          buffer local variables of raw-article-buffer
647 * preview-buffer::              Buffer local variables of preview-buffer
648
649 \1f
650 File: tm-view-en.info,  Node: raw-article-buffer,  Next: preview-buffer,  Prev: Two buffers for an article,  Up: Two buffers for an article
651
652 buffer local variables of raw-article-buffer
653 ============================================
654
655  - Structure: mime::content-info RCNUM POINT-MIN POINT-MAX TYPE
656           PARAMETERS ENCODING CHILDREN
657      structure to represent MIME content in raw-article-buffer.  It is
658      called by *content-info*.
659
660      Please use reference function `mime::content-info/SLOT-NAME' to
661      reference slot of content-info.  Their argument is only
662      content-info.
663
664      Following is a list of slots of the structure:
665
666     RCNUM
667           "reversed content-number" (list)
668
669     POINT-MIN
670           beginning point of region in raw-article-buffer
671
672     POINT-MAX
673           end point of region in raw-article-buffer
674
675     TYPE
676           content-type/sub-type (string or nil)
677
678     PARAMETERS
679           parameter of Content-Type field (association list)
680
681     ENCODING
682           Content-Transfer-Encoding (string or nil)
683
684     CHILDREN
685           parts included in this part (list of content-infos)
686
687      If a part includes other parts in its contents, such as multipart
688      or message/rfc822, content-infos of other parts are included in
689      CHILDREN, so content-info become a tree.
690
691  - Variable: mime::article/content-info
692      result of MIME parsing of raw-article-buffer (content-info)
693
694  - Variable: mime::article/preview-buffer
695      preview-buffer corresponded by this buffer
696
697  - Function: mime-article/point-content-number POINT &optional CINFO
698      In a region managed by content-info CINFO, it returns
699      content-number corresponded by POINT.
700
701      If CINFO is omitted, `mime::article/content-info' is used as
702      default value.
703
704  - Function: mime-article/rcnum-to-cinfo RCNUM &optional CINFO
705      In a region managed by content-info CINFO, it returns content-info
706      corresponded by reversed-content-number RCNUM.
707
708      If CINFO is omitted, `mime::article/content-info' is used as
709      default value.
710
711  - Function: mime-article/cnum-to-cinfo RCNUM &optional CINFO
712      In a region managed by content-info CINFO, it returns content-info
713      corresponded by content-number RCNUM.
714
715      If CINFO is omitted, `mime::article/content-info' is used as
716      default value.
717
718  - Function: mime/flatten-content-info &optional CINFO
719      It returns flatten list of content-info from content-info CINFO
720      tree.
721
722      If CINFO is omitted, `mime::article/content-info' is used as
723      default value.
724
725 \1f
726 File: tm-view-en.info,  Node: preview-buffer,  Prev: raw-article-buffer,  Up: Two buffers for an article
727
728 Buffer local variables of preview-buffer
729 ========================================
730
731  - Variable: mime::preview/mother-buffer
732      Mother buffer of this preview-buffer.
733
734  - Structure: mime::preview-content-info POINT-MIN POINT-MAX BUFFER
735           CONTENT-INFO
736      structure to represent MIME content in preview-buffer.  It is
737      called by *preview-content-info*.
738
739      Please use reference function
740      `mime::preview-content-info/SLOT-NAME' to reference slot of
741      preview-content-info.  Their argument is only preview-content-info.
742
743      Following is a list of slots of the structure:
744
745     POINT-MIN
746           beginning point of region in preview-buffer
747
748     POINT-MAX
749           end point of region in preview-buffer
750
751     BUFFER
752           raw-article-buffer corresponding a part
753
754     CONTENT-INFO
755           content-info corresponding a part
756
757
758  - Variable: mime::preview/content-list
759      List of preview-content-info to represent structure of this
760      preview-buffer.
761
762  - Variable: mime::preview/article-buffer
763      raw-article-buffer corresponded by this preview-buffer.
764
765  - Variable: mime::preview/original-major-mode
766      major-mode of original buffer.
767
768  - Variable: mime::preview/original-window-configuration
769      window-configuration just before made this preview-buffer.
770
771  - Function: mime-preview/point-pcinfo POINT &optional PCL
772      In a region of preview-buffer managed by preview-content-info PCL,
773      it returns preview-content-info corresponded by POINT.
774
775      If CINFO is omitted, `mime::preview/content-list' is used.
776
777 \1f
778 File: tm-view-en.info,  Node: API,  Next: Acknowledgments,  Prev: Two buffers for an article,  Up: Top
779
780 Functions to decode MIME message
781 ********************************
782
783    tm-view provides some available functions to decode and navigate MIME
784 message to each MUA (*Note (tm-en)MUA::)s.
785
786    There are 2 kinds of functions, one is for MIME preview, another one
787 is to decode RFC 1522 encoded-word (*Note (tm-en)encoded-word::).
788
789 * Menu:
790
791 * API about MIME preview::      Function to preview MIME message
792 * encoded-word decoding::       encoded-word decoder
793
794 \1f
795 File: tm-view-en.info,  Node: API about MIME preview,  Next: encoded-word decoding,  Prev: API,  Up: API
796
797 Function to preview MIME message
798 ================================
799
800  - Command: mime/viewer-mode &optional MOTHER CTL ENCODING IBUF OBUF
801           MOTHER-KEYMAP
802      Parse IBUF as a MIME message, and create preview-buffer into OBUF
803      to display to user, then enter `mime/viewer-mode' (*Note
804      mime/viewer-mode::).
805
806      If IBUF is omitted, current buffer is used.
807
808      MOTHER is used to specify original raw-article-buffer.  It may be
809      useful when a raw-article-buffer is assembled from message/partial
810      messages.
811
812      CTL is used to specify Content-Type field (*Note
813      (tm-en)Content-Type field::) information.  Its format is output
814      format of `mime/Content-Type'.  When CTL is specified, tm-view
815      uses it instead of Content-Type field of the raw-article-buffer.
816
817      ENCODING is used to specify field-body of
818      Content-Transfer-Encoding field.  When is is specified, tm-view
819      uses it instead of Content-Type field of the raw-article-buffer.
820
821      If MOTHER-KEYMAP is specified, keymap of `mime/viewer-mode'
822      includes it.
823
824 \1f
825 File: tm-view-en.info,  Node: encoded-word decoding,  Prev: API about MIME preview,  Up: API
826
827 encoded-word decoder
828 ====================
829
830    tm-view has functions to decode RFC 1522 encoded-word (*Note
831 (tm-en)encoded-word::).
832
833  - Command: mime/decode-message-header
834      It decodes encoded-words in message header of current buffer.
835
836      If an encoded-word is broken or invalid, or it has non supported
837      MIME charset (*Note (tm-en)MIME charset::), it is not decoded.
838
839  - Command: mime-eword/decode-region START END &optional UNFOLDING
840           MUST-UNFOLD
841      It decodes encoded-words in region START to END.
842
843      If an encoded-word is broken or invalid, or it has non supported
844      MIME charset (*Note (tm-en)MIME charset::), it is not decoded.
845
846      If UNFOLDING is non-nil, it unfolds folded fields.
847
848      If MUST-FOLD is non-nil and decoded result of an encoded-word has
849      folding or raw CR or LF, it unfolds or delete raw CR or LF.
850
851  - Function: mime-eword/decode-string STRING &optional MUST-UNFOLD
852      It decodes encoded-words in STRING and returns decoded string.
853
854      If an encoded-word is broken or invalid, or it has non supported
855      MIME charset (*Note (tm-en)MIME charset::), it is not decoded.
856
857      If STRING is folded, it unfolds STRING before decoding.
858
859      If MUST-FOLD is non-nil and decoded result of an encoded-word has
860      folding or raw CR or LF, it unfolds or delete raw CR or LF.
861
862 \1f
863 File: tm-view-en.info,  Node: Acknowledgments,  Next: Concept Index,  Prev: API,  Up: Top
864
865 Acknowledgments
866 ***************
867
868    First of all, I thank MASUTANI Yasuhiro.  He requested me a lot of
869 important features and gave me a lot of suggestions when tm-view was
870 born.  tm-view is based on his influence.
871
872    I thank ENAMI Tsugutomo for work of `mime.el', which is an origin of
873 `tm-ew-d.el' and `mel-b.el', and permission to rewrite for tm.
874
875    I thank OKABE Yasuo for work of internal method for LaTeX and
876 automatic assembling method for message/partial.  I thank UENO Hiroshi
877 for work of internal method for tar archive.
878
879    Last of all, I thank members of two tm mailing lists, Japanese and
880 English version.
881
882 \1f
883 File: tm-view-en.info,  Node: Concept Index,  Next: Function Index,  Prev: Acknowledgments,  Up: Top
884
885 Concept Index
886 *************
887
888 * Menu:
889
890 * content-body:                         content-body.
891 * content-filter <1>:                   content-body.
892 * content-filter:                       Two buffers for an article.
893 * content-header-filter:                content-header.
894 * content-info:                         raw-article-buffer.
895 * content-number:                       content-button.
896 * content-separator:                    content-separator.
897 * decoding operation(s) (for a part):   method.
898 * decoding-mode:                        method.
899 * external method:                      method.
900 * filter <1>:                           Introduction.
901 * filter:                               Two buffers for an article.
902 * header-filter:                        Two buffers for an article.
903 * internal method:                      method.
904 * method <1>:                           method.
905 * method:                               Introduction.
906 * preview-buffer:                       Two buffers for an article.
907 * preview-content-info:                 preview-buffer.
908 * raw-article-buffer:                   Two buffers for an article.
909
910 \1f
911 File: tm-view-en.info,  Node: Function Index,  Next: Variable Index,  Prev: Concept Index,  Up: Top
912
913 Function Index
914 **************
915
916 * Menu:
917
918 * mime-article/cnum-to-cinfo:           raw-article-buffer.
919 * mime-article/point-content-number:    raw-article-buffer.
920 * mime-article/rcnum-to-cinfo:          raw-article-buffer.
921 * mime-eword/decode-region:             encoded-word decoding.
922 * mime-eword/decode-string:             encoded-word decoding.
923 * mime-preview/point-pcinfo:            preview-buffer.
924 * mime-viewer/body-visible-p:           content-body.
925 * mime-viewer/default-content-filter:   content-body.
926 * mime-viewer/default-content-header-filter: content-header.
927 * mime-viewer/default-content-separator: content-separator.
928 * mime-viewer/header-visible-p:         content-header.
929 * mime/decode-message-header:           encoded-word decoding.
930 * mime/flatten-content-info:            raw-article-buffer.
931 * mime/viewer-mode:                     API about MIME preview.
932 * mime::content-info:                   raw-article-buffer.
933 * mime::preview-content-info:           preview-buffer.
934 * set-atype:                            Example of decoding-condition.
935
936 \1f
937 File: tm-view-en.info,  Node: Variable Index,  Prev: Function Index,  Up: Top
938
939 Variable Index
940 **************
941
942 * Menu:
943
944 * mime-viewer/childrens-header-showing-Content-Type-list: content-header.
945 * mime-viewer/content-button-ignored-ctype-list: content-button.
946 * mime-viewer/content-filter-alist:     content-body.
947 * mime-viewer/content-header-filter-alist: content-header.
948 * mime-viewer/default-showing-Content-Type-list: content-body.
949 * mime-viewer/ignored-field-list:       content-header.
950 * mime::article/content-info:           raw-article-buffer.
951 * mime::article/preview-buffer:         raw-article-buffer.
952 * mime::preview/article-buffer:         preview-buffer.
953 * mime::preview/content-list:           preview-buffer.
954 * mime::preview/mother-buffer:          preview-buffer.
955 * mime::preview/original-major-mode:    preview-buffer.
956 * mime::preview/original-window-configuration: preview-buffer.
957
958
959 \1f
960 Tag Table:
961 Node: Top\7f99
962 Node: Introduction\7f802
963 Node: MIME display\7f1646
964 Node: content-button\7f3934
965 Node: content-header\7f5646
966 Node: content-body\7f8280
967 Node: content-separator\7f10203
968 Node: mime/viewer-mode\7f11082
969 Node: method\7f12236
970 Node: decoding-condition\7f13342
971 Node: method value\7f15142
972 Node: Example of decoding-condition\7f16871
973 Node: environment variables\7f19443
974 Node: Two buffers for an article\7f19950
975 Node: raw-article-buffer\7f21501
976 Node: preview-buffer\7f24021
977 Node: API\7f25673
978 Node: API about MIME preview\7f26230
979 Node: encoded-word decoding\7f27400
980 Node: Acknowledgments\7f28825
981 Node: Concept Index\7f29539
982 Node: Function Index\7f30765
983 Node: Variable Index\7f31930
984 \1f
985 End Tag Table