tm 7.67.
[elisp/tm.git] / doc / tm-view_en.texi
index ea2dae6..203aa42 100644 (file)
@@ -1,16 +1,6 @@
-\input texinfo.tex
-@c{-*-tm manual-*-}
-@setfilename tm-view_en.info
-@settitle{tm-view manual}
+@c{$Id: tm-view_en.texi,v 7.3 1995/12/13 09:30:34 morioka Exp $}
 
-@titlepage
-@title tm-view Manual (English Version)
-@author by MORIOKA Tomohiko
-@code{$Id: tm-view_en.texi,v 6.1 1995/09/05 17:54:42 morioka Exp $}
-@end titlepage
-
-
-@node Top, Mechanism, (dir), (dir)
+@node tm-view, encoded-word, tm-MUA, Top
 @comment  node-name,  next,  previous,  up
 @chapter tm-view
 @cindex tm-view
@@ -20,39 +10,24 @@ The tm-view is a general MIME viewer running on GNU Emacs.
 tm-view provides the major-mode called @code{mime/viewer-mode} to read
 MIME message for MUA. MUA implementer can use it to add MIME function.
 
-
+tm-view is a user interface kernel to view and navigate MIME message.
+tm-view drives some programs to navigate each content-type/sub-types,
+they are called @strong{method}. tm-view calls some programs to
+display each content-type/sub-types in preview buffer, they are called 
+@strong{filter}. @strong{method} and @strong{filter} are tm-view
+application program. They expand tm-view to treat various kinds of
+MIME types.
 
 @menu
-* Mechanism::      Mechanism of mime/viewer-mode.
-* How to run::     How to run mime/viewer-mode.
-* Commands::       Commands of mime/viewer-mode.
-* Preview Buffer:: Screen design of preview buffer.
-* Decoding::       Mechanism of decoding operations for contents.
-
-Preview buffer
-* Preview Buffer:: Screen design of preview buffer.
-* content-subject::
-* content-header::
-* content-body::
-* content-separator::
-
-Decoding
-* Decoding:: Mechanism of decoding operations for contents.
-* decoding-condition:: Setting of content decoding condition.
-* Format of method value:: Format of method value part.
-* Example of decoding-condition:: Examples of decoding-condition.
-
-Indexes
-* Concept Index::
-* Command Index::
-* Variable Index::
+* Mechanism of tm-view::
+* mime/viewer-mode::
 @end menu
 
 
-@node Mechanism, How to run, Top, Top
+@node Mechanism of tm-view, Functions of tm-view, tm-view, tm-view
 @comment  node-name,  next,  previous,  up
-@chapter Mechanism
-@cindex Mechanism
+@chapter Mechanism of tm-view
+@cindex mechanism of tm-view
 
 tm-view managements two buffers, one is for raw message called
 @strong{article buffer}, another one is to preview for user called
@@ -73,10 +48,38 @@ Notice: In this document, I call @strong{content-type} as
 content-type/subtype of Content-Type field.
 
 
-@node How to run, Commands, Mechanism, Top
+@menu
+* Functions of tm-view::
+* article-buffer::
+* preview-buffer::
+* method::
+@end menu
+
+
+@node Functions of tm-view, function to preview, Mechanism of tm-view, Mechanism of tm-view
+@comment  node-name,  next,  previous,  up
+@subsection Functions of tm-view
+
+tm-view provides some available functions to decode and navigate MIME
+message to each MUAs.
+
+There are 2 kinds of functions, one is for MIME preview, another one
+is to decode RFC 1522 encoded-word.
+
+Memo: Old tiny-mime.el was abolished. Functions to decode RFC 1522
+encoded-word are took over to tm-view.
+
+
+@menu
+* function to preview::
+* encoded-word decoding::
+@end menu
+
+
+@node function to preview, encoded-word decoding, Functions of tm-view, Functions of tm-view
 @comment  node-name,  next,  previous,  up
-@chapter How to run mime/viewer-mode
-@cindex How to run mime/viewer-mode
+@subsubsection function to preview MIME message
+@cindex mime/viewer-mode
 
 @deffn{Command} mime/viewer-mode &optional mother ctl encoding
 
