74
|
1 <!doctype sinfo system>
|
|
2 <!-- $Id: gnus-mime-en.sgml,v 1.1.1.1 1996/12/21 20:51:39 steve Exp $ -->
|
|
3 <head>
|
|
4 <title>gnus-mime 0.10 reference manual (English Version)
|
|
5 <author>MORIOKA Tomohiko <mail>morioka@jaist.ac.jp</mail>
|
|
6 <date>1996/10/21
|
|
7
|
|
8 <toc>
|
|
9 </head>
|
|
10
|
|
11 <body>
|
|
12
|
|
13 <abstract>
|
|
14 <p>
|
|
15 This file documents gnus-mime, a MIME extension for Gnus.
|
|
16 </abstract>
|
|
17
|
|
18
|
|
19 <h1> What is gnus-mime?
|
|
20 <node> Introduction
|
|
21 <p>
|
|
22 <concept>gnus-mime</concept> is a <dref file="tm-en">MIME</dref>
|
|
23 extender for <a file="gnus">Gnus</a> using <a file="tm-en"
|
|
24 node="tm-kernel">tm</a>.
|
|
25
|
|
26 <memo title="Notice">
|
|
27 <p>
|
|
28 gnus-mime is for only Gnus. Please use <a
|
|
29 file="tm-gnus_en">tm-gnus</a> for GNUS.
|
|
30 </memo>
|
|
31
|
|
32 <p>
|
|
33 gnus-mime supports automatic MIME preview in <code>"*Article*"</code>
|
|
34 buffer using <a file="tm-view-en">tm-view</a>. In particular, with
|
|
35 XEmacs, it decodes images as same as text.
|
|
36 <p>
|
|
37 In addition, gnus-mime supports multilingual/internationalization
|
|
38 feature for mule such as <a file="tm-en" node="mule">MULE</a>,
|
|
39 XEmacs/mule and mule merged Emacs. It supports code-conversion by
|
|
40 MIME charset or depended default MIME charset of newsgroups.
|
|
41 <p>
|
|
42 For RFC 1522, original Gnus supports only Q-encoded <dref
|
|
43 file="tm-en">iso-8859-1</dref> <dref file="tm-en">encoded-word</dref>.
|
|
44 So gnus-mime supports more MIME charsets, such as <dref
|
|
45 file="tm-en">iso-8859-2</dref>, <dref file="tm-en">iso-8859-3</dref>,
|
|
46 ..., <dref file="tm-en">iso-2022-jp</dref>, <dref
|
|
47 file="tm-en">euc-kr</dref>, <dref file="tm-en">iso-2022-kr</dref>,
|
|
48 gb2312, <dref file="tm-en">hz-gb-2312</dref>, <dref
|
|
49 file="tm-en">cn-big5</dref>, and B-encoding. In addition, original
|
|
50 Gnus does not support unfolding or space elimination rule of RFC
|
|
51 1522. gnus-mime is more rightful.
|
|
52
|
|
53
|
|
54 <h1> Inline display for MIME message
|
|
55 <node> Automatic MIME Preview
|
|
56 <p>
|
|
57 <concept>automatic MIME preview</concept> feature is available for
|
|
58 gnus-mime. In automatic MIME preview mode, when reading an article in
|
|
59 summary mode, gnus-mime displays preview buffer processed by tm-view
|
|
60 instead of raw article buffer. <cf file="tm-view-en">
|
|
61 <p>
|
|
62 Therefore if an article is encoded by <dref file="tm-en">Base64</dref>
|
|
63 or <dref file="tm-en">Quoted-Printable</dref>, a decoded article is
|
|
64 displayed. Or rich text article, such as <dref
|
|
65 file="tm-en">text/enriched</dref> format, is automatic formated. Of
|
|
66 course, <dref file="tm-en">multipart</dref> article is dealt with
|
|
67 correctly.
|
|
68 <p>
|
|
69 In addition, in <concept>XEmacs</concept>, images are displayed in
|
|
70 preview buffer as same as text.
|
|
71 <p>
|
|
72 Different from using metamail, speaker does not roar just then read an
|
|
73 article includes audio content, video player does not play just then
|
|
74 read an article includes video content, it does not do anonymous <dref
|
|
75 file="tm-en">ftp</dref> or send mail when read an article includes
|
|
76 external-message. These contents are played when you do decoding
|
|
77 command in preview buffer.
|
|
78 <p>
|
|
79 However if you use a slow machine, or are just really impatient, you
|
|
80 can stop automatic MIME preview.
|
|
81
|
|
82
|
|
83 <h2> How to process MIME in Article Buffer
|
|
84 <node> MIME processing
|
|
85 <p>
|
|
86 When <code>gnus-show-mime</code> is not <code>nil</code> and an
|
|
87 article has Mime-Version field in its message header, namely it is a
|
|
88 MIME message, Gnus calls <code>gnus-show-mime-method</code> to process
|
|
89 MIME.
|
|
90 <p>
|
|
91 When <code>gnus-strict-mime</code> is <code>nil</code> and
|
|
92 <code>gnus-show-mime</code> is not <code>nil</code>, Gnus calls
|
|
93 <code>gnus-show-mime-method</code> even if an message does not have
|
|
94 Mime-Version field in its message header.
|
|
95 <p>
|
|
96 Gnus 5.2 or later calls <code>gnus-show-mime-method</code> when
|
|
97 <code>gnus-strict-mime</code> is not <code>nil</code> and an article
|
|
98 does not have Mime-Version field. Notice that old Gnus does not have
|
|
99 it, so it may be better to set <code>gnus-strict-mime</code> to
|
|
100 <code>nil</code>.
|
|
101
|
|
102
|
|
103 <defvar name="gnus-show-mime">
|
|
104 <p>
|
|
105 If it is not <code>nil</code>, Gnus do automatic MIME preview.
|
|
106 Default value is <code>t</code>.
|
|
107 <p>
|
|
108 It is a variable of Gnus, so if gnus is loaded before gnus-mime is
|
|
109 loaded, default value is not guaranteed.
|
|
110
|
|
111 <cf file="gnus" node="Using MIME">
|
|
112 </defvar>
|
|
113
|
|
114 <defvar name="gnus-show-mime-method">
|
|
115 <p>
|
|
116 Gnus calls function bound by it to process MIME. Default value is
|
|
117 <code>gnus-article-preview-mime-message</code>.
|
|
118 <p>
|
|
119 It is a variable of Gnus, so if gnus is loaded before gnus-mime is
|
|
120 loaded, default value is not guaranteed.
|
|
121
|
|
122 <cf file="gnus" node="Using MIME">
|
|
123 </defvar>
|
|
124
|
|
125 <defvar name="gnus-decode-encoded-word-method">
|
|
126 <p>
|
|
127 Gnus calls function bound by it to decode encoded-words. Default
|
|
128 value is <code>gnus-article-decode-encoded-word</code>.
|
|
129 <p>
|
|
130 It is a variable of Gnus, so if gnus is loaded before gnus-mime is
|
|
131 loaded, default value is not guaranteed.
|
|
132 <p>
|
|
133 In addition, it is not available at Gnus 5.0.* or Gnus 5.1.
|
|
134 </defvar>
|
|
135
|
|
136 <memo title="Notice">
|
|
137 <p>
|
|
138 gnus-mime uses some variables of Gnus and defines different default
|
|
139 values by <code>defvar</code>. For example, gnus-mime's default value
|
|
140 of <code>gnus-show-mime</code> is <code>t</code> instead of
|
|
141 <code>nil</code>. Or its default value of
|
|
142 <code>gnus-show-mime-method</code> is
|
|
143 <code>gnus-article-preview-mime-message</code> instead of
|
|
144 <code>metamail-buffer</code>.
|
|
145 <cf file="gnus" node="Using MIME">
|
|
146 <p>
|
|
147 gnus-mime uses <code>defvar</code> instead of <code>setq</code>,
|
|
148 because of respect user's setting before gnus-mime is loaded, such as
|
|
149 using <file>~/.emacs</file>. But it has a problem. If gnus is loaded
|
|
150 before gnus-mime is loaded, features of gnus-mime is not available in
|
|
151 default even if gnus-mime is loaded. Therefore there is serious
|
|
152 problem to load gnus before gnus-mime is loaded. In other words,
|
|
153 setting in <file>~/.gnus</file>, such as to load
|
|
154 <file>gnus-mime</file> or <file>mime-setup</file>, is not good way.
|
|
155 If you want such way, please do setting for
|
|
156 <code>gnus-show-mime</code> and <code>gnus-show-mime-method</code>.
|
|
157 </memo>
|
|
158
|
|
159
|
|
160 <h2> Mechanism of Automatic MIME preview
|
|
161 <node> Two buffers for an article
|
|
162 <p>
|
|
163 Gnus 5.2 or later has two buffers for an article,
|
|
164 <code>gnus-original-article-buffer</code> (<code>" *Original
|
|
165 Article*"</code>) and <code>gnus-article-buffer</code>
|
|
166 (<code>"*Article*"</code>). The former is called <concept>raw article
|
|
167 buffer</concept>, the latter is called <concept>preview
|
|
168 buffer</concept>.
|
|
169 <p>
|
|
170 Content of raw article buffer is non-processed ``raw message''. In
|
|
171 particular, for emacs variants includes <dref file="tm-en">mule</dref>
|
|
172 features, message is not code-converted in it.
|
|
173 <p>
|
|
174 Content of preview buffer is MIME processed message to display for
|
|
175 user. In particular, for emacs variants includes mule features,
|
|
176 non-ASCII message is code-converted in it by MIME charset or default
|
|
177 <dref file="tm-en">MIME charset</dref> for selected newsgroup.
|
|
178 <p>
|
|
179 Gnus 5.0.* and Gnus 5.1 don't have distinction between raw article
|
|
180 buffer and preview buffer. So gnus-mime emulate raw article buffer.
|
|
181 It is unnatural, so it may be better to use Gnus 5.2 or later, which
|
|
182 are designed for tm-view.
|
|
183 <p>
|
|
184 <cf file="tm-view-en" node="Two buffers for an article">
|
|
185
|
|
186
|
|
187 <h1> Internationalization
|
|
188 <node> mule
|
|
189 <p>
|
|
190 For emacs variants includes mule feature, such as <dref
|
|
191 file="tm-en">MULE</dref>, XEmacs/mule and Emacs/mule(*1), gnus-mime
|
|
192 supports code-conversion by <dref file="tm-en">MIME charset</dref> or
|
|
193 <code>default-mime-charset</code> of selected newsgroup.
|
|
194
|
|
195 <memo>
|
|
196 (*1) It means next generation of Emacs includes mule features. Now
|
|
197 (October 1996), HANDA Ken'ichi and RMS are developing it.
|
|
198 </memo>
|
|
199
|
|
200 <p>
|
|
201 Detail of code conversion is following:
|
|
202
|
|
203 <ol>
|
|
204 <li>If a newsgroup is selected, MIME charset for the newsgroup is
|
|
205 searched from <code>gnus-newsgroup-default-charset-alist</code>. If
|
|
206 it is found, it is set to buffer local variable
|
|
207 <code>default-mime-charset</code> of Summary Buffer. If not found,
|
|
208 global value of <code>default-mime-charset</code> is used.
|
|
209 </li>
|
|
210 <li>Non-ASCII characters in Summary Buffer are code-converted by
|
|
211 <code>default-mime-charset</code> in Summary Buffer.
|
|
212 </li>
|
|
213 <li><dref file="tm-en">encoded-word</dref> are code-converted by their
|
|
214 specified <dref file="tm-en">MIME charset</dref>.
|
|
215 </li>
|
|
216 <li>Code-conversion of articles are following:
|
|
217
|
|
218 <ol>
|
|
219 <li>If a part of a MIME message has charset parameter of <dref
|
|
220 file="tm-en">Content-Type field</dref>, it is code-converted by the
|
|
221 MIME charset.
|
|
222 </li>
|
|
223 <li>When there are no specified MIME charset, such as message header
|
|
224 or non-MIME message, they are code-converted by
|
|
225 <code>default-mime-charset</code> in Summary Buffer.
|
|
226 </ol>
|
|
227 </ol>
|
|
228
|
|
229
|
|
230 <defvar name="gnus-newsgroup-default-charset-alist">
|
|
231 <p>
|
|
232 Association-list regexp for newsgroup vs. symbol for default MIME
|
|
233 charset.
|
|
234 <p>
|
|
235 Default setting are following:
|
|
236
|
|
237 <dl>
|
|
238 <dt>alt.chinese.*
|
|
239 <dd>
|
|
240 <dref file="tm-en">hz-gb-2312</dref>
|
|
241 </dd>
|
|
242 <dt>alt.chinese.text.big5, hk.*, hkstar.*, tw.*
|
|
243 <dd>
|
|
244 <dref file="tm-en">cn-big5</dref>
|
|
245 </dd>
|
|
246 <dt>fj.*
|
|
247 <dd>
|
|
248 <dref file="tm-en">iso-2022-jp-2</dref>
|
|
249 </dd>
|
|
250 <dt>han.*
|
|
251 <dd>
|
|
252 <dref file="tm-en">euc-kr</dref>
|
|
253 </dd>
|
|
254 <dt>relcom.*
|
|
255 <dd><dref file="tm-en">koi8-r</dref>
|
|
256 </dl>
|
|
257 <p>
|
|
258 If there is no MIME charsets for a newsgroup,
|
|
259 <code>default-mime-charset</code> is used as default MIME charset.
|
|
260 </defvar>
|
|
261
|
|
262 <defun name="gnus-set-newsgroup-default-charset">
|
|
263 <args>newsgroup charset
|
|
264 <p>
|
|
265 Set default MIME <var>charset</var> of <var>newsgroup</var> to
|
|
266 <code>gnus-newsgroup-default-charset-alist</code>.
|
|
267 <p>
|
|
268 <var>newsgroup</var> is string of newsgroup name or category, for
|
|
269 <code>"gnu.emacs.gnus"</code>, <code>"gnu.emacs"</code>,
|
|
270 <code>"gnu"</code>.
|
|
271 <p>
|
|
272 <var>charset</var> is symbol of MIME charset, for example
|
|
273 <code>iso-8859-1</code>, <code>iso-2022-jp</code>.
|
|
274 </defun>
|
|
275
|
|
276
|
|
277 <h1> Composing MIME messages
|
|
278 <node> MIME-Edit
|
|
279 <p>
|
|
280 If using <dref file="tm-en">mime-setup</dref>, you can edit MIME
|
|
281 message in message-mode using <a file="tm-edit-en">tm-edit</a>.
|
|
282
|
|
283 <memo title="Notice">
|
|
284 <p>
|
|
285 Default setting of mime-setup avoids automatic inserting signature
|
|
286 when sending a message.
|
|
287
|
|
288 <cf file="tm-en" node="mime-setup">
|
|
289 </memo>
|
|
290
|
|
291 <p>
|
|
292 gnus-mime does not have implementation for <kbd>C-c C-x C-m</kbd>
|
|
293 (<code>mime-editor/insert-mail</code>). Because gnus-mime does not
|
|
294 know which mail-reader should be used. In addition, <kbd>C-c C-x
|
|
295 C-y</kbd> (<code>mime-editor/insert-message</code>) is enough to
|
|
296 insert mail (namely to select a mail group and select a message to
|
|
297 insert, then it is available to insert the mail message).
|
|
298 <p>
|
|
299 However you can use <kbd>C-c C-x C-m</kbd> to specify an
|
|
300 implementation of <code>message-mode</code> to
|
|
301 <code>mime-editor/mail-inserter-alist</code>.
|
|
302
|
|
303
|
|
304 <h2> Example: same as <kbd>C-c C-x C-m</kbd>
|
|
305 <p>
|
|
306 <lisp>
|
|
307 (set-alist 'mime-editor/mail-inserter-alist
|
|
308 'message-mode (function message-mime-insert-article))
|
|
309 </lisp>
|
|
310
|
|
311
|
|
312 <h2> Example: including from MH folder
|
|
313 <p>
|
|
314 <lisp>
|
|
315 (autoload 'tm-mh-e/insert-mail "tm-mh-e")
|
|
316
|
|
317 (set-alist 'mime-editor/mail-inserter-alist
|
|
318 'message-mode (function tm-mh-e/insert-mail))
|
|
319 </lisp>
|
|
320
|
|
321
|
|
322 <h1> Concept Index
|
|
323 <node> Concept Index
|
|
324 <p>
|
|
325 <cindex>
|
|
326
|
|
327
|
|
328 <h1> Function Index
|
|
329 <node> Function Index
|
|
330 <p>
|
|
331 <findex>
|
|
332
|
|
333
|
|
334 <h1> Variable Index
|
|
335 <node> Variable Index
|
|
336 <p>
|
|
337 <vindex>
|
|
338
|
|
339 </body>
|