Go to the previous, next section.

Sending Messages

When sending messages from within VM, you will be using the standard Mail major mode provided with GNU Emacs. See section `Mail Mode' in the GNU Emacs Manual. However, `*mail*' buffers created by VM have extra command keys:

C-c C-y (vm-yank-message)
Copies a message from the current folder into the `*mail*' buffer. The message number is read from the minibuffer. By default each line of the copy is prepended with the value of the variable vm-included-text-prefix. All message headers are yanked along with the text. Point is left before the inserted text, the mark after. Any hook functions bound to mail-yank-hooks are run, after inserting the text and setting point and mark. If a prefix argument is given, this tells VM to ignore mail-yank-hooks, don't set the mark, don't prepend the value of vm-included-text-prefix to every yanked line, and don't yank any headers other than those specified in vm-visible-headers/vm-invisible-headers.
C-c y (vm-yank-message-other-folder)
Work like vm-yank-message, but it first prompts for the name of a folder from which to yank the message.
C-c C-v <Any VM command key>
All VM commands may be accessed in the `*mail*' buffer by prefixing them with C-c C-v.

The simplest command is m (vm-mail) which sends a mail message much as M-x mail does but allows the added commands described above.

vm-mail can be invoked outside of VM by typing M-x vm-mail. However, of the above commands, only C-c y (vm-yank-message-other-folder) will work; all the other commands require a parent folder.

If you send a message and it is returned by the mail system because it was undeliverable, you an easily resend the message by typing M-r (vm-resend-bounced-message). VM will extract the old message and its pertinent headers from the returned message, and place you in a `*mail*' buffer. You can then change the recipient addresses or do whatever is necessary to correct the original problem and resend the message.


VM has special commands that make it easy to reply to a message. When a reply command is invoked VM fills in the subject and recipient headers for you, since it is apparent to whom the message should be sent and what the subject should be. There is an old convention of prepending the string `"Re: "' to the subject of replies if the string isn't present already. VM supports this indirectly by providing the variable vm-reply-subject-prefix. Its value should be a string to prepend to the subject of replies, if the said string isn't present already. A nil value means don't prepend anything to the subject (this is the default). In any case you can edit any of the message headers manually, if you wish.

VM also helps you quote material from a message to which you are replying by providing included text as a feature of some of the commands. Included text is a copy of the message being replied to with some fixed string prepended to each line so that included text can be distinguished from the text of the reply. The variable vm-included-text-prefix specifies what the prepended string will be.

The variable vm-included-text-attribution-format specifies the format for the attribution of included text. This attribution is a line of text that tells who wrote the text that is to be included; it will be inserted before the included text. If non-nil, the value of vm-included-text-attribution-format should be a string format specification similar to vm-summary-format. See section Summaries. A nil value causes the attribution to be omitted.

The variable vm-in-reply-to-format specifies the format of the In-Reply-To header that is inserted into header section of the reply buffer. Like vm-included-text-attribution-format, vm-in-reply-to-format should be a string similar to that of vm-summary-format. A nil value causes the In-Reply-To header to be omitted.

The recipient headers generated for reply messages are created by simply copying the appropriate headers for the message to which you are replying. This includes any full name information, comments, etc. in these headers. If the variable vm-strip-reply-headers is non-nil, the reply headers will stripped of all information but the actual addresses.

The reply commands are:

r (vm-reply)
Replies to the author of the current message.
R (vm-reply-include-text)
Replies to the author of the current message and provides included text.
f (vm-followup)
Replies to the all recipients of the current message.
F (vm-followup-include-text)
Replies to the all recipients of the current message and provides included text.

These commands all accept a numeric prefix argument n, which if present, causes VM to reply to the next (or previous if the argument is negative) n-1 message as well as the current message. Also all the reply commands set the "replied" attribute of the messages to which you are responding, but only when the reply is actually sent. The reply commands can also be applied to marked messages, see section Message Marks.

If you are one of multiple recipients of a message and you use f and F, your address will be included in the recipients of the reply. You can avoid this by judicious use of the variable vm-reply-ignored-addresses. Its value should be a list of regular expressions that match addresses that VM should automatically remove from the recipient headers of replies.

Forwarding Messages

VM has two commands to forward messages: z (vm-forward-message) and @ (vm-send-digest).

Typing z puts you into a `*mail*' buffer just like m, except the current message appears as the body of the message in the `*mail*' buffer. The forwarded message is surrounded by RFC 934 compliant message delimiters. If the variable vm-rfc934-forwarding is non-nil "^-" to "- -" character stuffing is done to the forwarded message (this is the default). This behavior is required if the recipient of the forwarded message wants to use a RFC 934 standard bursting agent to access the message. If the variable vm-forwarding-subject-format is non-nil it should specify the format of the Subject header of the forwarded message. This subject will be used as the contents of the Subject header automatically inserted into the `*mail*' buffer. A nil value causes the Subject header to be left blank. The forwarded message is flagged "forwarded". The command @ (vm-send-digest) works like z except that a digest of all the messages in the current folder is made and inserted into the `*mail*' buffer. Also, vm-send-digest can be applied to marked messages. See section Message Marks. When applied to marked messages, vm-send-digest will only bundle marked messages, as opposed to the usual bundling of all messages in the current folder. If you give vm-send-digest a prefix argument, VM will insert a list of preamble lines at the beginning of the digest, one line per digestified message. The variable vm-digest-preamble-format determines the format of the preamble lines. If the value of vm-digest-center-preamble is non-nil, the preamble lines will be centered.

Go to the previous, next section.