3 @setfilename ../info/emacs
4 @settitle GNU Emacs Manual
6 @c The edition number appears in several places in this file
7 @set EDITION Fourteenth
11 This is the @value{EDITION} edition of the @cite{GNU Emacs Manual},
12 updated for Emacs version @value{EMACSVER}.
14 Copyright @copyright{} 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997,
15 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software
19 Permission is granted to copy, distribute and/or modify this document
20 under the terms of the GNU Free Documentation License, Version 1.2 or
21 any later version published by the Free Software Foundation; with the
22 Invariant Sections being ``The GNU Manifesto'', ``Distribution'' and
23 ``GNU GENERAL PUBLIC LICENSE'', with the Front-Cover texts being ``A GNU
24 Manual,'' and with the Back-Cover Texts as in (a) below. A copy of the
25 license is included in the section entitled ``GNU Free Documentation
28 (a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify
29 this GNU Manual, like GNU software. Copies published by the Free
30 Software Foundation raise funds for GNU development.''
36 * Emacs: (emacs). The extensible self-documenting text editor.
39 @c in general, keep the following line commented out, unless doing a
40 @c copy of this manual that will be published. the manual should go
41 @c onto the distribution in the full, 8.5 x 11" size.
45 @setchapternewpage odd
52 @shorttitlepage GNU Emacs Manual
57 @center @titlefont{GNU Emacs Manual}
59 @center @value{EDITION} Edition, Updated for Emacs Version @value{EMACSVER}.
61 @center Richard Stallman
63 @vskip 0pt plus 1filll
68 Published by the Free Software Foundation @*
69 51 Franklin Street, Fifth Floor @*
70 Boston, MA 02110-1301 USA
73 Cover art by Etienne Suvasa.
83 @node Top, Distrib, (dir), (dir)
86 Emacs is the extensible, customizable, self-documenting real-time
87 display editor. This Info file describes how to edit with Emacs and
88 some of how to customize it; it corresponds to GNU Emacs version
92 If you never before used the Info documentation system, type @kbd{h},
93 and Emacs will take you to a programmed instruction sequence for the
97 For information on extending Emacs, see @ref{Top, Emacs Lisp,, elisp, The
98 Emacs Lisp Reference Manual}.
102 These subcategories have been deleted for simplicity
103 and to avoid conflicts.
106 Auto-Saving: Protection Against Disasters
112 Shell Command History
114 The ones for Dired and Rmail have had the items turned into :: items
116 Also Running Shell Commands from Emacs
117 and Sending Mail and Registers and Minibuffer.
121 * Distrib:: How to get the latest Emacs distribution.
122 * Copying:: The GNU General Public License gives you permission
123 to redistribute GNU Emacs on certain terms;
124 it also explains that there is no warranty.
125 * GNU Free Documentation License:: The license for this documentation.
126 * Intro:: An introduction to Emacs concepts.
127 * Glossary:: The glossary.
128 * Antinews:: Information about Emacs version 21.
129 * Mac OS:: Using Emacs in the Mac.
130 * Emacs and Microsoft Windows:: Using Emacs on Microsoft Windows.
131 * Manifesto:: What's GNU? Gnu's Not Unix!
132 * Acknowledgments:: Major contributors to GNU Emacs.
134 Indexes (nodes containing large menus)
135 * Key Index:: An item for each standard Emacs key sequence.
136 * Option Index:: An item for every command-line option.
137 * Command Index:: An item for each command name.
138 * Variable Index:: An item for each documented variable.
139 * Concept Index:: An item for each concept.
141 Important General Concepts
142 * Screen:: How to interpret what you see on the screen.
143 * User Input:: Kinds of input events (characters, buttons,
145 * Keys:: Key sequences: what you type to request one
147 * Commands:: Named functions run by key sequences to do editing.
148 * Text Characters:: Character set for text (the contents of buffers
150 * Entering Emacs:: Starting Emacs from the shell.
151 * Exiting:: Stopping or killing Emacs.
152 * Emacs Invocation:: Hairy startup options.
154 Fundamental Editing Commands
155 * Basic:: The most basic editing commands.
156 * Minibuffer:: Entering arguments that are prompted for.
157 * M-x:: Invoking commands by their names.
158 * Help:: Commands for asking Emacs about its commands.
160 Important Text-Changing Commands
161 * Mark:: The mark: how to delimit a ``region'' of text.
162 * Killing:: Killing (cutting) text.
163 * Yanking:: Recovering killed text. Moving text. (Pasting.)
164 * Accumulating Text:: Other ways of copying text.
165 * Rectangles:: Operating on the text inside a rectangle on the screen.
166 * Registers:: Saving a text string or a location in the buffer.
167 * Display:: Controlling what text is displayed.
168 * Search:: Finding or replacing occurrences of a string.
169 * Fixit:: Commands especially useful for fixing typos.
170 * Keyboard Macros:: A keyboard macro records a sequence of
171 keystrokes to be replayed with a single command.
173 Major Structures of Emacs
174 * Files:: All about handling files.
175 * Buffers:: Multiple buffers; editing several files at once.
176 * Windows:: Viewing two pieces of text at once.
177 * Frames:: Running the same Emacs session in multiple X windows.
178 * International:: Using non-@acronym{ASCII} character sets (the MULE features).
181 * Major Modes:: Text mode vs. Lisp mode vs. C mode ...
182 * Indentation:: Editing the white space at the beginnings of lines.
183 * Text:: Commands and modes for editing English.
184 * Programs:: Commands and modes for editing programs.
185 * Building:: Compiling, running and debugging programs.
186 * Maintaining:: Features for maintaining large programs.
187 * Abbrevs:: How to define text abbreviations to reduce
188 the number of characters you must type.
189 * Sending Mail:: Sending mail in Emacs.
190 * Rmail:: Reading mail in Emacs.
191 * Dired:: You can ``edit'' a directory to manage files in it.
192 * Calendar/Diary:: The calendar and diary facilities.
193 * Gnus:: How to read netnews with Emacs.
194 * Shell:: Executing shell commands from Emacs.
195 * Emacs Server:: Using Emacs as an editing server for @code{mail}, etc.
196 * Printing:: Printing hardcopies of buffers or regions.
197 * Sorting:: Sorting lines, paragraphs or pages within Emacs.
198 * Narrowing:: Restricting display and editing to a portion
200 * Two-Column:: Splitting apart columns to edit them
201 in side-by-side windows.
202 * Editing Binary Files::Using Hexl mode to edit binary files.
203 * Saving Emacs Sessions:: Saving Emacs state from one session to the next.
204 * Recursive Edit:: A command can allow you to do editing
205 "within the command". This is called a
206 "recursive editing level".
207 * Emulation:: Emulating some other editors with Emacs.
208 * Hyperlinking:: Following links in buffers.
209 * Thumbnails:: Browsing images using thumbnails.
210 * Dissociated Press:: Dissociating text for fun.
211 * Amusements:: Various games and hacks.
212 * Customization:: Modifying the behavior of Emacs.
213 * X Resources:: X resources for customizing Emacs.
215 Recovery from Problems
216 * Quitting:: Quitting and aborting.
217 * Lossage:: What to do if Emacs is hung or malfunctioning.
218 * Bugs:: How and when to report a bug.
219 * Contributing:: How to contribute improvements to Emacs.
220 * Service:: How to get help for your own Emacs needs.
222 Detailed Node Listing
223 ---------------------
225 Here are some other nodes which are really inferiors of the ones
226 already listed, mentioned here so you can get to them in one step:
228 The Organization of the Screen
230 * Point:: The place in the text where editing commands operate.
231 * Echo Area:: Short messages appear at the bottom of the screen.
232 * Mode Line:: Interpreting the mode line.
233 * Menu Bar:: How to use the menu bar.
235 Basic Editing Commands
237 * Inserting Text:: Inserting text by simply typing it.
238 * Moving Point:: How to move the cursor to the place where you want to
240 * Erasing:: Deleting and killing text.
241 * Basic Undo:: Undoing recent changes in the text.
242 * Basic Files:: Visiting, creating, and saving files.
243 * Basic Help:: Asking what a character does.
244 * Blank Lines:: Commands to make or delete blank lines.
245 * Continuation Lines:: Lines too wide for the screen.
246 * Position Info:: What page, line, row, or column is point on?
247 * Arguments:: Numeric arguments for repeating a command.
248 * Repeating:: A short-cut for repeating the previous command.
252 * Minibuffer File:: Entering file names with the minibuffer.
253 * Minibuffer Edit:: How to edit in the minibuffer.
254 * Completion:: An abbreviation facility for minibuffer input.
255 * Minibuffer History:: Reusing recent minibuffer arguments.
256 * Repetition:: Re-executing commands that used the minibuffer.
260 * Help Summary:: Brief list of all Help commands.
261 * Key Help:: Asking what a key does in Emacs.
262 * Name Help:: Asking about a command, variable or function name.
263 * Apropos:: Asking what pertains to a given topic.
264 * Library Keywords:: Finding Lisp libraries by keywords (topics).
265 * Language Help:: Help relating to international language support.
266 * Help Mode:: Special features of Help mode and Help buffers.
267 * Misc Help:: Other help commands.
268 * Help Files:: Commands to display pre-written help files.
269 * Help Echo:: Help on active text and tooltips (`balloon help')
271 The Mark and the Region
273 * Setting Mark:: Commands to set the mark.
274 * Transient Mark:: How to make Emacs highlight the region--
276 * Momentary Mark:: Enabling Transient Mark mode momentarily.
277 * Using Region:: Summary of ways to operate on contents of the region.
278 * Marking Objects:: Commands to put region around textual units.
279 * Mark Ring:: Previous mark positions saved so you can go back there.
280 * Global Mark Ring:: Previous mark positions in various buffers.
282 Killing and Moving Text
284 * Deletion:: Commands for deleting small amounts of text and
286 * Killing by Lines:: How to kill entire lines of text at one time.
287 * Other Kill Commands:: Commands to kill large regions of text and
288 syntactic units such as words and sentences.
289 * Graphical Kill:: The kill ring on graphical terminals:
290 yanking between applications.
291 * CUA Bindings:: Using @kbd{C-x}, @kbd{C-c}, @kbd{C-v} for copy
292 and paste, with enhanced rectangle support.
296 * Kill Ring:: Where killed text is stored. Basic yanking.
297 * Appending Kills:: Several kills in a row all yank together.
298 * Earlier Kills:: Yanking something killed some time ago.
302 * RegPos:: Saving positions in registers.
303 * RegText:: Saving text in registers.
304 * RegRect:: Saving rectangles in registers.
305 * RegConfig:: Saving window configurations in registers.
306 * RegNumbers:: Numbers in registers.
307 * RegFiles:: File names in registers.
308 * Bookmarks:: Bookmarks are like registers, but persistent.
310 Controlling the Display
312 * Scrolling:: Moving text up and down in a window.
313 * Horizontal Scrolling:: Moving text left and right in a window.
314 * Follow Mode:: Follow mode lets two windows scroll as one.
315 * Faces:: How to change the display style using faces.
316 * Standard Faces:: Emacs' predefined faces.
317 * Font Lock:: Minor mode for syntactic highlighting using faces.
318 * Highlight Interactively:: Tell Emacs what text to highlight.
319 * Fringes:: Enabling or disabling window fringes.
320 * Useless Whitespace:: Showing possibly-spurious trailing whitespace.
321 * Selective Display:: Hiding lines with lots of indentation.
322 * Optional Mode Line:: Optional mode line display features.
323 * Text Display:: How text characters are normally displayed.
324 * Cursor Display:: Features for displaying the cursor.
325 * Display Custom:: Information on variables for customizing display.
327 Searching and Replacement
329 * Incremental Search:: Search happens as you type the string.
330 * Nonincremental Search:: Specify entire string and then search.
331 * Word Search:: Search for sequence of words.
332 * Regexp Search:: Search for match for a regexp.
333 * Regexps:: Syntax of regular expressions.
334 * Search Case:: To ignore case while searching, or not.
335 * Replace:: Search, and replace some or all matches.
336 * Other Repeating Search:: Operating on all matches for some regexp.
340 * Unconditional Replace:: Replacing all matches for a string.
341 * Regexp Replace:: Replacing all matches for a regexp.
342 * Replacement and Case:: How replacements preserve case of letters.
343 * Query Replace:: How to use querying.
345 Commands for Fixing Typos
347 * Undo:: Full details of Emacs undo commands.
348 * Kill Errors:: Commands to kill a batch of recently entered text.
349 * Transpose:: Exchanging two characters, words, lines, lists...
350 * Fixing Case:: Correcting case of last word entered.
351 * Spelling:: Apply spelling checker to a word or a whole buffer.
355 * Basic Keyboard Macro:: Defining and running keyboard macros.
356 * Keyboard Macro Ring:: Where previous keyboard macros are saved.
357 * Keyboard Macro Counter:: Inserting incrementing numbers in macros.
358 * Keyboard Macro Query:: Making keyboard macros do different things each time.
359 * Save Keyboard Macro:: Giving keyboard macros names; saving them in files.
360 * Edit Keyboard Macro:: Editing keyboard macros.
361 * Keyboard Macro Step-Edit:: Interactively executing and editing a keyboard
366 * File Names:: How to type and edit file-name arguments.
367 * Visiting:: Visiting a file prepares Emacs to edit the file.
368 * Saving:: Saving makes your changes permanent.
369 * Reverting:: Reverting cancels all the changes not saved.
370 * Auto Save:: Auto Save periodically protects against loss of data.
371 * File Aliases:: Handling multiple names for one file.
372 * Version Control:: Version control systems (RCS, CVS and SCCS).
373 * Directories:: Creating, deleting, and listing file directories.
374 * Comparing Files:: Finding where two files differ.
375 * Misc File Ops:: Other things you can do on files.
376 * Compressed Files:: Accessing compressed files.
377 * File Archives:: Operating on tar, zip, jar etc. archive files.
378 * Remote Files:: Accessing files on other sites.
379 * Quoted File Names:: Quoting special characters in file names.
380 * File Name Cache:: Completion against a list of files you often use.
381 * File Conveniences:: Convenience Features for Finding Files.
382 * Filesets:: Handling sets of files.
386 * Save Commands:: Commands for saving files.
387 * Backup:: How Emacs saves the old version of your file.
388 * Customize Save:: Customizing the saving of files.
389 * Interlocking:: How Emacs protects against simultaneous editing
390 of one file by two users.
391 * File Shadowing:: Copying files to "shadows" automatically.
392 * Time Stamps:: Emacs can update time stamps on saved files.
396 * Introduction to VC:: How version control works in general.
397 * VC Mode Line:: How the mode line shows version control status.
398 * Basic VC Editing:: How to edit a file under version control.
399 * Old Versions:: Examining and comparing old versions.
400 * Secondary VC Commands:: The commands used a little less frequently.
401 * Branches:: Multiple lines of development.
403 Using Multiple Buffers
405 * Select Buffer:: Creating a new buffer or reselecting an old one.
406 * List Buffers:: Getting a list of buffers that exist.
407 * Misc Buffer:: Renaming; changing read-onliness; copying text.
408 * Kill Buffer:: Killing buffers you no longer need.
409 * Several Buffers:: How to go through the list of all buffers
410 and operate variously on several of them.
411 * Indirect Buffers:: An indirect buffer shares the text of another buffer.
412 * Buffer Convenience:: Convenience and customization features for
417 * Basic Window:: Introduction to Emacs windows.
418 * Split Window:: New windows are made by splitting existing windows.
419 * Other Window:: Moving to another window or doing something to it.
420 * Pop Up Window:: Finding a file or buffer in another window.
421 * Force Same Window:: Forcing certain buffers to appear in the selected
422 window rather than in another window.
423 * Change Window:: Deleting windows and changing their sizes.
424 * Window Convenience:: Convenience functions for window handling.
428 * Mouse Commands:: Moving, cutting, and pasting, with the mouse.
429 * Secondary Selection:: Cutting without altering point and mark.
430 * Clipboard:: Using the clipboard for selections.
431 * Mouse References:: Using the mouse to select an item from a list.
432 * Menu Mouse Clicks:: Mouse clicks that bring up menus.
433 * Mode Line Mouse:: Mouse clicks on the mode line.
434 * Creating Frames:: Creating additional Emacs frames with various contents.
435 * Frame Commands:: Iconifying, deleting, and switching frames.
436 * Speedbar:: How to make and use a speedbar frame.
437 * Multiple Displays:: How one Emacs job can talk to several displays.
438 * Special Buffer Frames:: You can make certain buffers have their own frames.
439 * Frame Parameters:: Changing the colors and other modes of frames.
440 * Scroll Bars:: How to enable and disable scroll bars; how to use them.
441 * Wheeled Mice:: Using mouse wheels for scrolling.
442 * Drag and Drop:: Using drag and drop to open files and insert text.
443 * Menu Bars:: Enabling and disabling the menu bar.
444 * Tool Bars:: Enabling and disabling the tool bar.
445 * Dialog Boxes:: Controlling use of dialog boxes.
446 * Tooltips:: Showing "tooltips", AKA "balloon help" for active text.
447 * Mouse Avoidance:: Moving the mouse pointer out of the way.
448 * Non-Window Terminals:: Multiple frames on terminals that show only one.
449 * XTerm Mouse:: Using the mouse in an XTerm terminal emulator.
451 International Character Set Support
453 * International Chars:: Basic concepts of multibyte characters.
454 * Enabling Multibyte:: Controlling whether to use multibyte characters.
455 * Language Environments:: Setting things up for the language you use.
456 * Input Methods:: Entering text characters not on your keyboard.
457 * Select Input Method:: Specifying your choice of input methods.
458 * Multibyte Conversion:: How single-byte characters convert to multibyte.
459 * Coding Systems:: Character set conversion when you read and
460 write files, and so on.
461 * Recognize Coding:: How Emacs figures out which conversion to use.
462 * Text Coding:: Choosing conversion to use for file text.
463 * Communication Coding:: Coding systems for interprocess communication.
464 * File Name Coding:: Coding systems for file @emph{names}.
465 * Terminal Coding:: Specifying coding systems for converting
466 terminal input and output.
467 * Fontsets:: Fontsets are collections of fonts
468 that cover the whole spectrum of characters.
469 * Defining Fontsets:: Defining a new fontset.
470 * Undisplayable Characters::When characters don't display.
471 * Unibyte Mode:: You can pick one European character set
472 to use without multibyte characters.
473 * Charsets:: How Emacs groups its internal character codes.
477 * Choosing Modes:: How major modes are specified or chosen.
481 * Indentation Commands:: Various commands and techniques for indentation.
482 * Tab Stops:: You can set arbitrary "tab stops" and then
483 indent to the next tab stop when you want to.
484 * Just Spaces:: You can request indentation using just spaces.
486 Commands for Human Languages
488 * Words:: Moving over and killing words.
489 * Sentences:: Moving over and killing sentences.
490 * Paragraphs:: Moving over paragraphs.
491 * Pages:: Moving over pages.
492 * Filling:: Filling or justifying text.
493 * Case:: Changing the case of text.
494 * Text Mode:: The major modes for editing text files.
495 * Outline Mode:: Editing outlines.
496 * TeX Mode:: Editing input to the formatter TeX.
497 * HTML Mode:: Editing HTML, SGML, and XML files.
498 * Nroff Mode:: Editing input to the formatter nroff.
499 * Formatted Text:: Editing formatted text directly in WYSIWYG fashion.
500 * Text Based Tables:: Editing text-based tables in WYSIWYG fashion.
504 * Auto Fill:: Auto Fill mode breaks long lines automatically.
505 * Refill:: Keeping paragraphs filled.
506 * Fill Commands:: Commands to refill paragraphs and center lines.
507 * Fill Prefix:: Filling paragraphs that are indented
508 or in a comment, etc.
509 * Adaptive Fill:: How Emacs can determine the fill prefix automatically.
510 * Longlines:: Editing text with very long lines.
514 * Program Modes:: Major modes for editing programs.
515 * Defuns:: Commands to operate on major top-level parts
517 * Program Indent:: Adjusting indentation to show the nesting.
518 * Parentheses:: Commands that operate on parentheses.
519 * Comments:: Inserting, killing, and aligning comments.
520 * Documentation:: Getting documentation of functions you plan to call.
521 * Hideshow:: Displaying blocks selectively.
522 * Symbol Completion:: Completion on symbol names of your program or language.
523 * Glasses:: Making identifiersLikeThis more readable.
524 * Misc for Programs:: Other Emacs features useful for editing programs.
525 * C Modes:: Special commands of C, C++, Objective-C,
526 Java, and Pike modes.
527 * Asm Mode:: Asm mode and its special features.
529 Top-Level Definitions, or Defuns
531 * Left Margin Paren:: An open-paren or similar opening delimiter
532 starts a defun if it is at the left margin.
533 * Moving by Defuns:: Commands to move over or mark a major definition.
534 * Imenu:: Making buffer indexes as menus.
535 * Which Function:: Which Function mode shows which function you are in.
537 Indentation for Programs
539 * Basic Indent:: Indenting a single line.
540 * Multi-line Indent:: Commands to reindent many lines at once.
541 * Lisp Indent:: Specifying how each Lisp function should be indented.
542 * C Indent:: Extra features for indenting C and related modes.
543 * Custom C Indent:: Controlling indentation style for C and related modes.
545 Commands for Editing with Parentheses
547 * Expressions:: Expressions with balanced parentheses.
548 * Moving by Parens:: Commands for moving up, down and across
549 in the structure of parentheses.
550 * Matching:: Insertion of a close-delimiter flashes matching open.
552 Manipulating Comments
554 * Comment Commands:: Inserting, killing, and indenting comments.
555 * Multi-Line Comments:: Commands for adding and editing multi-line comments.
556 * Options for Comments::Customizing the comment features.
560 * Info Lookup:: Looking up library functions and commands
562 * Man Page:: Looking up man pages of library functions and commands.
563 * Lisp Doc:: Looking up Emacs Lisp functions, etc.
567 * Motion in C:: Commands to move by C statements, etc.
568 * Electric C:: Colon and other chars can automatically reindent.
569 * Hungry Delete:: A more powerful DEL command.
570 * Other C Commands:: Filling comments, viewing expansion of macros,
571 and other neat features.
573 Compiling and Testing Programs
575 * Compilation:: Compiling programs in languages other
576 than Lisp (C, Pascal, etc.).
577 * Compilation Mode:: The mode for visiting compiler errors.
578 * Compilation Shell:: Customizing your shell properly
579 for use in the compilation buffer.
580 * Grep Searching:: Searching with grep.
581 * Flymake:: Finding syntax errors on the fly.
582 * Debuggers:: Running symbolic debuggers for non-Lisp programs.
583 * Executing Lisp:: Various modes for editing Lisp programs,
584 with different facilities for running
586 * Lisp Libraries:: Creating Lisp programs to run in Emacs.
587 * Lisp Eval:: Executing a single Lisp expression in Emacs.
588 * Lisp Interaction:: Executing Lisp in an Emacs buffer.
589 * External Lisp:: Communicating through Emacs with a separate Lisp.
591 Running Debuggers Under Emacs
593 * Starting GUD:: How to start a debugger subprocess.
594 * Debugger Operation:: Connection between the debugger and source buffers.
595 * Commands of GUD:: Key bindings for common commands.
596 * GUD Customization:: Defining your own commands for GUD.
597 * GDB Graphical Interface:: An enhanced mode that uses GDB features to
598 implement a graphical debugging environment through
601 Maintaining Large Programs
603 * Change Log:: Maintaining a change history for your program.
604 * Format of ChangeLog:: What the change log file looks like.
605 * Tags:: Go direct to any function in your program in one
606 command. Tags remembers which file it is in.
610 * Tag Syntax:: Tag syntax for various types of code and text files.
611 * Create Tags Table:: Creating a tags table with @code{etags}.
612 * Etags Regexps:: Create arbitrary tags using regular expressions.
613 * Select Tags Table:: How to visit a tags table.
614 * Find Tag:: Commands to find the definition of a specific tag.
615 * Tags Search:: Using a tags table for searching and replacing.
616 * List Tags:: Listing and finding tags defined in a file.
620 * Abbrev Concepts:: Fundamentals of defined abbrevs.
621 * Defining Abbrevs:: Defining an abbrev, so it will expand when typed.
622 * Expanding Abbrevs:: Controlling expansion: prefixes, canceling expansion.
623 * Editing Abbrevs:: Viewing or editing the entire list of defined abbrevs.
624 * Saving Abbrevs:: Saving the entire list of abbrevs for another session.
625 * Dynamic Abbrevs:: Abbreviations for words already in the buffer.
626 * Dabbrev Customization:: What is a word, for dynamic abbrevs. Case handling.
630 * Mail Format:: Format of the mail being composed.
631 * Mail Headers:: Details of permitted mail header fields.
632 * Mail Aliases:: Abbreviating and grouping mail addresses.
633 * Mail Mode:: Special commands for editing mail being composed.
634 * Mail Amusements:: Distract the NSA's attention; add a fortune to a msg.
635 * Mail Methods:: Using alternative mail-composition methods.
637 Reading Mail with Rmail
639 * Rmail Basics:: Basic concepts of Rmail, and simple use.
640 * Rmail Scrolling:: Scrolling through a message.
641 * Rmail Motion:: Moving to another message.
642 * Rmail Deletion:: Deleting and expunging messages.
643 * Rmail Inbox:: How mail gets into the Rmail file.
644 * Rmail Files:: Using multiple Rmail files.
645 * Rmail Output:: Copying message out to files.
646 * Rmail Labels:: Classifying messages by labeling them.
647 * Rmail Attributes:: Certain standard labels, called attributes.
648 * Rmail Reply:: Sending replies to messages you are viewing.
649 * Rmail Summary:: Summaries show brief info on many messages.
650 * Rmail Sorting:: Sorting messages in Rmail.
651 * Rmail Display:: How Rmail displays a message; customization.
652 * Rmail Coding:: How Rmail handles decoding character sets.
653 * Rmail Editing:: Editing message text and headers in Rmail.
654 * Rmail Digest:: Extracting the messages from a digest message.
655 * Out of Rmail:: Converting an Rmail file to mailbox format.
656 * Rmail Rot13:: Reading messages encoded in the rot13 code.
657 * Movemail:: More details of fetching new mail.
658 * Remote Mailboxes:: Retrieving Mail from Remote Mailboxes.
659 * Other Mailbox Formats:: Retrieving Mail from Local Mailboxes in
662 Dired, the Directory Editor
664 * Dired Enter:: How to invoke Dired.
665 * Dired Navigation:: How to move in the Dired buffer.
666 * Dired Deletion:: Deleting files with Dired.
667 * Flagging Many Files:: Flagging files based on their names.
668 * Dired Visiting:: Other file operations through Dired.
669 * Marks vs Flags:: Flagging for deletion vs marking.
670 * Operating on Files:: How to copy, rename, print, compress, etc.
671 either one file or several files.
672 * Shell Commands in Dired:: Running a shell command on the marked files.
673 * Transforming File Names:: Using patterns to rename multiple files.
674 * Comparison in Dired:: Running `diff' by way of Dired.
675 * Subdirectories in Dired:: Adding subdirectories to the Dired buffer.
676 * Subdirectory Motion:: Moving across subdirectories, and up and down.
677 * Hiding Subdirectories:: Making subdirectories visible or invisible.
678 * Dired Updating:: Discarding lines for files of no interest.
679 * Dired and Find:: Using `find' to choose the files for Dired.
680 * Wdired:: Operating on files by editing the Dired buffer.
681 * Misc Dired Features:: Various other features.
683 The Calendar and the Diary
685 * Calendar Motion:: Moving through the calendar; selecting a date.
686 * Scroll Calendar:: Bringing earlier or later months onto the screen.
687 * Counting Days:: How many days are there between two dates?
688 * General Calendar:: Exiting or recomputing the calendar.
689 * LaTeX Calendar:: Print a calendar using LaTeX.
690 * Holidays:: Displaying dates of holidays.
691 * Sunrise/Sunset:: Displaying local times of sunrise and sunset.
692 * Lunar Phases:: Displaying phases of the moon.
693 * Other Calendars:: Converting dates to other calendar systems.
694 * Diary:: Displaying events from your diary.
695 * Appointments:: Reminders when it's time to do something.
696 * Importing Diary:: Converting diary events to/from other formats.
697 * Daylight Savings:: How to specify when daylight savings time is active.
698 * Time Intervals:: Keeping track of time intervals.
700 Movement in the Calendar
702 * Calendar Unit Motion:: Moving by days, weeks, months, and years.
703 * Move to Beginning or End:: Moving to start/end of weeks, months, and years.
704 * Specified Dates:: Moving to the current date or another
707 Conversion To and From Other Calendars
709 * Calendar Systems:: The calendars Emacs understands
710 (aside from Gregorian).
711 * To Other Calendar:: Converting the selected date to various calendars.
712 * From Other Calendar:: Moving to a date specified in another calendar.
713 * Mayan Calendar:: Moving to a date specified in a Mayan calendar.
717 * Displaying the Diary:: Viewing diary entries and associated calendar dates.
718 * Format of Diary File:: Entering events in your diary.
719 * Date Formats:: Various ways you can specify dates.
720 * Adding to Diary:: Commands to create diary entries.
721 * Special Diary Entries:: Anniversaries, blocks of dates, cyclic entries, etc.
725 * Buffers of Gnus:: The group, summary, and article buffers.
726 * Gnus Startup:: What you should know about starting Gnus.
727 * Summary of Gnus:: A short description of the basic Gnus commands.
729 Running Shell Commands from Emacs
731 * Single Shell:: How to run one shell command and return.
732 * Interactive Shell:: Permanent shell taking input via Emacs.
733 * Shell Mode:: Special Emacs commands used with permanent shell.
734 * Shell Prompts:: Two ways to recognize shell prompts.
735 * Shell History:: Repeating previous commands in a shell buffer.
736 * Directory Tracking:: Keeping track when the subshell changes directory.
737 * Shell Options:: Options for customizing Shell mode.
738 * Terminal emulator:: An Emacs window as a terminal emulator.
739 * Term Mode:: Special Emacs commands used in Term mode.
740 * Paging in Term:: Paging in the terminal emulator.
741 * Remote Host:: Connecting to another computer.
743 Using Emacs as a Server
745 * Invoking emacsclient:: Emacs client startup options.
747 Hyperlinking and Navigation Features
749 * Browse-URL:: Following URLs.
750 * Goto-address:: Activating URLs.
751 * FFAP:: Finding files etc. at point.
755 * Minor Modes:: Each minor mode is one feature you can turn on
756 independently of any others.
757 * Easy Customization:: Convenient way to browse and change user options.
758 * Variables:: Many Emacs commands examine Emacs variables
759 to decide what to do; by setting variables,
760 you can control their functioning.
761 * Key Bindings:: The keymaps say what command each key runs.
762 By changing them, you can "redefine keys".
763 * Syntax:: The syntax table controls how words and
764 expressions are parsed.
765 * Init File:: How to write common customizations in the
770 * Examining:: Examining or setting one variable's value.
771 * Hooks:: Hook variables let you specify programs for parts
772 of Emacs to run on particular occasions.
773 * Locals:: Per-buffer values of variables.
774 * File Variables:: How files can specify variable values.
776 Customizing Key Bindings
778 * Keymaps:: Generalities. The global keymap.
779 * Prefix Keymaps:: Keymaps for prefix keys.
780 * Local Keymaps:: Major and minor modes have their own keymaps.
781 * Minibuffer Maps:: The minibuffer uses its own local keymaps.
782 * Rebinding:: How to redefine one key's meaning conveniently.
783 * Init Rebinding:: Rebinding keys with your init file, @file{.emacs}.
784 * Function Keys:: Rebinding terminal function keys.
785 * Named ASCII Chars:: Distinguishing @key{TAB} from @kbd{C-i}, and so on.
786 * Non-ASCII Rebinding:: Rebinding non-@acronym{ASCII} characters such as Latin-1.
787 * Mouse Buttons:: Rebinding mouse buttons in Emacs.
788 * Disabling:: Disabling a command means confirmation is required
789 before it can be executed. This is done to protect
790 beginners from surprises.
792 The Init File, @file{~/.emacs}
794 * Init Syntax:: Syntax of constants in Emacs Lisp.
795 * Init Examples:: How to do some things with an init file.
796 * Terminal Init:: Each terminal type can have an init file.
797 * Find Init:: How Emacs finds the init file.
799 Dealing with Emacs Trouble
801 * DEL Does Not Delete:: What to do if @key{DEL} doesn't delete.
802 * Stuck Recursive:: `[...]' in mode line around the parentheses.
803 * Screen Garbled:: Garbage on the screen.
804 * Text Garbled:: Garbage in the text.
805 * Memory Full:: How to cope when you run out of memory.
806 * After a Crash:: Recovering editing in an Emacs session that crashed.
807 * Emergency Escape:: Emergency escape---
808 What to do if Emacs stops responding.
809 * Total Frustration:: When you are at your wits' end.
813 * Bug Criteria:: Have you really found a bug?
814 * Understanding Bug Reporting:: How to report a bug effectively.
815 * Checklist:: Steps to follow for a good bug report.
816 * Sending Patches:: How to send a patch for GNU Emacs.
818 Command Line Arguments for Emacs Invocation
820 * Action Arguments:: Arguments to visit files, load libraries,
822 * Initial Options:: Arguments that take effect while starting Emacs.
823 * Command Example:: Examples of using command line arguments.
824 * Resume Arguments:: Specifying arguments when you resume a running Emacs.
825 * Environment:: Environment variables that Emacs uses.
826 * Display X:: Changing the default display and using remote login.
827 * Font X:: Choosing a font for text, under X.
828 * Colors:: Choosing display colors.
829 * Window Size X:: Start-up window size, under X.
830 * Borders X:: Internal and external borders, under X.
831 * Title X:: Specifying the initial frame's title.
832 * Icons X:: Choosing what sort of icon to use, under X.
833 * Misc X:: Other display options.
835 Environment Variables
837 * General Variables:: Environment variables that all versions of Emacs use.
838 * Misc Variables:: Certain system specific variables.
839 * MS-Windows Registry:: An alternative to the environment on MS-Windows.
841 X Options and Resources
843 * Resources:: Using X resources with Emacs (in general).
844 * Table of Resources:: Table of specific X resources that affect Emacs.
845 * Face Resources:: X resources for customizing faces.
846 * Lucid Resources:: X resources for Lucid menus.
847 * LessTif Resources:: X resources for LessTif and Motif menus.
848 * GTK resources:: Resources for GTK widgets.
852 * Mac Input:: Keyboard and mouse input on Mac.
853 * Mac International:: International character sets on Mac.
854 * Mac Environment Variables:: Setting environment variables for Emacs.
855 * Mac Directories:: Volumes and directories on Mac.
856 * Mac Font Specs:: Specifying fonts on Mac.
857 * Mac Functions:: Mac-specific Lisp functions.
859 Emacs and Microsoft Windows
861 * Text and Binary:: Text files on MS-DOS use CRLF to separate lines.
862 * Windows Processes:: Running subprocesses on Windows.
863 * Windows System Menu:: Controlling what the ALT key does.
869 This manual documents the use and simple customization of the Emacs
870 editor. The reader is not expected to be a programmer; simple
871 customizations do not require programming skill. The user who is not
872 interested in customizing can ignore the scattered customization hints.
874 This is primarily a reference manual, but can also be used as a
875 primer. For complete beginners, it is a good idea to start with the
876 on-line, learn-by-doing tutorial, before reading the manual. To run the
877 tutorial, start Emacs and type @kbd{C-h t}. This way you can learn
878 Emacs by using Emacs on a specially designed file which describes
879 commands, tells you when to try them, and then explains the results you
882 On first reading, just skim chapters 1 and 2, which describe the
883 notational conventions of the manual and the general appearance of the
884 Emacs display screen. Note which questions are answered in these
885 chapters, so you can refer back later. After reading chapter 4, you
886 should practice the commands there. The next few chapters describe
887 fundamental techniques and concepts that are used constantly. You need
888 to understand them thoroughly, experimenting with them if necessary.
890 Chapters 14 through 19 describe intermediate-level features that are
891 useful for all kinds of editing. Chapter 20 and following chapters
892 describe features that you may or may not want to use; read those
893 chapters when you need them.
895 Read the Trouble chapter if Emacs does not seem to be working
896 properly. It explains how to cope with some common problems
897 (@pxref{Lossage}), as well as when and how to report Emacs bugs
900 To find the documentation on a particular command, look in the index.
901 Keys (character commands) and command names have separate indexes. There
902 is also a glossary, with a cross reference for each term.
904 This manual is available as a printed book and also as an Info file.
905 The Info file is for on-line perusal with the Info program, which will
906 be the principal way of viewing documentation on-line in the GNU system.
907 Both the Info file and the Info program itself are distributed along
908 with GNU Emacs. The Info file and the printed book contain
909 substantially the same text and are generated from the same source
910 files, which are also distributed along with GNU Emacs.
912 GNU Emacs is a member of the Emacs editor family. There are many
913 Emacs editors, all sharing common principles of organization. For
914 information on the underlying philosophy of Emacs and the lessons
915 learned from its development, see @cite{Emacs, the Extensible,
916 Customizable Self-Documenting Display Editor}, available from
917 @url{ftp://publications.ai.mit.edu/ai-publications/pdf/AIM-519A.pdf}.
919 This edition of the manual is intended for use with GNU Emacs
920 installed on GNU and Unix systems. GNU Emacs can also be used on VMS,
921 MS-DOS (also called MS-DOG), Microsoft Windows, and Macintosh systems.
922 Those systems use different file name syntax; in addition, VMS and
923 MS-DOS do not support all GNU Emacs features. @xref{Emacs and
924 Microsoft Windows}, for information about using Emacs on Windows.
925 @xref{Mac OS}, for information about using Emacs on Macintosh. We
926 don't try to describe VMS usage in this manual.
929 @node Distrib, Intro, Top, Top
930 @unnumbered Distribution
932 GNU Emacs is @dfn{free software}; this means that everyone is free to
933 use it and free to redistribute it on certain conditions. GNU Emacs
934 is not in the public domain; it is copyrighted and there are
935 restrictions on its distribution, but these restrictions are designed
936 to permit everything that a good cooperating citizen would want to do.
937 What is not allowed is to try to prevent others from further sharing
938 any version of GNU Emacs that they might get from you. The precise
939 conditions are found in the GNU General Public License that comes with
940 Emacs and also appears in this manual@footnote{This manual is itself
941 covered by the GNU Free Documentation License. This license is
942 similar in spirit to the General Public License, but is more suitable
943 for documentation. @xref{GNU Free Documentation License}.}.
946 One way to get a copy of GNU Emacs is from someone else who has it.
947 You need not ask for our permission to do so, or tell any one else;
948 just copy it. If you have access to the Internet, you can get the
949 latest distribution version of GNU Emacs by anonymous FTP; see
950 @url{http://www.gnu.org/software/emacs} on our website for more
953 You may also receive GNU Emacs when you buy a computer. Computer
954 manufacturers are free to distribute copies on the same terms that apply to
955 everyone else. These terms require them to give you the full sources,
956 including whatever changes they may have made, and to permit you to
957 redistribute the GNU Emacs received from them under the usual terms of the
958 General Public License. In other words, the program must be free for you
959 when you get it, not just free for the manufacturer.
961 You can also order copies of GNU Emacs from the Free Software
962 Foundation. This is a convenient and reliable way to get a copy; it is
963 also a good way to help fund our work. We also sell hardcopy versions
964 of this manual and @cite{An Introduction to Programming in Emacs Lisp},
965 by Robert J. Chassell. You can find an order form on our web site at
966 @url{http://www.gnu.org/order/order.html}. For further information,
970 Free Software Foundation
971 51 Franklin Street, Fifth Floor
972 Boston, MA 02110-1301
976 The income from distribution fees goes to support the foundation's
977 purpose: the development of new free software, and improvements to our
978 existing programs including GNU Emacs.
980 If you find GNU Emacs useful, please @strong{send a donation} to the
981 Free Software Foundation to support our work. Donations to the Free
982 Software Foundation are tax deductible in the US. If you use GNU Emacs
983 at your workplace, please suggest that the company make a donation. If
984 company policy is unsympathetic to the idea of donating to charity, you
985 might instead suggest ordering a CD-ROM from the Foundation
986 occasionally, or subscribing to periodic updates.
989 @node Acknowledgments, Intro, Distrib, Top
990 @unnumberedsec Acknowledgments
992 Contributors to GNU Emacs include Per Abrahamsen, Tomas Abrahamsson,
993 Jay K.@: Adams, Joe Arceneaux, Miles Bader, David Bakhash, Eli
994 Barzilay, Steven L.@: Baur, Boaz Ben-Zvi, Ray Blaak, Jim Blandy, Per
995 Bothner, Terrence Brannon, Frank Bresz, Peter Breton, Emmanuel Briot,
996 Kevin Broadey, Vincent Broman, David M.@: Brown, Georges Brun-Cottan,
997 W@l{}odek Bzyl, Bill Carpenter, Per Cederqvist, Hans Chalupsky, Chris
998 Chase, Bob Chassell, Andrew Choi, James Clark, Mike Clarkson, Glynn
999 Clements, Andrew Csillag, Doug Cutting, Michael DeCorte, Gary Delp,
1000 Matthieu Devin, Eri Ding, Jan Dj@"{a}rv, Carsten Dominik, Scott
1001 Draves, Benjamin Drieu, Viktor Dukhovni, John Eaton, Rolf Ebert,
1002 Stephen Eglen, Torbj@"orn Einarsson, Tsugutomo Enami, Hans Henrik
1003 Eriksen, Michael Ernst, Ata Etemadi, Frederick Farnbach, Oscar
1004 Figueiredo, Fred Fish, Karl Fogel, Gary Foster, Noah Friedman,
1005 Hallvard Furuseth, Keith Gabryelski, Kevin Gallagher, Kevin Gallo,
1006 Juan Le@'{o}n Lahoz Garc@'{i}a, Howard Gayle, Stephen Gildea, Julien
1007 Gilles, David Gillespie, Bob Glickstein, Boris Goldowsky, Michelangelo
1008 Grigni, Odd Gripenstam, Kai Gro@ss{}johann, Michael Gschwind, Henry
1009 Guillaume, Doug Gwyn, Ken'ichi Handa, Chris Hanson, K. Shane Hartman,
1010 John Heidemann, Jon K.@: Hellan, Markus Heritsch, Karl Heuer, Manabu
1011 Higashida, Anders Holst, Kurt Hornik, Tom Houlder, Denis Howe, Lars
1012 Ingebrigtsen, Andrew Innes, Seiichiro Inoue, Ulf Jasper, Michael
1013 K. Johnson, Kyle Jones, Terry Jones, Simon Josefsson, Tomoji Kagatani,
1014 Brewster Kahle, David Kaufman, Henry Kautz, Taichi Kawabata, Howard
1015 Kaye, Michael Kifer, Richard King, Peter Kleiweg, Larry K.@: Kolodney,
1016 Pavel Kobiakov, Larry K.@: Kolodney, David M.@: Koppelman, Koseki
1017 Yoshinori, Robert Krawitz, Sebastian Kremer, Ryszard Kubiak, Geoff
1018 Kuenning, David K@aa{}gedal, Daniel LaLiberte, Aaron Larson, James
1019 R.@: Larus, Vinicius Jose Latorre, Frederic Lepied, Peter Liljenberg,
1020 Lars Lindberg, Chris Lindblad, Anders Lindgren, Thomas Link, Dave
1021 Love, Eric Ludlam, Alan Mackenzie, Christopher J.@: Madsen,
1022 Neil M.@: Mager, Ken Manheimer, Bill Mann, Brian Marick, Simon
1023 Marshall, Bengt Martensson, Charlie Martin, Thomas May, Roland McGrath,
1024 Will Mengarini, David Megginson, Wayne Mesard, Brad Miller, Richard
1025 Mlynarik, Gerd Moellmann, Stefan Monnier, Morioka Tomohiko, Keith
1026 Moore, Sen Nagata, Erik Naggum, Thomas Neumann, Thien-Thi Nguyen, Mike
1027 Newton, Jurgen Nickelsen, Dan Nicolaescu, Jeff Norden, Andrew Norman,
1028 Alexandre Oliva, Bob Olson, Takaaki Ota, Pieter E.@: J.@: Pareit,
1029 David Pearson, Jeff Peck, Damon Anton Permezel, Tom Perrine, William
1030 M.@: Perry, Per Persson, Jens Petersen, Daniel Pfeiffer, Richard
1031 L.@: Pieri, Fred Pierresteguy, Christian Plaunt, David Ponce, Francesco
1032 A. Potorti, Michael D. Prange, Mukesh Prasad, Marko Rahamaa, Ashwin
1033 Ram, Eric S. Raymond, Paul Reilly, Edward M. Reingold, Alex Rezinsky,
1034 Rob Riepel, Nick Roberts, Roland B.@: Roberts, John Robinson, Danny
1035 Roozendaal, William Rosenblatt, Guillermo J.@: Rozas, Ivar Rummelhoff,
1036 Jason Rumney, Wolfgang Rupprecht, Kevin Ryde, James B. Salem, Masahiko
1037 Sato, Holger Schauer, William Schelter, Ralph Schleicher, Gregor
1038 Schmid, Michael Schmidt, Ronald S. Schnell, Philippe Schnoebelen, Jan
1039 Schormann, Alex Schroeder, Stephen Schoef, Randal Schwartz, Oliver
1040 Seidel, Manuel Serrano, Hovav Shacham, Stanislav Shalunov, Mark
1041 Shapiro, Richard Sharman, Olin Shivers, Espen Skoglund, Rick Sladkey,
1042 Lynn Slater, Chris Smith, David Smith, Paul D.@: Smith, Andre Spiegel,
1043 Michael Staats, William Sommerfeld, Michael Staats, Sam Steingold, Ake
1044 Stenhoff, Peter Stephenson, Ken Stevens, Jonathan Stigelman, Martin
1045 Stjernholm, Kim F.@: Storm, Steve Strassman, Olaf Sylvester, Naoto
1046 Takahashi, Jean-Philippe Theberge, Jens T.@: Berger Thielemann,
1047 Spencer Thomas, Jim Thompson, Tom Tromey, Daiki Ueno, Masanobu Umeda,
1048 Rajesh Vaidheeswarran, Neil W.@: Van Dyke, Didier Verna, Ulrik Vieth,
1049 Geoffrey Voelker, Johan Vromans, Inge Wallin, Colin Walters, Barry
1050 Warsaw, Morten Welinder, Joseph Brian Wells, Rodney Whitby, John
1051 Wiegley, Ed Wilkinson, Mike Williams, Bill Wohler, Steven A. Wood,
1052 Dale R.@: Worley, Francis J.@: Wright, Felix S. T. Wu, Tom Wurgler,
1053 Masatake Yamato, Jonathan Yavner, Ilya Zakharevich, Milan Zamazal,
1054 Victor Zandy, Eli Zaretskii, Jamie Zawinski, Shenghuo Zhu, Ian
1055 T.@: Zimmermann, Reto Zimmermann, Neal Ziring, and Detlev Zundel.
1058 @node Intro, Glossary, Distrib, Top
1059 @unnumbered Introduction
1061 You are reading about GNU Emacs, the GNU incarnation of the advanced,
1062 self-documenting, customizable, extensible real-time display editor Emacs.
1063 (The `G' in `GNU' is not silent.)
1065 We say that Emacs is a @dfn{display} editor because normally the text
1066 being edited is visible on the screen and is updated automatically as you
1067 type your commands. @xref{Screen,Display}.
1069 We call it a @dfn{real-time} editor because the display is updated very
1070 frequently, usually after each character or pair of characters you
1071 type. This minimizes the amount of information you must keep in your
1072 head as you edit. @xref{Basic,Real-time,Basic Editing}.
1074 We call Emacs advanced because it provides facilities that go beyond
1075 simple insertion and deletion: controlling subprocesses; automatic
1076 indentation of programs; viewing two or more files at once; editing
1077 formatted text; and dealing in terms of characters, words, lines,
1078 sentences, paragraphs, and pages, as well as expressions and comments in
1079 several different programming languages.
1081 @dfn{Self-documenting} means that at any time you can type a special
1082 character, @kbd{Control-h}, to find out what your options are. You can
1083 also use it to find out what any command does, or to find all the commands
1084 that pertain to a topic. @xref{Help}.
1086 @dfn{Customizable} means that you can change the definitions of Emacs
1087 commands in little ways. For example, if you use a programming language in
1088 which comments start with @samp{<**} and end with @samp{**>}, you can tell
1089 the Emacs comment manipulation commands to use those strings
1090 (@pxref{Comments}). Another sort of customization is rearrangement of the
1091 command set. For example, if you prefer the four basic cursor motion
1092 commands (up, down, left and right) on keys in a diamond pattern on the
1093 keyboard, you can rebind the keys that way. @xref{Customization}.
1095 @dfn{Extensible} means that you can go beyond simple customization and
1096 write entirely new commands, programs in the Lisp language to be run by
1097 Emacs's own Lisp interpreter. Emacs is an ``on-line extensible''
1098 system, which means that it is divided into many functions that call
1099 each other, any of which can be redefined in the middle of an editing
1100 session. Almost any part of Emacs can be replaced without making a
1101 separate copy of all of Emacs. Most of the editing commands of Emacs
1102 are written in Lisp; the few exceptions could have been written
1103 in Lisp but are written in C for efficiency. Although only a programmer
1104 can write an extension, anybody can use it afterward. @xref{Top,
1105 Emacs Lisp Intro, Preface, eintr, An Introduction to Programming in
1106 Emacs Lisp}, if you want to learn Emacs Lisp programming.
1108 When running on a graphical display, Emacs provides its own menus
1109 and convenient handling of mouse buttons. But Emacs provides many of
1110 the benefits of a graphical display even on a text-only terminal. For
1111 instance, it can highlight parts of a file, display and edit several
1112 files at once, move text between files, and edit files while running
1115 @include screen.texi
1116 @include commands.texi
1117 @include entering.texi
1123 @include killing.texi
1125 @include display.texi
1126 @include search.texi
1128 @include kmacro.texi
1130 @include buffers.texi
1131 @include windows.texi
1132 @include frames.texi
1135 @include indent.texi
1137 @include programs.texi
1138 @include building.texi
1139 @include maintaining.texi
1140 @include abbrevs.texi
1141 @include sending.texi
1144 @include calendar.texi
1146 @include custom.texi
1147 @include trouble.texi
1149 @node Copying, GNU Free Documentation License, Service, Top
1150 @appendix GNU GENERAL PUBLIC LICENSE
1151 @center Version 2, June 1991
1154 Copyright @copyright{} 1989, 1991 Free Software Foundation, Inc.
1155 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
1157 Everyone is permitted to copy and distribute verbatim copies
1158 of this license document, but changing it is not allowed.
1161 @unnumberedsec Preamble
1163 The licenses for most software are designed to take away your
1164 freedom to share and change it. By contrast, the GNU General Public
1165 License is intended to guarantee your freedom to share and change free
1166 software---to make sure the software is free for all its users. This
1167 General Public License applies to most of the Free Software
1168 Foundation's software and to any other program whose authors commit to
1169 using it. (Some other Free Software Foundation software is covered by
1170 the GNU Library General Public License instead.) You can apply it to
1173 When we speak of free software, we are referring to freedom, not
1174 price. Our General Public Licenses are designed to make sure that you
1175 have the freedom to distribute copies of free software (and charge for
1176 this service if you wish), that you receive source code or can get it
1177 if you want it, that you can change the software or use pieces of it
1178 in new free programs; and that you know you can do these things.
1180 To protect your rights, we need to make restrictions that forbid
1181 anyone to deny you these rights or to ask you to surrender the rights.
1182 These restrictions translate to certain responsibilities for you if you
1183 distribute copies of the software, or if you modify it.
1185 For example, if you distribute copies of such a program, whether
1186 gratis or for a fee, you must give the recipients all the rights that
1187 you have. You must make sure that they, too, receive or can get the
1188 source code. And you must show them these terms so they know their
1191 We protect your rights with two steps: (1) copyright the software, and
1192 (2) offer you this license which gives you legal permission to copy,
1193 distribute and/or modify the software.
1195 Also, for each author's protection and ours, we want to make certain
1196 that everyone understands that there is no warranty for this free
1197 software. If the software is modified by someone else and passed on, we
1198 want its recipients to know that what they have is not the original, so
1199 that any problems introduced by others will not reflect on the original
1200 authors' reputations.
1202 Finally, any free program is threatened constantly by software
1203 patents. We wish to avoid the danger that redistributors of a free
1204 program will individually obtain patent licenses, in effect making the
1205 program proprietary. To prevent this, we have made it clear that any
1206 patent must be licensed for everyone's free use or not licensed at all.
1208 The precise terms and conditions for copying, distribution and
1209 modification follow.
1212 @unnumberedsec TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
1215 @center TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
1220 This License applies to any program or other work which contains
1221 a notice placed by the copyright holder saying it may be distributed
1222 under the terms of this General Public License. The ``Program,'' below,
1223 refers to any such program or work, and a ``work based on the Program''
1224 means either the Program or any derivative work under copyright law:
1225 that is to say, a work containing the Program or a portion of it,
1226 either verbatim or with modifications and/or translated into another
1227 language. (Hereinafter, translation is included without limitation in
1228 the term ``modification.'') Each licensee is addressed as ``you.''
1230 Activities other than copying, distribution and modification are not
1231 covered by this License; they are outside its scope. The act of
1232 running the Program is not restricted, and the output from the Program
1233 is covered only if its contents constitute a work based on the
1234 Program (independent of having been made by running the Program).
1235 Whether that is true depends on what the Program does.
1238 You may copy and distribute verbatim copies of the Program's
1239 source code as you receive it, in any medium, provided that you
1240 conspicuously and appropriately publish on each copy an appropriate
1241 copyright notice and disclaimer of warranty; keep intact all the
1242 notices that refer to this License and to the absence of any warranty;
1243 and give any other recipients of the Program a copy of this License
1244 along with the Program.
1246 You may charge a fee for the physical act of transferring a copy, and
1247 you may at your option offer warranty protection in exchange for a fee.
1250 You may modify your copy or copies of the Program or any portion
1251 of it, thus forming a work based on the Program, and copy and
1252 distribute such modifications or work under the terms of Section 1
1253 above, provided that you also meet all of these conditions:
1257 You must cause the modified files to carry prominent notices
1258 stating that you changed the files and the date of any change.
1261 You must cause any work that you distribute or publish, that in
1262 whole or in part contains or is derived from the Program or any
1263 part thereof, to be licensed as a whole at no charge to all third
1264 parties under the terms of this License.
1267 If the modified program normally reads commands interactively
1268 when run, you must cause it, when started running for such
1269 interactive use in the most ordinary way, to print or display an
1270 announcement including an appropriate copyright notice and a
1271 notice that there is no warranty (or else, saying that you provide
1272 a warranty) and that users may redistribute the program under
1273 these conditions, and telling the user how to view a copy of this
1274 License. (Exception: if the Program itself is interactive but
1275 does not normally print such an announcement, your work based on
1276 the Program is not required to print an announcement.)
1279 These requirements apply to the modified work as a whole. If
1280 identifiable sections of that work are not derived from the Program,
1281 and can be reasonably considered independent and separate works in
1282 themselves, then this License, and its terms, do not apply to those
1283 sections when you distribute them as separate works. But when you
1284 distribute the same sections as part of a whole which is a work based
1285 on the Program, the distribution of the whole must be on the terms of
1286 this License, whose permissions for other licensees extend to the
1287 entire whole, and thus to each and every part regardless of who wrote it.
1289 Thus, it is not the intent of this section to claim rights or contest
1290 your rights to work written entirely by you; rather, the intent is to
1291 exercise the right to control the distribution of derivative or
1292 collective works based on the Program.
1294 In addition, mere aggregation of another work not based on the Program
1295 with the Program (or with a work based on the Program) on a volume of
1296 a storage or distribution medium does not bring the other work under
1297 the scope of this License.
1300 You may copy and distribute the Program (or a work based on it,
1301 under Section 2) in object code or executable form under the terms of
1302 Sections 1 and 2 above provided that you also do one of the following:
1306 Accompany it with the complete corresponding machine-readable
1307 source code, which must be distributed under the terms of Sections
1308 1 and 2 above on a medium customarily used for software interchange; or,
1311 Accompany it with a written offer, valid for at least three
1312 years, to give any third party, for a charge no more than your
1313 cost of physically performing source distribution, a complete
1314 machine-readable copy of the corresponding source code, to be
1315 distributed under the terms of Sections 1 and 2 above on a medium
1316 customarily used for software interchange; or,
1319 Accompany it with the information you received as to the offer
1320 to distribute corresponding source code. (This alternative is
1321 allowed only for noncommercial distribution and only if you
1322 received the program in object code or executable form with such
1323 an offer, in accord with Subsection b above.)
1326 The source code for a work means the preferred form of the work for
1327 making modifications to it. For an executable work, complete source
1328 code means all the source code for all modules it contains, plus any
1329 associated interface definition files, plus the scripts used to
1330 control compilation and installation of the executable. However, as a
1331 special exception, the source code distributed need not include
1332 anything that is normally distributed (in either source or binary
1333 form) with the major components (compiler, kernel, and so on) of the
1334 operating system on which the executable runs, unless that component
1335 itself accompanies the executable.
1337 If distribution of executable or object code is made by offering
1338 access to copy from a designated place, then offering equivalent
1339 access to copy the source code from the same place counts as
1340 distribution of the source code, even though third parties are not
1341 compelled to copy the source along with the object code.
1344 You may not copy, modify, sublicense, or distribute the Program
1345 except as expressly provided under this License. Any attempt
1346 otherwise to copy, modify, sublicense or distribute the Program is
1347 void, and will automatically terminate your rights under this License.
1348 However, parties who have received copies, or rights, from you under
1349 this License will not have their licenses terminated so long as such
1350 parties remain in full compliance.
1353 You are not required to accept this License, since you have not
1354 signed it. However, nothing else grants you permission to modify or
1355 distribute the Program or its derivative works. These actions are
1356 prohibited by law if you do not accept this License. Therefore, by
1357 modifying or distributing the Program (or any work based on the
1358 Program), you indicate your acceptance of this License to do so, and
1359 all its terms and conditions for copying, distributing or modifying
1360 the Program or works based on it.
1363 Each time you redistribute the Program (or any work based on the
1364 Program), the recipient automatically receives a license from the
1365 original licensor to copy, distribute or modify the Program subject to
1366 these terms and conditions. You may not impose any further
1367 restrictions on the recipients' exercise of the rights granted herein.
1368 You are not responsible for enforcing compliance by third parties to
1372 If, as a consequence of a court judgment or allegation of patent
1373 infringement or for any other reason (not limited to patent issues),
1374 conditions are imposed on you (whether by court order, agreement or
1375 otherwise) that contradict the conditions of this License, they do not
1376 excuse you from the conditions of this License. If you cannot
1377 distribute so as to satisfy simultaneously your obligations under this
1378 License and any other pertinent obligations, then as a consequence you
1379 may not distribute the Program at all. For example, if a patent
1380 license would not permit royalty-free redistribution of the Program by
1381 all those who receive copies directly or indirectly through you, then
1382 the only way you could satisfy both it and this License would be to
1383 refrain entirely from distribution of the Program.
1385 If any portion of this section is held invalid or unenforceable under
1386 any particular circumstance, the balance of the section is intended to
1387 apply and the section as a whole is intended to apply in other
1390 It is not the purpose of this section to induce you to infringe any
1391 patents or other property right claims or to contest validity of any
1392 such claims; this section has the sole purpose of protecting the
1393 integrity of the free software distribution system, which is
1394 implemented by public license practices. Many people have made
1395 generous contributions to the wide range of software distributed
1396 through that system in reliance on consistent application of that
1397 system; it is up to the author/donor to decide if he or she is willing
1398 to distribute software through any other system and a licensee cannot
1401 This section is intended to make thoroughly clear what is believed to
1402 be a consequence of the rest of this License.
1405 If the distribution and/or use of the Program is restricted in
1406 certain countries either by patents or by copyrighted interfaces, the
1407 original copyright holder who places the Program under this License
1408 may add an explicit geographical distribution limitation excluding
1409 those countries, so that distribution is permitted only in or among
1410 countries not thus excluded. In such case, this License incorporates
1411 the limitation as if written in the body of this License.
1414 The Free Software Foundation may publish revised and/or new versions
1415 of the General Public License from time to time. Such new versions will
1416 be similar in spirit to the present version, but may differ in detail to
1417 address new problems or concerns.
1419 Each version is given a distinguishing version number. If the Program
1420 specifies a version number of this License which applies to it and ``any
1421 later version,'' you have the option of following the terms and conditions
1422 either of that version or of any later version published by the Free
1423 Software Foundation. If the Program does not specify a version number of
1424 this License, you may choose any version ever published by the Free Software
1428 If you wish to incorporate parts of the Program into other free
1429 programs whose distribution conditions are different, write to the author
1430 to ask for permission. For software which is copyrighted by the Free
1431 Software Foundation, write to the Free Software Foundation; we sometimes
1432 make exceptions for this. Our decision will be guided by the two goals
1433 of preserving the free status of all derivatives of our free software and
1434 of promoting the sharing and reuse of software generally.
1437 @heading NO WARRANTY
1444 BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
1445 FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW@. EXCEPT WHEN
1446 OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
1447 PROVIDE THE PROGRAM ``AS IS'' WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
1448 OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
1449 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE@. THE ENTIRE RISK AS
1450 TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU@. SHOULD THE
1451 PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
1452 REPAIR OR CORRECTION.
1455 IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
1456 WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
1457 REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
1458 INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
1459 OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
1460 TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
1461 YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
1462 PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
1463 POSSIBILITY OF SUCH DAMAGES.
1467 @heading END OF TERMS AND CONDITIONS
1470 @center END OF TERMS AND CONDITIONS
1474 @unnumberedsec How to Apply These Terms to Your New Programs
1476 If you develop a new program, and you want it to be of the greatest
1477 possible use to the public, the best way to achieve this is to make it
1478 free software which everyone can redistribute and change under these terms.
1480 To do so, attach the following notices to the program. It is safest
1481 to attach them to the start of each source file to most effectively
1482 convey the exclusion of warranty; and each file should have at least
1483 the ``copyright'' line and a pointer to where the full notice is found.
1486 @var{one line to give the program's name and an idea of what it does.}
1487 Copyright (C) 19@var{yy} @var{name of author}
1489 This program is free software; you can redistribute it and/or
1490 modify it under the terms of the GNU General Public License
1491 as published by the Free Software Foundation; either version 2
1492 of the License, or (at your option) any later version.
1494 This program is distributed in the hope that it will be useful,
1495 but WITHOUT ANY WARRANTY; without even the implied warranty of
1496 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE@. See the
1497 GNU General Public License for more details.
1499 You should have received a copy of the GNU General Public License along
1500 with this program; if not, write to the Free Software Foundation, Inc.,
1501 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
1504 Also add information on how to contact you by electronic and paper mail.
1506 If the program is interactive, make it output a short notice like this
1507 when it starts in an interactive mode:
1510 Gnomovision version 69, Copyright (C) 20@var{yy} @var{name of author}
1511 Gnomovision comes with ABSOLUTELY NO WARRANTY; for details
1512 type `show w'. This is free software, and you are welcome
1513 to redistribute it under certain conditions; type `show c'
1517 The hypothetical commands @samp{show w} and @samp{show c} should show
1518 the appropriate parts of the General Public License. Of course, the
1519 commands you use may be called something other than @samp{show w} and
1520 @samp{show c}; they could even be mouse-clicks or menu items---whatever
1523 You should also get your employer (if you work as a programmer) or your
1524 school, if any, to sign a ``copyright disclaimer'' for the program, if
1525 necessary. Here is a sample; alter the names:
1529 Yoyodyne, Inc., hereby disclaims all copyright
1530 interest in the program `Gnomovision'
1531 (which makes passes at compilers) written
1534 @var{signature of Ty Coon}, 1 April 1989
1535 Ty Coon, President of Vice
1539 This General Public License does not permit incorporating your program into
1540 proprietary programs. If your program is a subroutine library, you may
1541 consider it more useful to permit linking proprietary applications with the
1542 library. If this is what you want to do, use the GNU Library General
1543 Public License instead of this License.
1545 @include doclicense.texi
1546 @include cmdargs.texi
1547 @include xresources.texi
1553 @include glossary.texi
1558 @c The Option Index is produced only in the on-line version,
1559 @c because the index entries related to command-line options
1560 @c tend to point to the same pages and all begin with a dash.
1561 @c This, and the need to keep the node links consistent, are
1562 @c the reasons for the funky @iftex/@ifnottex dance below.
1563 @c The Option Index is _not_ before Key Index, because that
1564 @c would require changes in the glossary.texi's @node line.
1565 @c It is not after Concept Index for similar reasons.
1568 @node Key Index, Command Index, Glossary, Top
1569 @unnumbered Key (Character) Index
1574 @node Key Index, Option Index, Glossary, Top
1575 @unnumbered Key (Character) Index
1578 @node Option Index, Command Index, Key Index, Top
1579 @unnumbered Command-Line Options Index
1582 @node Command Index, Variable Index, Option Index, Top
1583 @unnumbered Command and Function Index
1588 @node Command Index, Variable Index, Key Index, Top
1589 @unnumbered Command and Function Index
1593 @node Variable Index, Concept Index, Command Index, Top
1594 @unnumbered Variable Index
1597 @node Concept Index, Acknowledgments, Variable Index, Top
1598 @unnumbered Concept Index
1604 arch-tag: ed48740a-410b-46ea-9387-c9a9252a3392