Info file: mew.info,    -*-Text-*-
produced by `texinfo-format-buffer'
from file `mew.texi'
using `texinfmt.el' version 2.42 of  7 Jul 2006.

INFO-DIR-SECTION Message User Agent
START-INFO-DIR-ENTRY
* Mew: (mew.info).           Messaging in the Emacs World.
END-INFO-DIR-ENTRY






File: mew.info, Node: Top, Next: Overview, Prev: (dir), Up: (dir)

Mew Manual
**********

                                                         Kazu YAMAMOTO
                                                    Created 1996/02/18
                                                   Modified 2008/04/14

This manual documents Mew version 6.1. In addition to this manual, you
may find useful information about Mew from Mew's official home page
(http://www.Mew.org/).


* Menu:

* Overview::                    Read me first
* Viewing::                     Viewing messages
* Composing::                   Composing messages
* Marks::                       Funny marks
* Refile::                      Happy refiling
* Virtual::                     Virtual folder
* Quit::                        Give me a break
* Customize::                   Customizing Mew
* Tips::                        Advanced usage
* Convention::                  E-mail convention
* Implementation::              Implementation Issues
* Avail::                       Availability and mailing-list
* Copyright::                   Copyright
* Variable Index::              Variable Index
* Key Index::                   Key Index




File: mew.info, Node: Overview, Next: characteristic, Prev: Top, Up: Top

Read me first
*************

Mew is a user interface for text messages, multimedia messages (MIME),
news articles and security functionality including PGP, S/MIME, SSH,
and SSL. Also, Mew can work with the recent search services.

Mew is an acronym for "Messaging in the Emacs World". You should spell
it with the first letter capitalized and pronounce it as it is
(i.e. the meow of cats). When the author started programming it, he
chose a cute word from his English dictionary. Thus, Mew.

* Menu:

* characteristic::             Mew's features
* Emacsen::                    Supported Emacs versions
* modes::                      Modes
* folder convention::          Folder convention
* configuration::              Configuration
* password::                   Password
* start::                      Starting




File: mew.info, Node: characteristic, Next: Emacsen, Prev: Overview, Up: Overview

Mew's features
==============

The features of Mew 6.1 are as follows:

   - You can easily display a very complicated structured
     message. What you should do to view messages is just type `SPC'.

   - If you know how to do file operations such as copy, you can
     compose a very complicated message without any difficulty.

   - You can start to read messages before they are all fully listed.

   - Since Mew preserves lists of messages in Summary mode, when you
     move messages to a new folder, they will automatically be listed
     incrementally.

   - Mew neatly suggests default folders for refiling. Those who
     receive many messages cannot live without this feature.

   - In Draft mode, you can complete field names, e-mail addresses,
     receiver's names, domain names, and folder names.

   - You can easily search messages with keywords etc.

   - Mew automatically decodes messages encrypted with PGP or
     S/MIME. It also automatically verifies signed messages.

   - You can easily encrypt or sign a message with PGP or S/MIME.

   - It takes a bit of time to analyze MIME syntax or to verify a PGP
     or S/MIME signature. While the user is reading a message, Mew
     processes the next message so that the next message can be
     displayed faster. Analyzed messages are cached briefly.

   - You can view multiple folders simultaneously.

   - Selection/Thread, a mechanism to display the flow of messages, is
     supported. You can make Selection from messages matched to a
     keyword and make Thread from the Selection.

   - When you input a folder name, you can search it with a substring
     of the name.





File: mew.info, Node: Emacsen, Next: modes, Prev: characteristic, Up: Overview

Supported Emacs versions
========================

Please use Emacs 21.4 or later. Mew doesn't support earlier versions
nor XEmacs.




File: mew.info, Node: modes, Next: folder convention, Prev: Emacsen, Up: Overview

Modes
=====

Mew has the following six modes:

`Summary mode'
     A mode to list and select messages.
`Virtual mode'
     A mode to list messages selected with a specific condition from
     one or more folders. This is similar to Summary mode. This mode
     is categorized to Selection or Thread.
`Message mode'
     A mode to display the content of a message.
`Draft mode'
     A mode to prepare a message to be sent, answered, and forwarded.
`Header mode'
     A mode to edit the header of a message and to send it.
`Addrbook mode'
     A mode to register an entry to the address book (Addrbook).




File: mew.info, Node: folder convention, Next: configuration, Prev: modes, Up: Overview

Folder convention
=================

With Mew's terminology, a place where messages are deliver is called
'mailbox'. There are three kinds of mailbox: local, POP server, IMAP
server, and NNTP server.

A box which contains messages used by Mew is called "folder". The name
of a folder is in the format that "proto" is followed by a string,
where "proto" is one sign letter. For example, the proto of "+inbox"
is "+".

Mew's folders are categorized to two types: "local folder" and "remote
folder".

A local folder is a folder which is *original* and is created the
computer on which Mew is running. Also, messages stored in the folder
are *original*. (So, if you remove them, you cannot revive them.)

The proto of a local folder is "+". We summarize special local folders
as follows:

`+inbox'
     The first local folder to store messages which you fetch from
     your local mailbox or your POP server. To refile messages, what
     you do is to move the messages from "+inbox" to other folders.
`+draft'
     A local folder where messages, which you have not completed yet,
     are stored.
`+queue'
     A local folder where e-mail messages to be sent are stored. The
     messages in "+queue" will be eventually sent by SMTP.
`+postq'
     A local folder where NetNews message to be sent are stored. The
     messages in "+postq" will be eventually sent by NNTP.

A remote folder is a COPY whose original is on a server side. A
message in a remote folder is a cache which is copied from the server.

