emacs - GNU project Emacs
emacs [command-line switches] [file ...]
The GNU Emacs editor is a new version of Emacs, written by the author of the original (PDP-10) Emacs, Richard Stallman. It provides all the user capabilities of other Emacs editors, and it is easily extensible because its editing commands are written in Lisp.
The documentation for GNU Emacs is available online and can be viewed using Info, a subsystem of the Emacs facility. This documentation contains the most up-to-date and complete information. For the most part, users of other Emacs editors should have little trouble adapting without the documentation and new users should progress quickly with the basic features by studying the tutorial and using the self-documenting features of the Emacs facility.
The Emacs editor has an extensive interactive help facility, however, you must know how to manipulate Emacs windows and buffers to use it. To enter the Help facility, enter CTRL-h (backspace or CTRL-h) from with the Emacs facility. There are several help topics available: Help Tutorial (type CTRL-h t) provides an interactive tutorial that teaches beginners the fundamentals of the Emacs facility in a short time. Help Apropos (type CTRL-h a) is used to locate commands. Help Character (type Ctrl-h c) describes a specified character's effect. Help Function (type CTRL-h f) provides information on the specified Lisp function.
The Emacs editor's Undo command can be used to undo several steps of modification to your buffers, so it is easy to recover from editing mistakes.
facility also provides many other
features including special packages to handle reading (RMail) and sending
(Mail), outline editing (Outline), compiling (Compile), running subshells
windows (Shell), running a Lisp read-eval-print
loop (Lisp-Interaction-Mode) and more.
The following options are of general interest:
Specifies the file that you want to edit.
Moves to the line specified by
(Do not insert a space between the
sign and the number.)
Specifies that the
file is not to be loaded.
for the specified user.
Uses the specified file as the terminal instead of using standard
input and standard output. This must be the first argument specified in the
Use the following options to specify lisp functions and to load lisp
code into your files. These options are processed in the order they are specified:
Executes the specified Lisp function.
Loads the lisp code in specified file.
Use the following options to run
as a batch
Edits in batch mode. The editor sends messages to standard
output. This option must be the first in the argument list. Use the
options to specify the files to execute
and the functions to call.
facility while in batch
The Emacs facility has been tailored to work with the X window system. If you run the Emacs editor under X windows, it creates its own X window in which to display. Starting the editor as a background process (emacs &) is advisable because you can continue using your original window.
An Emacs session is started using following X switches: Specifies the program name which should be used when looking up defaults in the user's X resources. This must be the first option specified in the command line. Specifies the name which should be assigned to the Emacs window. Displays the Emacs window in reverse video. Uses the ``kitchen sink'' bitmap icon when iconifying the Emacs window. Sets the Emacs window's font to the font specified. There are various X fonts in the /usr/lib/X11/fonts directory.
Use the following options to specify the colors used in an
window on color displays only:
Sets the color of the text. See the file
for a list of valid color names.
Sets the color of the window's background.
Sets the color of the window's border.
Sets the color of the window's text cursor.
Sets the color of the window's mouse cursor.
Use the following options to specify how the
facility interacts with your
window on the specified
display. This must be the first option specified in the command line.
facility not to use its
special interface to X. If you use this switch when invoking the
facility from a
window, the display appears
in that window. This must be the first option specified in the command line.
Use the following format to set X default values for your Emacs windows in your .Xresources file (see xrdb(1X)): emacs.keyword:value
In the previous format example, value specifies the default value of the specified keyword. You can set the following default values for keywords: Sets the window's text font. Displays the window in reverse video if the reverseVideo's value is set to on. Turns the window into the ``kitchen sink'' icon if the bitmapIcon's value is set to on. Sets the window's border width in pixels. Sets the window's internal border width in pixels. Sets the window's text color (for color displays only). Sets the window's background color (for color displays only). Sets the color of the window's border (for color displays only). Sets the color of the window's text cursor (for color displays only). Sets the color of the window's mouse cursor (for color displays only). Sets the geometry of the Emacs window (as described above). Sets the title of the Emacs window. Sets the icon name for the Emacs window icon.
If specify color values when using a black and white display, the window's
characteristics change as follows:
Foreground color defaults to black
Background color defaults to white
Border color defaults to grey
Text and mouse cursors defaults to black
The following table lists the mouse button bindings for an Emacs window under X11:
|GNU Emacs Key Bindings for X Windows|
Hardocpy (postscript format) versions of the Emacs manuals are located in /usr/lib/emacs/doc.
To purchase printed copies of the GNU Emacs Manual contact the Free Software Foundation for information on pricing and ordering instructions. Their address follows:
Free Software Foundation 675 Mass Ave. Cambridge, MA 02139
All software and publications received from Free Software Foundation
can be copied and distributed without permission. The TeX source to the manual
is included in the source distribution.
facility was written by Richard Stallman
and the Free Software Foundation. Joachim Martillo and Robert Krawitz added
the X features.
The Emacs software and documentation is free. Anyone can distribute copies of the Emacs software and documentation using the terms stated in the Emacs General Public License. A copy of this license accompanies each distribution of the Emacs software, and it is also documented in the reference manual.
Copies of the Emacs software is often packaged with distributions of UNIX systems, but the scope of any licenses governing these systems does not include limiting the Emacs software and documentation in any manner. Such claims violate the terms under which the Emacs software is distributed. The primary purpose of the General Public License is to prohibit anyone from attaching restrictions to the distribution of the Emacs software and documentation.
Richard Stallman encourages you to improve and extend the
software and urges that you contribute your extensions to
the GNU library. Eventually,
(GNU's Not UNIX) is intended
to be a complete replacement for Berkeley UNIX. All persons will be able
to use the GNU system for free.
Contains files for the
documentation browser, a subsystem of the
Although not much UNIX documentation is included in this library, the Emacs
reference manual is included in a convenient tree structure.
Contains Lisp source files and compiled files that define
most editing commands. Some are preloaded; others are autoloaded from this
directory when used.
Contains various programs that are used with GNU Emacs, and
some files of information.
Contains the documentation strings for the Lisp primitives
and preloaded Lisp functions of GNU Emacs. They are stored here to reduce
the size of
Holds lock files that are made for all files that are modified
facility. These files prevent simultaneous
modifications of one file by two users.
Lists valid X color names.
Commands: X(1X), xlsfonts(1X), xrdb(1X), xterm(1X)