Linux

  1. Home
  2. Computing & Technology
  3. Linux

Header Editing

Emacs Documentation

By Juergen Haas, About.com

Mail Header Editing

Mail mode provides special commands to move to particular header fields and to complete addresses in headers.

  • C-c C-f C-t
    Move to the To header field, creating one if there is none (mail-to).
  • C-c C-f C-s
    Move to the Subject header field, creating one if there is none (mail-subject).
  • C-c C-f C-c
    Move to the CC header field, creating one if there is none (mail-cc).
  • C-c C-f C-b
    Move to the BCC header field, creating one if there is none (mail-bcc).
  • C-c C-f C-f
    Move to the FCC header field, creating one if there is none (mail-fcc).
  • M-<TAB>
    Complete a mailing address (mail-complete).

There are five commands to move point to particular header fields, all based on the prefix C-c C-f (C-f is for "field"). They are listed in the table above. If the field in question does not exist, these commands create one. We provide special motion commands for these particular fields because they are the fields users most often want to edit.

While editing a header field that contains mailing addresses, such as To:, CC: and BCC:, you can complete a mailing address by typing M-<TAB> (mail-complete). It inserts the full name corresponding to the address, if it can determine the full name. The variable mail-complete-style controls whether to insert the full name, and what style to use, as in mail-from-style (see Mail Headers).

For completion purposes, the valid mailing addresses are taken to be the local users' names plus your personal mail aliases. You can specify additional sources of valid addresses; look at the customization group mailalias to see the options for this (see Customization Groups).

If you type M-<TAB> in the body of the message, mail-complete invokes ispell-complete-word, as in Text mode.

* Emacs Manual Index

Explore Linux

About.com Special Features

Build Your Own Website

Step-by-step advice on how to do everything from choosing a Web host to promoting your content. More >

Connect Your Home Computers

Easy ways to connect two computers for networking purposes. More >

Linux

  1. Home
  2. Computing & Technology
  3. Linux
  4. Linux Software
  5. Editors
  6. Emacs
  7. Emacs Documentation - Header Editing

©2009 About.com, a part of The New York Times Company.

All rights reserved.