Here are a list of available proto of remote folders:

`%'
     Folders on an IMAP servers. Example: "%inbox"
`$'
     The folder on a POP server. Example: "$inbox" (Since there is
     only one folder in a POP server, "$inbox" is the only folder
     whose name starts with "$".)
`-'
     Newsgroups of NetNews. Example: "-fj.mail.reader.mew"

If you use several servers, there are multiple sets of remote folders.
You can specify several servers by using "case". For more information
about the "case", see *Note config::. To specify a remote folder
corresponding to a "case", you should write "case:folder". You can
omit "case:" if a case is "default".

A combination of "case" and proto organized a world to which a message
belongs. A message can move within its world. To make it easy to
search received messages afterward, they should be moved to proper
folders. To know how to refile received messages, see *Note Refile::.

You cannot move a message in the "$" world because there is only one
folder, "$inbox". You cannot move a message in the "-" world either
since messages in the "-" world are not yours.

If you want to move a message from one world to another, you should
COPY it. Its destination is restricted to a local folder. This method
is described in *Note retrieving::.

If you make a list of folders, you can use the completion
functionality for folders. To know how to make a list of folders,
please refer to *Note status-update::.




File: mew.info, Node: configuration, Next: password, Prev: folder convention, Up: Overview

Configuration
=============

To execute Mew, the followings are necessary either in the site
configuration file or in your "~/.emacs".

     (autoload 'mew "mew" nil t)
     (autoload 'mew-send "mew" nil t)

     ;; Optional setup (Read Mail menu for Emacs 21):
     (if (boundp 'read-mail-command)
         (setq read-mail-command 'mew))

     ;; Optional setup (e.g. C-xm for sending a message):
     (autoload 'mew-user-agent-compose "mew" nil t)
     (if (boundp 'mail-user-agent)
         (setq mail-user-agent 'mew-user-agent))
     (if (fboundp 'define-mail-user-agent)
         (define-mail-user-agent
           'mew-user-agent
           'mew-user-agent-compose
           'mew-draft-send-message
           'mew-draft-kill
           'mew-send-hook))

If you are using Emacs with the --unibyte option or the EMACS_UNIBYTE
environment variable for Latin-1, put the following into your
"~/.emacs".

     (set-language-environment "Latin-1")
     (set-input-method "latin-1-prefix") ;; or "latin-1-postfix"

If you use the following configuration for Latin-1, please remove it.
This is an obsolete handling of Latin-1 that can cause Mew to function
incorrectly.

     (standard-display-european 1)

When booting, Mew reads the file "~/.mew.el". All Mew configurations
should be written in this file.

To configure your e-mail address, the followings are necessary.

     ;; (setq mew-name "your name") ;; (user-full-name)
     ;; (setq mew-user "user name of e-mail address") ;; (user-login-name)
     (setq mew-mail-domain "domain of e-mail address")

To send e-mail messages by SMTP, the following is necessary.

     (setq mew-smtp-server "your SMTP server")  ;; if not localhost

If you want to use POP to receive e-mail messages, the followings are
necessary.

     ;; (setq mew-pop-user "your POP account")  ;; (user-login-name)
     (setq mew-pop-server "your POP server")    ;; if not localhost

If you want to use a local mailbox to receive e-mail messages, the
followings are necessary.

     ;; To use local mailbox "mbox" or "maildir" instead of POP
     (setq mew-mailbox-type 'mbox)
     (setq mew-mbox-command "incm")
     (setq mew-mbox-command-arg "-u -d /path/to/mbox")
     ;; If /path/to/mbox is a file, it means "mbox".
     ;; If /path/to/mbox is a directory, it means "maildir".

If you want to use IMAP to receive e-mail messages, the followings are
necessary.

     (setq mew-proto "%")
     ;; (setq mew-imap-user "your IMAP account")  ;; (user-login-name)
     (setq mew-imap-server "your IMAP server")    ;; if not localhost

To read and/or write articles of NetNews, the followings are
necessary.

     ;; (setq mew-nntp-user "your NNTP account")
     (setq mew-nntp-server "your NNTP server")




File: mew.info, Node: password, Next: start, Prev: configuration, Up: Overview

Password
========

When fetching/sending messages or using PGP or S/MIME, you may be
required to input your password. Before you type your password, check
carefully to see if either the following conditions is satisfied:

   - Emacs is running on a local computer
   - Emacs is running on a remote computer, but an encryption
     mechanism is being used for communication.

If neither of these conditions are satisfied, do not input a
password. Your password could be accessed without your knowledge.

If you get sick of inputting your password from time to time, please
use one of two password-cache mechanisms.

  1. Storing passwords in memory temporarily. Not writing them to a
     file.
  2. Storing passwords in memory while Mew is running. When Mew/Emacs
     quits, Mew encrypts the passwords and writes them to a file.

To use Feature 1., configure as follows:

     (setq mew-use-cached-passwd t)

To use Feature 2., after installing GnuPG, configure as follows:

     (setq mew-use-master-passwd t)

If both variables are `t', the feature 2. is used.

Feature 1.: Any passwords including POP and PGP are cached in
memory. While a password is cached, you can omit to input the
password. The cached password will expire after a certain period (20
minutes by default). However, its timer is cleared (reset to 20
minutes) if the password is used internally.

Feature 2: When Mew boots, Mew asks you to input a master password.
Mew decrypts encrypted passwords in a file and caches them in memory.
For instance, if you have already typed POP password, it is to be
stored in memory. Thus, when the POP password is required, you can
omit to input it. If you use a master password at the first time, you
are asked to input it twice. When Mew boots, you might type a wrong
master password. In this case, if you enabled Feature 1., it is
used. Otherwise, no password-cache mechanisms is used.

