(What's FLIM): Add description about mime-lib.el and mime-parse.el.
[elisp/flim.git] / README.en
1 [README for FLIM (English Version)]
2
3 What's FLIM
4 ===========
5
6   FLIM is a library to provide basic features about message
7   representation or encoding.  It consists of following
8   modules:
9
10     std11.el    --- STD 11 (RFC 822) parser and utility
11
12     mime-def.el --- Definitions about MIME format
13
14     MEL: MIME encoder/decoder
15         mel.el    --- main module
16         mel-dl.el --- base64 (b-encoding) encoder/decoder
17                       (for Emacs 20 with dynamic loading support)
18         mel-b.el  --- base64 (b-encoding) encoder/decoder
19                       (for other emacsen)
20         mel-q.el  --- quoted-printable and q-encoding encoder/decoder
21         mel-u.el  --- unofficial module for uuencode
22         mel-g.el  --- unofficial module for gzip64
23
24     eword: encoded-word encoder/decoder
25         eword-decode.el --- encoded-word decoder
26         eword-encode.el --- encoded-word encoder
27
28     mime-lib.el --- MIME entity library
29
30     mime-parse.el --- MIME parser
31
32     mailcap.el  --- mailcap parser and utility
33
34
35 Installation
36 ============
37
38 (0) before installing it, please install APEL package.  APEL package
39     is available at:
40
41         ftp://ftp.jaist.ac.jp/pub/GNU/elisp/apel/
42
43 (1-a) run in expanded place
44
45   If you don't want to install other directories, please do only
46   following:
47
48         % make
49
50   You can specify the emacs command name, for example
51
52         % make install EMACS=xemacs
53
54   If `EMACS=...' is omitted, EMACS=emacs is used.
55
56 (1-b) make install
57
58   If you want to install other directories, please do following:
59
60         % make install
61
62   You can specify the emacs command name, for example
63
64         % make install EMACS=xemacs
65
66   If `EMACS=...' is omitted, EMACS=emacs is used.
67
68   You can specify the prefix of the directory tree for Emacs Lisp
69   programs and shell scripts, for example:
70
71         % make install PREFIX=~/
72
73   If `PREFIX=...' is omitted, the prefix of the directory tree of the
74   specified emacs command is used (perhaps /usr/local).
75
76   For example, if PREFIX=/usr/local and EMACS 19.34 is specified, it
77   will create the following directory tree:
78
79         /usr/local/share/emacs/site-lisp/flim/   --- FLIM
80
81   You can specify site-lisp directory, for example
82
83         % make install LISPDIR=~/share/emacs/lisp
84
85   If `LISPDIR=...' is omitted, site-lisp directory of the specified
86   emacs command is used (perhaps /usr/local/share/emacs/site-lisp or
87   /usr/local/lib/xemacs/site-lisp).
88
89   You can specify other optional settings by editing the file
90   FLIM-CFG.  Please read comments in it.
91
92
93 load-path (for Emacs or MULE)
94 =============================
95
96   If you are using Emacs or Mule, please add directory of FLIM to
97   load-path.  If you install by default setting, you can write
98   subdirs.el for example:
99
100   --------------------------------------------------------------------
101   (normal-top-level-add-to-load-path '("apel" "flim"))
102   --------------------------------------------------------------------
103
104   If you are using XEmacs, there are no need of setting about
105   load-path.
106
107
108 How to use
109 ==========
110
111 Region
112 ------
113
114 Command mime-encode-region (START END ENCODING)
115
116   Encode region START to END of current buffer using ENCODING.
117
118 Command mime-decode-region (start end encoding)
119
120   Decode region START to END of current buffer using ENCODING.
121
122 Command base64-encode-region (start end)
123
124   Encode current region by base64.
125   START and END are buffer positions.
126
127   This function calls internal base64 encoder if size of region is
128   smaller than `base64-internal-encoding-limit', otherwise it calls
129   external base64 encoder specified by `base64-external-encoder'.  In
130   this case, you must install the program (maybe mmencode included in
131   metamail or XEmacs package).
132
133 Command base64-decode-region (start end)
134
135   Decode current region by base64.
136   START and END are buffer positions.
137
138   This function calls internal base64 decoder if size of region is
139   smaller than `base64-internal-decoding-limit', otherwise it calls
140   external base64 decoder specified by `base64-external-decoder'.  In
141   this case, you must install the program (maybe mmencode included in
142   metamail or XEmacs package).
143
144 Command quoted-printable-encode-region (start end)
145
146   Encode current region by quoted-printable.
147   START and END are buffer positions.
148
149   This function calls internal quoted-printable encoder if size of
150   region is smaller than `quoted-printable-internal-encoding-limit',
151   otherwise it calls external quoted-printable encoder specified by
152   `quoted-printable-external-encoder'.  In this case, you must install
153   the program (maybe mmencode included in metamail or XEmacs package).
154
155 Command quoted-printable-decode-region (start end)
156
157   Decode current region by quoted-printable.
158   START and END are buffer positions.
159
160   This function calls internal quoted-printable decoder if size of
161   region is smaller than `quoted-printable-internal-decoding-limit',
162   otherwise it calls external quoted-printable decoder specified by
163   `quoted-printable-external-decoder'.  In this case, you must install
164   the program (maybe mmencode included in metamail or XEmacs package).
165
166 Command uuencode-encode-region (start end)
167
168   Encode region START to END of current buffer using uuencode.
169
170 Command uuencode-decode-region (start end)
171
172   Decode region START to END of current buffer using uuencode.
173
174 Command gzip64-encode-region (start end)
175
176   Encode region START to END of current buffer using x-gzip64.
177
178 Command gzip64-decode-region (start end)
179
180   Decode region START to END of current buffer using x-gzip64.
181
182 Variable mime-encoding-method-alist
183
184   Alist of encoding vs. corresponding method to encode region.
185   Each element looks like (STRING . FUNCTION) or (STRING . nil).
186   STRING is content-transfer-encoding.
187   FUNCTION is region encoder and nil means not to encode.
188
189 Variable mime-decoding-method-alist
190
191   Alist of encoding vs. corresponding method to decode region.
192   Each element looks like (STRING . FUNCTION).
193   STRING is content-transfer-encoding.
194   FUNCTION is region decoder.
195
196 File
197 ----
198
199 Command mime-insert-encoded-file (FILENAME ENCODING)
200
201   Insert file FILENAME encoded by ENCODING format.
202
203 Command base64-insert-encoded-file (FILENAME)
204
205   Encode contents of file FILENAME to base64, and insert the result.
206
207   It calls external base64 encoder specified by
208   `base64-external-encoder'.  So you must install the program (maybe
209   mmencode included in metamail or XEmacs package).
210
211 Command quoted-printable-insert-encoded-file (FILENAME)
212
213   Insert quoted-printable encoded file.
214
215 Command uuencode-insert-encoded-file (FILENAME)
216
217   Insert uuencode encoded file.
218
219 Command gzip64-insert-encoded-file (FILENAME)
220
221   Insert gzip64 encoded file.
222
223 Variable mime-file-encoding-method-alist
224
225   Alist of encoding vs. corresponding method to insert encoded file.
226   Each element looks like (STRING . FUNCTION).
227   STRING is content-transfer-encoding.
228   FUNCTION is function to insert encoded file.
229
230 String
231 ------
232
233 Function base64-encode-string (STRING)
234
235   Encode STRING to base64, and return the result.
236
237 Function base64-decode-string (STRING)
238
239   Decode STRING which is encoded in base64, and return the result.
240
241 Function q-encoding-encode-string (STRING &optional MODE)
242
243   Encode STRING to Q-encoding of encoded-word, and return the result.
244   MODE allows `text', `comment', `phrase' or nil.  Default value is
245   `phrase'.
246
247 Function q-encoding-decode-string (STRING)
248
249   Decode STRING which is encoded in Q-encoding and return the result.
250
251 Function base64-encoded-length (STRING)
252
253   Return length of base64 encoded STRING.
254
255 Function q-encoded-length (STRING &optional MODE)
256
257   Return length of Q-encoding encoded STRING.
258   MODE allows `text', `comment', `phrase' or nil.  Default value is
259   `phrase'.
260
261
262 Bug reports
263 ===========
264
265   If you write bug-reports and/or suggestions for improvement, please
266   send them to the tm Mailing List:
267
268         bug-tm-en@chamonix.jaist.ac.jp  (English)
269         bug-tm-ja@chamonix.jaist.ac.jp  (Japanese)
270
271   Via the tm ML, you can report FLIM bugs, obtain the latest release
272   of FLIM, and discuss future enhancements to FLIM. To join the tm ML,
273   send an empty e-mail to
274
275         tm-en-help@chamonix.jaist.ac.jp (English)
276         tm-ja-help@chamonix.jaist.ac.jp (Japanese)