@@ -97,51 +100,31 @@ instead of Content-Type field of the article buffer.
 @end deffn
 
 
-@node Commands, Preview Buffer, How to run, Top
-@comment  node-name,  next,  previous,  up
-@chapter Commands of mime/viewer-mode
-@cindex Commands of mime/viewer-mode
+@include{tm-ew-d_en.texi}
 
-@code{mime/viewer-mode} has following functions:
 
-@table @kbd 
-@item u
-        goes to the upper content (returns to the Summary mode if the
-        cursor is sitting on the top content (*1))
-@item p
-        goes to the previous content
-@item n
-        goes to the next content
-@item @key{SPC}
-        scrolls up
-@item @key{M-SPC}
-        scrolls down
-@item @key{DEL}
-        scrolls down
-@item @key{RET}
-        goes to the next line
-@item @key{M-RET}
-        goes to the previous line
-@item v
-        playbacks a content            (*2)
-@item e
-        extracts a file from a content (*2)
-@item C-c C-p
-        prints a content               (*2)
-@end table
+@include{tm-view-a_en.texi}
 
-@b{[Notice]}
-@enumerate
-@item
-Not return to the Summary mode unless tm-view has been setup using
-tm-mh-e, tm-gnus, tm-rmail etc.
+@include{tm-view-p_en.texi}
+
+@include{tm-view-m_en.texi}
 
-@item
-Actual playback/extract/print will be performed by a method.
-@end enumerate
 
 
-@node Preview Buffer, Decoding, Commands, Top
+@node mime/viewer-mode, environment variables, Functions of tm-view, tm-view
+@comment  node-name,  next,  previous,  up
+@section mime/viewer-mode
+@cindex mime/viewer-mode
+
+@code{mime/viewer-mode} is a major-mode to preview MIME message. In
+MIME viewer mode, you can navigate MIME message interactively.
+
+@menu
+* MIME display::
+* MIME navigation::
+@end menu
+
+@node MIME display, content-body, mime/viewer-mode, mime/viewer-mode
 @comment  node-name,  next,  previous,  up
 @chapter Screen design of preview buffer
 @cindex Screen design of preview buffer
@@ -197,187 +180,9 @@ MORIOKA, Tomohiko <morioka@@jaist.ac.jp>
 * content-separator::
 @end menu
 