If you want to change the master password, type `C-cC-m' in Summary
mode.

Cached passwords in memory are not encrypted. So, if you use either
Feature 1. or Feature 2., you should take care so that nobody can
touch your Emacs. If you leave your PC and an Emacs expert happens to
check your configuration, your passwords could be stolen.




File: mew.info, Node: start, Next: Viewing, Prev: password, Up: Overview

Starting
========

To start Mew, you can choose one of the following:

`M-x mew'
     Execute Mew first unless Mew is running. And retrieve arrived
     messages or just visit to the default folder.

     `proto' is determined by `mew-proto' and the "case" (see
     *Note config::).

     If `proto' is `+' (i.e. a local folder), a mailbox is determined
     according to `mew-mailbox-type' (see *Note retrieving::).
     Otherwise (i.e. a remote folder), an appropriate protocol to
     retrieve messages is chosen according to `proto'.

     If `mew-auto-get' is `t', arrived messages are asynchronously
     fetched and listed up in Summary mode.

     `mew-auto-get' is `nil', just visit to the folder determined by
     `proto'.
`C-uM-x mew'
     Perform `M-x mew' with `mew-auto-get' reversed.
`M-x mew-send'
     Enter Draft mode for message composing.
`C-xm'
     Enter Draft mode for message composing if `mail-user-agent' is
     configured.

When Mew is executed on Emacs, two cute cats appear on the cover page.

For the methods of quitting Mew, please refer to *Note Quit::.




File: mew.info, Node: Viewing, Next: singlepart, Prev: start, Up: Top

Viewing messages
****************

If you input `M-x mew' (regardless Mew is running or not), Mew
displays a list of message like this:

     * 03/12 Hidenori Ohta  This weekend              |Let's go to StoneMagic
      M03/14 Momo-chan      The pictures of Noto      |Attached are the pictu
       03/15 Neat Sumikawa  Re: wine                  |OK. I vote for Wednesd

This is called Summary mode. This section mainly explains how to read
messages in Summary mode.

As you can see the example above, the format of Summary mode consists
of a mark, data type (a mark by Mew), date, a sender, Subject:, and a
body.

For the method of terminating Summary mode, please see *Note Quit::.

* Menu:

* singlepart::                  Reading Basis
* multipart::                   Displaying MIME
* analysis::                    Controlling MIME analysis
* cipher-viewing::              Visualizing cipher or signature
* retrieving::                  Getting messages
* moving::                      Moving to another folder
* sum-write::                   Write, answer, and forward
* features::                    Useful features
* status-update::               Updating status
* invalid::                     Invalid messages



File: mew.info, Node: singlepart, Next: multipart, Prev: Viewing, Up: Viewing

Reading Basis
=============

To read messages in the order of their arrival, type `SPC' to display
them. That's it. It's easy, isn't it?

Yet this might not be comprehensive, so the basic commands for page
processing are listed as follows:

`SPC'
     Read through messages. That is, display a message, scroll it, and
     move-then-display another message. Refer to *Note summary-mode::
     to know which direction the cursor moves.
`C-uSPC'
     Redisplay the message from its header.
`DEL'
     Back-scroll this message. Unnecessary header fields are hidden
     over the window. Type `DEL' to see them when a message is
     displayed.
`RET'
     Make this message scroll up one line.
`M-RET'
`-'
     Make this message scroll down one line.

`C-n'
     Go to the next line.
`C-p'
     Go to the previous line.
`n'
     Move down then display. Targets include parts, messages marked with
     `*', and non-marked messages.
`C-un'
     Move down then display. Targets include messages marked with `*',
     and non-marked messages.
`p'
     Move up then display. Targets include parts, messages marked with
     `*', and non-marked messages.
`C-up'
     Move up then display. Targets include messages marked with `*',
     and non-marked messages.
`j'
     Jump to a line according to the line number which you input.
`C-uj'
     Jump to a message according to the message number which you
     input.



File: mew.info, Node: multipart, Next: analysis, Prev: singlepart, Up: Viewing

Displaying MIME
===============

It's not difficult to read a multipart message. As usual, just type
`SPC'.

A multipart message is marked with `M' on the left side of date as
follows:

     * 03/12 Hidenori Ohta  This weekend              |Let's go to StoneMagic
      M03/14 Momo-chan      The pictures of Noto      |Attached are the pictu
       03/15 Neat Sumikawa  Re: wine                  |OK. I vote for Wednesd

When you type `SPC' on the message marked with `M', its header is
displayed in Message mode. Then its multipart structure is displayed
in Summary mode as follows:

     * 03/12 Hidenori Ohta  This weekend              |Let's go to StoneMagic
      M03/14 Momo-chan      The pictures of Noto      |Attached are the pictu
     B    2  Image/Jpeg                   picture 1                noto1.jpg
     Q    3  Application/Postscript       Note map                 map.ps
       03/15 Neat Sumikawa  Re: wine                  |OK. I vote for Wednesd

If the first part is Text/, the first part is not displayed in Summary
mode but the first part is displayed with its header in Message mode.

Each line of multipart consists of

   - marks (Content-Transfer-Encoding:)
   - part number
   - data type (Content-Type:)
   - description (Content-Description:)
   - file name (Content-Disposition:).

Content-Description can be considered Subject: for each part. This
format is very similar to that of the attachment region in Draft mode.

If you type `SPC' or `n', the cursor moves onto part 2 and the content
is displayed according to its data type. For instance, Text/Plain is
showed in Message mode and PostScript is visualized with "ghostview".

Please note that `n' and `p' move lines including multipart.
To display the message below skipping multipart, type `C-un'.
Likewise, to display the message above (not this message), input
`C-up'.

Mew processes MIME recursively. The following example is a forwarded
multipart message.

      M03/15 Kazu yamamoto  Fw: The pictures of Noto  |Attached are the pictu
          2  Message/Rfc822               The pictures of Noto
     B    2.2  Image/Jpeg                   picture 1              noto1.jpg
     Q    2.3  Application/Postscript       Note map               map.ps

Note: We strongly recommend that you not embed any object other than
text as a top level single part to a message directly. Instead, it is
better to make a multipart message whose part 1 is a textual
description of part 2 and part 2 is a non-text object.

A message which contains a single part other than text is displayed as
multipart.

Since the syntax of MIME messages can be complex, it sometime takes a
bit of time to analyze the syntax. However, Mew guesses the message to
be read next and analyzes it beforehand while the user is reading the
current message. Analyzed messages are temporarily cached.

To make it clear where the message ends, Mew displays the string "[End
of message]" in the end of the message. At the end of each part, Mew
displays the string "[Message is continued]". These strings are
customized by `mew-end-of-message-string' and
`mew-end-of-part-string', respectively.



File: mew.info, Node: analysis, Next: cipher-viewing, Prev: multipart, Up: Viewing

Controlling MIME analysis
=========================

There are several variables for controlling message analysis.

`mew-file-max-size'
     The size limit of messages to be analyzed. If the size of a
     message is less than or equal to this value, it is analyzed and
     displayed.  Otherwise, the raw message is displayed without
     analysis. The default value is 10000 bytes.
`mew-header-max-length'
     The length limit of header to be analyzed. If the length of a
     header is less than or equal to this value, it is analyzed and
     displayed.  Otherwise, the message is displayed as fragmentarily
     since the analysis is stopped. The default value is 100 lines.
`mew-decode-broken'
     Whether Mew be liberal or conservative to invalid messages. If the value
     is `t', the setting is liberal. If the value is `nil', the
     setting is for conservative. If conservative and invalid portions are
     found, they are reported in the X-Mew: field. The default value is
     `t'.
`mew-use-text-body'
     Whether or not the text part of a body is displayed with its
     header. If the value is `t', both the body which is a single part
     text and the first text part in a multipart body are displayed
     with its header. If the value is `nil', they are displayed as a
     single part in a multipart. The default value is `t'.
`mew-use-alternative'
     How to treat Multipart/Alternative. If the value is `t', one part
     is displayed according to the preference defined in
     `mew-mime-multipart-alternative-list'. If the value is `nil', it
     is displayed as a multipart. The default value is `t'.
`mew-use-text/html'
     How to treat Text/Html. If `nil', HTML is displayed as is
     (without parsing). Otherwise, HTML is parsed and displayed. The
     default value is `nil'.
`mew-use-text/xml'
     How to treat Text/Xml. If `nil', XML is displayed as is (without
     parsing). Otherwise, XML is parsed and displayed. The default
     value is `t'.

The basic command relating to the variables above is `.'. The command
acts as follows:

1) If this command executed on a message, the cache of the message is
removed and the message is analyzed then displayed.

1a) If the size of the current message exceeds `mew-file-max-size',
MIME analysis is skipped then the beginning of the raw message is
displayed. In this situation, this command analyzes the current
message without the limitation then displays it.

1b) If the length of a header exceeds `mew-header-max-length', a
broken message is displayed. In this situation, this command analyzes
the current message without the limitation then displays it.

1c) If the current message is displayed by `:', the multipart
structure is displayed different from the normal display. In this
situation, this command gets the multipart structure back to the
normal display.

1d) If `mew-use-text/html' is `nil', its HTML body is displayed as
is. In this situation, this command analyzes the HTML body and
displays it.

2) If this command is called on a part, the part is displayed again.

2a) If 'mew-use-text/html' is `nil', its HTML part is displayed as
is. In this situation, this command analyzes the HTML part and
displays it.

In addition to `.', the following commands are prepared:

`.'
     Analyze the message and re-display it.
`C-u.'
     Analyze the message with `mew-decode-broken' reversed (see
     *Note invalid::).
`:'
     The same as `.' with `mew-use-alternative' and
     `mew-use-text-body' reversed.
`C-u:'
     The same as `C-u.' with `mew-use-alternative' and
     `mew-use-text-body' reversed.
`,'
     Insert a message or a part into Message mode in raw format.
`C-cTAB'
     Open an entire message as a file in read-only mode.
`C-uC-cTAB'
     Open an entire message as a file.



File: mew.info, Node: cipher-viewing, Next: retrieving, Prev: analysis, Up: Viewing

Visualizing cipher or signature
===============================

Basic commands such as `SPC' visualize messages signed or encrypted as
well. Let's start with a simple example:

      S03/18 Kanda PC shop  A written estimate        |Here is a written esti
      E03/21 Anonymous      Secret message            |

Messages above are marked with `S' and `E', respectively. This means
that the body of the first message is signed and that of the second
message is encrypted.

PGP/MIME and/or S/MIME also allow to sign and/or encrypt some parts of
a message. In this case, these marks do not appear. The `S' or `E'
mark appears only when the entire body of the message is signed or
encrypted.

The terms "sign" and "encrypt" used above mean the last procedure
applied the body is "sign" and "encryption", respectively. The above
examples may have been produced with more complex processes.  For
instance, in the case of the former message, the body may have been
signed after encrypting the body.  It is likely that some part of the
latter message was first signed then the body was encrypted.