-
-@node content-subject, content-header, Preview Buffer, Preview Buffer
-@comment  node-name,  next,  previous,  up
-@section content-subject
-@cindex content-subject
-
-content-subject is a part to display abstract for the content. It is
-placed in top of content.
-
-In default, it is displayed following design:
-
-@example
-        [1.3 test (text/plain)]
-@end example
-
-First number field represents position of a content in the message. It
-is called `content-number'. It can be considered as the chapter number
-in the message.
-
-Second string part represents title. It is created by following:
-
-@itemize @bullet
-@item name paramater or x-name parameter in Content-Type field
-@item Content-Description field or Subject field
-@item filename of uuencode
-@end itemize
-
-If they are not exists, space is displayed.
-
-Third parenthesis part represents content-type/subtype of the
-content. If it is non-MIME part, @code{nil} is displayed.
-
-Content-subject is used like icon when content-header and content-body
-are hidden. For example,
-
-@example
-        [2  (image/gif)]
-@end example
-
-if you press `v' key, GIF image is displayed.
-
-
-@defvr{Variable} mime-viewer/content-subject-omitting-Content-Type-list
-
-List of content-type. If content-type of a content is a member of this 
-list, its content-subject is not displayed.
-
-This variable is referenced by function
-@code{mime-viewer/default-content-subject-function}.
-@end defvr
-
-
-@deffn{Function} mime-viewer/default-content-subject-function cnum cinfo ctype params subj
-
-Default value of the variable
-@code{mime-viewer/content-subject-function}.
-It refers variable
-@code{mime-viewer/content-subject-omitting-Content-Type-list}.
-@end deffn
-
-
-@defvar mime-viewer/content-subject-function cnum cinfo ctype params subj
-
-Variable to specify content-subject display function. Default value is
-the function @code{mime-viewer/default-content-subject-function}.
-@end defvar
-
-
-@node content-header, content-body, content-subject, Preview Buffer
-@comment  node-name,  next,  previous,  up
-@section content-header
-@cindex content-header
-
-A content header shows the header portion of a content in the preview
-buffer.
-
-When the function @code{mime-viewer/header-visible-p} returns @code{t}
-for content-number of a content, content-header is displayed. This
-judge function returns @code{t} when a content is root or content-type
-of its parent is a member of the variable
-@code{mime-viewer/childrens-header-showing-Content-Type-list}.
-
-If you want to change this condition, please redefine it.
-
-When content-header is displayed, content-header are formated by
-content-header-filter. Content-header-filter is searched from variable 
-@code{mime-viewer/content-header-filter-alist}. Its key is major-mode
-of the article buffer. If not found, function
-@code{mime-viewer/default-content-header-filter} is called.
-
-
-@defvar mime-viewer/childrens-header-showing-Content-Type-list
-
-List of content-type. If content-type of parent of a content is a
-member of this variable, its content-header is displayed.
-Default value is "message/rfc822".
-
-This variable is referred by the function
-@code{mime-viewer/header-visible-p}.
-@end defvar
-
-
-@deffn{Function} mime-viewer/header-visible-p cnum cinfo &optional ctype
-
-Returns @code{t} if a content is displayed.
-
-@var{cnum} is content-number. @var{cinfo} is content-info. If you know 
-content-type, you can specify by @var{ctype}.
-@end deffn
-
-
-@defvar mime-viewer/content-header-filter-alist
-
-Association-list whose key is major-mode of a article buffer, value is
-content-header-filter.
-@end defvar
-
-
-@deffn{Function} mime-viewer/default-content-header-filter
-
-It is called when content-header-filter is not found in variable
-@code{mime-viewer/content-header-filter-alist}.
-@end deffn
-
-
-@node content-body, content-separator, content-header, Preview Buffer
-@comment  node-name,  next,  previous,  up
-@section content-body
-@cindex content-body
-
-Content-body represents content of the message. tm-view does not
-display raw content body. For example, if a content has binary, it is
-hidden. If a content has richtext, it is formated. Namely content body
-is hidden or formated.
-
-Function @code{mime-viewer/body-visible-p} is a judge function whether
-content-body of a content is displayed. If it returns @code{nil},
-content-body is hidden. In default, it returns non-@code{nil} when
-content-type of a content is a member of variable
-@code{mime-viewer/default-showing-Content-Type-list}.
-
-When content-body of a content is displayed, content-body is formated
-by content-filter. Content-filter is searched from variable
-@code{mime-viewer/content-filter-alist}. At this time, major-mode of
-the article buffer is used as the key.
-
-If it is not found, function @code{mime-viewer/default-content-filter}
-is called.
-
-
-@defvar mime-viewer/default-showing-Content-Type-list
-
-List of content-type. If content-type of a content is a member of this 
-variable, its body is displayed.
-@end defvar
-
-
-@deffn{Function} mime-viewer/body-visible-p cnum cinfo &optional ctype
-
-Return non-@code{nil}, if content-type of a content is displayed.
-@var{cnum} is content-number of a content. @var{cinfo} is content-info
-of the message. If you know content-type of a content, you can specify
-it as argument @var{ctype}.
-@end deffn
-
-
-@defvar mime-viewer/content-filter-alist
-
-Association-list whose key is major-mode of a article buffer, value is
-content-filter.
-@end defvar
-
-
-@deffn{Function} mime-viewer/default-content-filter cnum cinfo ctype params subj
-
-It is called when content-body of a content should be displayed and
-content-filter is not found in
-@code{mime-viewer/content-filter-alist}.
-
-In default, it does nothing.
-@end deffn
+@include{tm-view-cs_en.texi}
+@include{tm-view-ch_en.texi}
+@include{tm-view-cb_en.texi}
 
 
 @node content-separator, , content-body, Preview Buffer
@@ -406,262 +211,72 @@ content-body are not displayed.
 @end deffn
 
 