If some parts or the entire body is encrypted, Mew asks you to input
your pass-phrase to get plain text. Please refer to *Note start:: to
know what you should pay attention when inputting pass-phrase. The
pass-phrase is used to decrypt your secret key. The secret key is then
used to decrypt cipher text.

To visualize a cipher message, you need to input your pass-phrase
every time you encounter cipher text. This is because Mew does not
cache pass-phrases anywhere for security reasons. If you feel this is
inconvenient, you can configure Mew to cache your pass-phrase. Please
refer to *Note password:: for more information.

Since decrypted messages are cached for a while, you may not be asked
for your pass-phrase at the next time you display the message, even if
you are not using the pass-phrase cache.

To verify signatures, senders' public keys are used. Hence you are not
asked to type your pass-phrase.

Since Mew automatically verifies signatures and/or decrypts cipher
text with a pass-phrase, it is likely that users do not notice that
the original message has signatures and/or which parts were encrypted.

To inform users the results of verification of signatures or which
parts were decrypted, Mew inserts the X-Mew: field in the header as
follows:

     X-Mew: <body> PGP decrypted.
            Good PGP sign "kazu@example.org" COMPLETE

The number enclosed by "<>" indicates which part was protected with
PGP. "body" means the body was protected. This example tells us that
the body was singed by kazu then encrypted for the reader. Mew first
decrypted the message and then verified its signature of the decrypted
message. The fact that the signature is valid indicates that no one
has modified the content of the message since it was signed by the
secret key whose ID is kazu@example.org. The validity of the public
key used to verify the signature is "complete". Thus, the receiver can
be sure that the public key actually belongs to the user indicated by
the ID. That is, this message was verified by a reliable public key
AND its results were correct, so no alternation was found.

In the following example, the signature of the body (multipart), is
first verified, then part 2 (a message), is decrypted. That is, the
composing process was that part 2 is first encrypted then the entire
body is signed.

     X-Mew: <body multi> Good PGP sign "kazu@example.org" COMPLETE
     X-Mew: <2 message> PGP decrypted.

Intelligent users may wonder what happens in the case where a devious
person sends a message that contains an invalid X-Mew: field. This is
not a problem. First Mew carefully removes the X-Mew: field, and then
inserts a valid X-Mew: field into the header.

About PGP/MIME:

X-Mew: informs the user of various other types of results. For
example, the lack of availability of a public key, decryption
failures, etc. The following example indicates the absence of a public
key whose key ID is 0x1B8BF431.

     X-Mew: <body multi> No his/her public key. ID = 0x1B8BF431

In this case, if you type `C-cC-f', Mew tries fetching this public
key. You can interactively select a public key server. If the X-Mew:
field does not exist, `C-c C-f' takes the From: field as ID. Also,
`C-uC-cC-f' extracts key IDs from fields specified in
`mew-x-pgp-key-list' in addition to the X-Mew: field, and then tries
to fetch them.

Mew supports PGPv2, PGPv5, and GNUPG. You can select one of these by
typing `C-cC-v' in Summary mode. If you want to use those PGPs, you
should set the command name of PGPv2, PGPv5, and GNUPG to
`mew-prog-pgp2', `mew-prog-pgp5', and `mew-prog-gpg',
respectively. Also, set the default PGP name to `mew-prog-pgp'. Note
that pass-phrases are cached independently for each PGP.

Old fashioned PGP messages cannot be processed automatically. You can
decrypt and/or verify this kind messages with `C-cC-z'.



File: mew.info, Node: retrieving, Next: moving, Prev: cipher-viewing, Up: Viewing

Getting messages
================

To copy arrived messages to your mailbox to +inbox and list up a list of
the messages, use `i'. The mailbox is determined according to
`mew-mailbox-type'. (When you type `M-x mew' and if
`mew-proto' is `+', messages are also copied according to
`mew-mailbox-type'.) Here are summary of its values.

`'mbox'
     A local mailbox. "incm" is used to copy messages for the local
     mailbox by default. To know how to configure it, see *Note
     configuration::.
`'pop'
     A POP server. To use POP as it is. (This is a default value.)
`'imap'
     An IMAP server. This is not recommended.

To flush a list of messages in a local folder and display them again,
use `s'.

To retrieve messages or flush-then-retrieve messages again in a remote
folder, type `s'. It is recommended to use `s', not `i', for IMAP and
NetNews.

If you use `s', it asks you a range. Here are a summary of important
ranges for Mew.

`update'
     From "the last message in the Summary mode + 1" to "the last
     message in the corresponding folder". That is, the gap between
     the Summary mode and the existing folder
`all'
     All messages in the folder. When Summary mode in a local folder
     becomes inconsistent, use this range to flush the list. For a
     remote folder, this range results in retrieval of all messages
     again.
`sync'
     Deleting cache messages whose originals were removed in the
     server side.  Valid for remote folders only.

The default range both for +draft, +queue, and +postq is `all'. For
other folders, the default is `update'. So, just type `RET' after `s'
to get the up-to-date list of the current folder except +draft,
+queue, and +postq.

Although they are not especially important in Mew, you can specify the
following ranges:

`<num1>-<num2>'
     From <num1> to <num2>. Valid for local folders only.
`<num1>-'
     From <num1> to the last. Valid for local folders only.
`-<num2>'
     From the first to <num2>. Valid for local folders only.
`last:<num>'
     Last <num> messages.