-@node Decoding, Concept Index, Preview Buffer, Top
-@comment  node-name,  next,  previous,  up
-@chapter Decoding
-@cindex Decoding
-
-In @code{mime/viewer-mode}, you can do play (@key{v}), extract
-(@key{e}), or print (@key{C-c C-p}) for each content. These operations
-are called ``decoding operation(s) (for a content)''. And kind of
-decoding operations are called @strong{decoding-mode}.
-
-When decoding operation is driven, tm-view calls a procedure matched
-for the condition, such as content-type. This procedure is called
-@strong{method}.
-
-There are two kinds of method. One is Emacs Lisp function, called
-@strong{internal method}. Another one is external program, called
-@strong{external method}.
-
-Internal method operates in Emacs, so it can do carefully.
-
-External method is called as asynchronous process, so Emacs does not
-wait while method is running. So it is good for big data, such as
-audio, image or video.
-
-@menu
-* decoding-condition:: Setting of content decoding condition.
-* Format of method value:: Format of method value part.
-* Example of decoding-condition:: Examples of decoding-condition.
-@end menu
-
-
-@node decoding-condition, Format of method value, Decoding, Decoding
+@node MIME navigation, method, content-body, mime/viewer-mode
 @comment  node-name,  next,  previous,  up
-@section Setting of content decoding condition
-@cindex Setting of content decoding condition
-
-When decoding operation is driven, tm-view calls a method matched for
-the condition searched from the variable
-@code{mime/content-decoding-condition}.
-
-Variable @code{mime/content-decoding-condition} is defined as a list
-with the following syntax:
-
-@lisp
-        (condition1 condition2 ...)
-@end lisp
-
-Each condition are association-list with the following syntax:
-
-@lisp
-        ((field-type_1 . value_1)
-         (field-type_2 . value_2)
-         ...)
-@end lisp
-
-For example, if you want to call the external method named tm-plain to
-decode every text/plain type content, you can define the condition
-like
-
-@lisp
-        ((type . "text/plain")
-         (method "tm-plain" nil 'file 'type 'encoding 'mode 'name))
-@end lisp
-
-As you notice, now you can define the arguments to pass to a external
-method.  Refer to @xref{Format of method value} section for more
-explanation.
-
-This condition definition will match all contents whose types are
-text/plain. Here is an another example:
-
-@lisp
-        ((type . "text/plain")
-         (method "tm-plain" nil 'file 'type 'encoding 'mode 'name)
-         (mode . "play"))
-@end lisp
+@chapter Commands of mime/viewer-mode
+@cindex Commands of mime/viewer-mode
 
-This will match the content whose type is text/plain and the mode is
-play.
+@code{mime/viewer-mode} has following functions:
 
-@lisp
-        ((method "metamail" t "-m" "tm" "-x" "-d" "-z" "-e" 'file)
-         (mode . "play"))
-@end lisp
+@table @kbd 
+@item @key{u}
+goes to the upper content (returns to the Summary mode if the cursor
+is sitting on the top content (*1))
 
-This will match all contents which have a mode of play.
+@item @key{p}
+goes to the previous content
 
-The conditions defined in a mime/content-decoding-condition variable
-are examined from top to bottom.  The first matching condition becomes
-valid and the method specified in that condition definition will be
-executed.
+@item @key{n}
+goes to the next content
 
+@item @key{SPC}
+scrolls up
 
-@node Format of method value, Example of decoding-condition, decoding-condition, Decoding
-@comment  node-name,  next,  previous,  up
-@section Format of method value part
-@cindex Format of method value part
+@item @key{M-SPC}
+scrolls down
 
-You can specify the method field of the decoding-condition definition
-in two different ways,
+@item @key{DEL}
+scrolls down
 
-@lisp
-        (method . SYMBOL)
-@end lisp
+@item @key{RET}
+goes to the next line
 
-or
+@item @key{M-RET}
+goes to the previous line
 
-@lisp
-        (method  STRING  FLAG  ARGUMENT1  ARGUMENT2  ...)
-@end lisp
+@item @key{<}
+goes to the beginning of message
 
-can be accepted.
+@item @key{>}
+goes to the end of message
 
-When a symbol is specified in the method field, a function whose name
-is SYMBOL will be called as an internal method.
+@item @key{v}
+playbacks a content            (*2)
 
-When a list is specified in the method field, it will be called as an
-external method.
+@item @key{e}
+extracts a file from a content (*2)
 
-The list below shows the meaning of the parameters when the external
-method is specified in the method field.
+@item @key{C-c C-p}
+prints a content               (*2)
 
-@table @samp
-@item STRING
-        name of an external method
-@item FLAG
-        If @code{t}, both the content header and the content body are
-        passed to an external method. if nil, only the content body is
-        passed to an external method.
-@item ARGUMENTs
-        list of arguments passed to an external method
-@end table
+@item @key{f}
+displays X-Face in the message
 
-An argument passed to an external method can be in one of the
-following formats:
+@item @key{mouse-button-2}
+drives mouse button.
 
-@table @samp
-@item STRING
-        string itself
-@item 'SYMBOL
-        value gotten using SYMBOL as a key (see below)
-@item 'STRING
-        value gotten using STRING as a key (see below)
-@end table
+If you press content-subject, it playbacks the content. (*2)
 
-'SYMBOL can be one of the following:
-
-@table @samp
-@item 'file
-        name of a file holding the original content
-@item 'type
-        content-type/sub-type of Content-Type field
-@item 'encoding
-        field body of Content-Transfer-Encoding field
-@item 'mode
-        decoding-mode
-@item 'name
-        name of a file created by decode operation
+If you press URL-button, it runs WWW browser.
 @end table
 
-'STRING is used to search a parameter of the Content-Type field whose
-name matches with it, and pass the value of that parameter to the
-external method.
-
 
-@node Example of decoding-condition, , Format of method value, Decoding
-@comment  node-name,  next,  previous,  up
-@section Examples of decoding-condition
-@cindex Examples of decoding-condition
-
-The default definition of a mime/content-decoding-condition variable
-is shown below.
-
-@lisp
-(defvar mime/content-decoding-condition
-  '(((type . "text/plain")
-     (method "tm-plain" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "text/x-latex")
-     (method "tm-latex" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "audio/basic")
-     (method "tm-au"    nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/gif")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/jpeg")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/tiff")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/x-tiff")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/x-xbm")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "image/x-pic")
-     (method "tm-image" nil 'file 'type 'encoding 'mode 'name))
-    ((type . "video/mpeg")`
-     (method "tm-mpeg"  nil 'file 'type 'encoding 'mode 'name))
-    ((type . "application/octet-stream")
-     (method "tm-file"  nil 'file 'type 'encoding 'mode 'name))
-    ((type . "message/partial")
-     (method . mime/decode-message/partial-region))
-    ((method "metamail" t
-             "-m" "tm" "-x" "-d" "-z" "-e" 'file)(mode . "play"))
-    ))
-@end lisp
-
-For example, if you want to use metamail to decode any contents,
-
-@lisp
-(setq mime/content-decoding-condition
-      '(
-        ((method "metamail" t "-m" "tm" "-x" "-d" "-z" "-e" 'file))
-       ))
-@end lisp
-
-will work.
-
-A mime/content-decoding-condition variable provides you of very flexible
-way to define the conditions of decoding.  It can be simple if you only
-need the a few decoding methods, while it can be very complicated if you
-want to use the separate decoding method for each type/mode combination.
-
-
-Following function may be useful to set decoding-condition. It is a
-function of tl-atype.el.
-
-
-@deffn{Function} set-atype symbol alist
-
-Add condition @var{alist} to symbol @var{symbol}.
-
-Example:
-
-@lisp
-(set-atype 'mime/content-decoding-condition
-          '((type . "message/external-body")
-            ("access-type" . "anon-ftp")
-            (method . mime/decode-message/external-ftp)
-            ))
-@end lisp
-@end deffn
-
-
-@node Concept Index, Command Index, Decoding, Top
-@unnumbered Concept Index
-
-@printindex cp
-
-
-@node Command Index, Variable Index, Concept Index, Top
-@unnumbered Command and Function Index
-
-@printindex fn
-
-
-@node Variable Index,  , Command Index, Top
-@unnumbered Variable Index
-
-@printindex vr
+@b{[Notice]}
+@enumerate
+@item
+Not return to the Summary mode unless tm-view has been setup using
+tm-mh-e, tm-gnus, tm-rmail etc.
 
-@bye
+@item
+Actual playback/extract/print will be performed by a method.
+@end enumerate