If you execute `s' with `C-u' on a remote folder, you can
toggle "copying a header only" and "copying both a header and a body".
This action can be defined by `mew-pop-header-only',
`mew-imap-header-only', and `mew-nntp-header-only' for POP,
IMAP, and NNTP, respectively. The default values of these are
`nil', that is, "copying both a header and a body".

Messages that are of large size may be truncated. This kind of message
is marked with `T'. To retrieve the rest of this kind of message, type
`I' on the message.

Suppose that there is a message marked with `T' in $inbox. If you type
`I' on it, you can retrieve the entire message.

Here is a summary of the commands concerned with message retrieval:

`i'
     In a local folder, fetch arrived messages, store them to the +inbox
     folder and create a list. If `mew-auto-flush-queue' is `t',
     send messages in +queue. Please refer to *Note send:: for more
     information. In a remote folder, visit to its inbox folder and execute
     `s' + `update'.
`C-ui'
     Perform `i' with `mew-auto-flush-queue' reversed.
`I'
     Retrieve the rest of a truncated(`T') message.

     If you use this command in a local folder, a method to retrieve
     the message is determined by the "case" and
     `mew-mailbox-type'. If `mew-pop-delete'/`mew-imap-delete' is `t',
     delete the message from the mailbox.

     If you use this command in a remote folder, a "case" and protocol
     is determined by the folder. The message in the server side is
     always retained.
`C-uI'
     Perform `I' with `mew-pop-delete' or `mew-imap-delete' reversed.
`s'
     List up messages in Summary mode or flush them.
`C-us'
     On a remote folder, list up messages in Summary mode by toggling
     copying a header only" and "copying both a header and a body".
`lc'
     Copy a cached message in a remote folder to a local folder.



File: mew.info, Node: moving, Next: sum-write, Prev: retrieving, Up: Viewing

Moving to another folder
========================

To go to another folder, type `g'. Mew asks you to input a folder name
as follows:

     Folder name (+inbox): +

Let's call the right side of ":" 'writable area'. In this example,
proto "+" is displayed in the writable area. Typing an appropriate
string following proto and typing `RET' decides a folder name, then
Mew moves to the folder.

When you move to a folder and if Mew finds its list of messages old,
Mew automatically displays the differences.

The string in "()" is a default. If you specifies "+" by simply typing
`RET', Mew considers that the default folder name is specified.

To make use of completion, type `TAB' or `SPC'.

Now, lets get back to the state just after typing `g'.

     Folder name (+inbox): +

If you want to change, for example, "+" to "%", you have to delete "+"
first then type "%" in normal situation. But this is inconvenient. So,
typing "%" just after "+" removes "+" automatically. Like this, typing
another proto just after a proto replaces the previous one without
deletion.

When you type a remote folder, you may want to specify the "case"
(described in *Note config::). The "case" must be specified before a
folder, separated by ":". Consider moving "%inbox" for a "case"
"home". In this case, you should type "home:%inbox". Yes, this is
inconvenient. So, typing `C-cTAB' in any position does circular
completion for available "cases". Let's look at the following example.

     Folder name (+inbox): %inbox

Typing `C-cTAB' here results in the following:

     Folder name (+inbox): home:%inbox

You may want to search a folder by specifying a substring of the
folder.  For this purpose, `C-s' and `C-r' are available. The
following is the state of the minibuffer after typing `C-s'.

     Folder name (+inbox): ()

"()" appeared in the writable area indicates you have switched to
search mode. While you are typing here, a matched candidate is shown
in "()".  The following is the case where a search key is "mew".

     Folder name (+inbox): (+work/mew-release) mew

To select the matched candidate, type `RET'. Then the search mode is
finished and the matched candidate is displayed in the writable area.

     Folder name (+inbox): +work/mew-release

Typing `RET' again means that you decide the folder.

A list of folders to be searched is decided by a combination of "case"
and proto. When you enter the search mode by typing `C-s' or `C-r', a
pair of "case" and proto is extracted from the writable area, and a
list of folders is selected according to the pair.



File: mew.info, Node: sum-write, Next: features, Prev: moving, Up: Viewing

Write, answer, and forward
==========================

Please use the following commands for writing, replying, and
forwarding messages.

`w'
     Write a message. A new draft is prepared in Draft mode. Please refer to
     *Note Composing::.
`C-uw'
     Write a message. A new draft is prepared in Draft mode. The From:
     address of the current message is copied to the To: field in the
     draft.
`W'
     Send a message by modifying a part of the header of another
     message.  Please refer to *Note resend::.
`a'
     Answer to this message. A new draft is prepared in Draft
     mode. Mew automatically inserts the content of the fields To: and
     Cc:. Please refer to *Note reply::.
`C-ua'
     Answer to this message only to the sender.
`A'
     Answer to this message. A new draft is prepared in Draft
     mode. Mew automatically inserts the content of the fields To: and
     Cc: and cites the body. Please refer to *Note reply::.
`C-uA'
     Answer to this message only to the sender with citation.
`f'
     Forward this message to a third person. A new draft is prepared in Draft
     mode and this message is automatically attached. Please refer to
     *Note forward::.
`F'
     Forward messages marked with `*' to a third person. A new draft is
     prepared in Draft mode and this message is automatically attached. For
     more information, refer to *Note target mark::. Please refer to
     *Note forward::.

If an error message returns, please try again with the following
commands.

`E'
     Edit this message again to retry sending. Or edit this RFC822
     part typically included in a MIME-encapsulated error message.

       1. In +draft, the message is just edited.
       2. In +queue or +postq, the message is moved to +draft and is
          edited.
       3. Otherwise, the message is copied to +draft and is edited.

     For +draft, +queue, and +postq, the "case" revives.

     For the other folders, if `mew-case-guess-when-prepared' is `t',
     each field of the original header is replaced according to a
     guessed "case". For more information, see *Note config::.
`C-uE'
     The same as `E'. But, when used for other folders than +draft,
     +queue, and +postq, the original header is retained even if
     `mew-case-guess-when-prepared' is `t'.
`M-e'
     Edit an old fashioned error message in which the original message
     is encapsulated after "----- Original message follows -----".



File: mew.info, Node: features, Next: status-update, Prev: sum-write, Up: Viewing

Useful features
===============

Mew provides you with the following useful commands in Summary mode:

`v'
     Toggle "Summary mode only" and "Summary & Message mode". If you
     choose "Summary mode only", you can quickly put the `D' mark
     since the next message is not displayed.
`_'
     Toggle normal lines, wrapped lines and long lines.
`zv'
     If `mew-use-header-veil' is non-nil, field lines of To: and Cc:
     over `mew-header-veil-count' are covered with invisible
     veils. This commands toggles visibility of these lines.
     `mew-use-header-veil' and `mew-header-veil-count' are default to
     `t' and 4, respectively.
`M-l'
     Make the current line the center of the Summary mode.
`C-cC-s'
     Incremental search forward in Message mode.
`C-cC-r'
     Incremental search backward in Message mode.
`y'
     Save this message or this part into the file whose name is
     specified by you.
`C-uy'
     Save this message or this part into the file whose name is
     specified by you, specifying coding-system for text.
`#'
     Print the content of Message mode according to
     `mew-print-function'.
`C-u#'
     Print the content of Message mode with a specified printer name.
`|'
     Send the content of Message buffer to a command via pipe.
`C-u|'
     Send the body of Message buffer (excluding its header) to a
     command via pipe.
`\'
     Executing an external command specifying this message as an
     argument.
`B'
     De-capsulate embedded messages in MIME format.
`C-uB'
     Decompose embedded files in this message.
`C-cC-a'
     Register the information on the current message to Addrbook
     (*Note addrbook::).
`C-cC-v'
     Select PGP version (*Note cipher-viewing::).
`C-cC-z'
     Let PGP decrypt and/or verify old fashioned PGP messages (*Note
     cipher-viewing::).
`C'
     Change the value of the "case". For more information, please refer to
     *Note config::.
`='
     Display the folder name of this message and the message
     number. If this is a cache message, both the unique id and the
     size are also shown.  The full path to the message is set to the
     cut buffer of your window manager.
`;'
     Parse the Received: fields and display them in Message mode.



File: mew.info, Node: status-update, Next: invalid, Prev: features, Up: Viewing

Updating status
===============

In some cases of configuration modifications, you have to update
status to reflect them. When you think configuration modifications
don't make any effects or some errors occur, use one of the following
commands:

`Z'
     Update information including Addrbook(*Note addrbook::).
`C-uZ'
     Update information about folders of the current world.

Here is a summary of toggle commands.

`z8'
     Toggle 8bit mode (i.e. `mew-use-8bit').
`zc'
     Clean-up caches of analyzed messages.
`zd'
     Toggle `mew-debug'.
`zo'
     Toggle PGP/MIME or old-fashioned PGP (`mew-use-old-pgp') when
     composing with shortcut methods.
`zp'
     Toggle decode policy (i.e. `mew-decode-broken').
`zv'
     Toggle whether or not veil is used in Message
     mode(`mew-use-header-veil').
`zw'
     Toggle warning level. If `mew-warning-field-level' is 2, set it
     to 1. If `mew-warning-field-level' is 1, set it to 2.



File: mew.info, Node: invalid, Next: Composing, Prev: status-update, Up: Viewing

Invalid messages
================

The following message contains Japanese text in its body. The charset
parameter is not specified in the Content-Type: field. So, the body
should be treated as US-ASCII.

     To: piglet
     Subject: an invalid message
     From: pooh
     MIME-Version: 1.0
     Content-Type: Text/Plain

     Japanese comes here.

The following header is invalid as well.

     From: "=?iso-2022-jp?B?GyRCOzNLXE9CSScbKEI=?=" <kazu@example.net>

The string delimited by "=?" and "?=" in the above example was
originally Japanese. Since the spec of mail limits the content of
headers to ASCII characters, if a string whose character set is other
than ASCII, is to be stored in a header, the string must be encoded
with ASCII strings according to the defined rule. But it is certainly
invalid to embed the ASCII strings with `"'. Strings surrounded by `"'
are treated as is. Therefore, the string between "=?" and "?=" in the
example will not be decoded into Japanese.

Several mailers are careless about the spec and regularly violate
these rules. The right way to do is ask the programmers of such
mailers to make the programs conformant to the spec. However, since
there are so many mailers of this kind around the world, Mew tries to
decode as many different formats as possible. In these cases Mew
displays warnings such as:

     X-Mew: Charset for body is not specified.
            To: has encoded-words in quoted text.

If you want to decode messages strictly, set `mew-decode-broken' to
`nil'. This value can be toggled dynamically by `C-u.' (see
*Note singlepart::).

The following message is displayed as a mess since the character set
specified with the charset parameter and the actual character set of
its body are different.

     Content-Type: Text/Plain; charset=ISO-2022-JP

     Japanese text written in Shift_JIS

By using `C-cC-l', the text is re-displayed with charset guessed
according to a specified language, ignoring the character set
specified by the charset parameter. If you type `C-uC-cC-l', you can
re-display the text by specifying a character set explicitly.




File: mew.info, Node: Composing, Next: header, Prev: invalid, Up: Top

Composing messages
******************

This section explains how to compose a message.

Methods to enter Draft mode to write a new message are given below.

  1. Type `M-x mew-send'.
  2. Type `C-xm' if `mail-user-agent' is configured.
  3. Press `w' in Summary mode.

Then a buffer like the following is prepared.

     To:
     Subject:
     From: Kazu Yamamoto <kazu@example.org>
     X-Mailer: Mew version 6.1 on Emacs 22.1
     ----

We call this "Draft mode". In Draft mode, we call the region above
"----" the header, and the region below "----" the body.

Also, replying a message (`a' or `A') and/or forwarding messages (`f'
or `F') lead you to Draft mode from Summary mode.

Drafts are temporarily stored in the +draft folder. You can write
multiple messages simultaneously.

For the method of deleting a prepared draft, please refer to
*Note Quit::.

Now let's see how to use Draft mode.

* Menu:

* header::                      Completions in a header
* cheader::                     Circular completions in a header
* addr-comp::                   Address Completion
* addrbook::                    Address book
* auto-alias::                  Learning addresses
* addr-comp1::                  Address Completion(1)
* addr-comp2::                  Address Completion(2)
* send::                        Sending a message
* cite::                        Signature and citation
* mime-comp::                   Composing multipart
* charset-guess::               Defining charset
* reply::                       Replying to a message and deciding recipients
* forward::                     Forwarding messages
* resend::                      Re-sending messages
* shortcut::                    Creating signature or cipher message
* mark-b-comp::                 Mark based composer
* pgp-key::                     PGP key distribution
* anonymous::                   Sending messages with anonymous receivers



File: mew.info, Node: header, Next: cheader, Prev: Composing, Up: Composing

Completions in a header
=======================

In the header, completions for each field are assigned to `TAB' as
follows:

   - Field completion
   - Address completion (To:, Cc:, etc) (See *Note addr-comp::)
   - Folder completion (Fcc:)

<Field completion>

If the cursor is at the beginning of a line and the previous line does
not end with ",", you can complete field defined in the
`mew-fields' variable with `TAB'.

     To: kazu@example.org
     R`TAB'

At the point above, if you type `TAB', you get:

     To: kazu@example.org
     Reply-To:

<Folder completion>

At a point, such as Fcc:, you can complete folder name with
`TAB'. For example:

     Fcc: `TAB'

Here, "+" is completed.

     Fcc: +`TAB'

One more type of `TAB' shows candidates. Please type in the
appropriate characters then type `TAB'.

     Fcc: +b`TAB'

If a single candidate can be determined, you get a completion.

     Fcc: +backup



File: mew.info, Node: cheader, Next: addr-comp, Prev: header, Up: Composing

Circular completions in a header
================================

In a header, circular completions are assigned to `C-cTAB'.  Circular
completion means that a value of a list is replaced by the next value
of the list. The end of the list is considered continuous to the top
of the list. Circular completions in a header are different for each
field as follows:

   - Circular completion of domain name (To:, Cc:, etc)
   - Circular completion of From: (From:)

<Circular completion of domain name>

On a field where addresses are written, use `C-cTAB' for domain
completion. Candidates are selected from `mew-mail-domain-list'.

     To: kazu@`C-cTAB'

If you try to complete just after "@" as up above, the first domain of
`mew-mail-domain-list' is inserted.

     To: kazu@example.org`C-cTAB'

After completion, pressing `C-cTAB' one more times inserts the next
domain of `mew-mail-domain-list'. This completion is looped.

     To: kazu@example.jp

If a single candidate can be determined, it is inserted.

     To: kazu@w`C-cTAB'

The above example gives:

     To: kazu@example.jp

<Circular completion of From:>

In Draft mode, the From: field is inserted with the format of
mew-name <mew-user@mew-domain>".

     From: Kazu Yamamoto <kazu@example.org>

On the From: field, `C-cTAB' circularly completes its value from
`mew-from-list'. You can set `mew-from-list' by yourself.  Also,
`mew-from-list' can be set automatically. For automatic setup, please
refer to *Note config::.

Typing `C-cTAB' anywhere on the value replaces the value with the next
value of `mew-from-list'. For example,

     From: Kazu Yamamoto <kazu@example.org>`C-cTAB'

becomes as follows:

     From: Kazuhiko Yamamoto <kazu@example.jp>



File: mew.info, Node: addr-comp, Next: addrbook, Prev: cheader, Up: Composing

Address Completion
==================

You can complete addresses on To: or Cc:. This completion command is
bound to `TAB'.

     To: kazu`TAB'

When you type `TAB' after a part of an address as the example above,
the entire address is completed as follows:

     To: kazu@example.org

There are three kinds of registered addresses to be used for the
completion.

  1. The expansion rule in an address book
  2. The personal information in the address book
  3. Learned addresses when sending

Mew provides two ways to complete addresses. You can select one of
them with `mew-use-full-alias', which is default to `nil'.

If `mew-use-full-alias' is `nil', the portion before `@', a user name
or a short name, is a target of the completion. When you type `TAB',
the user name is completed. And if the user name is uniquely completed
and you type `TAB' again, it is expanded to its entire address. Let's
call this Address Completion(1).

An advantage of Address Completion(1)(*Note addr-comp1::) is that you
can use the completion/expansion against the three kinds of addresses
seamlessly. You can also explicitly expand the user name with `TAB' as
described later. A disadvantage is that user names must be unique. So,
if a user name is already registered, other addresses with the same
user name cannot be learned.

If `mew-use-full-alias' is `t', for learned addresses when sending,
completion target is an entire address. Let's call this Address
Completion(2).

An advantage of Address Completion(2)(*Note addr-comp1::) is that Mew
can learn addresses whose user names are the same. One of
disadvantages is that only the first address of personal information
can be used (the other addresses are useless). And for the explicit
expansion, you have to type `M-C-e', a different key from
`TAB'.



