]> code.delx.au - gnu-emacs/blobdiff - man/misc.texi
*** empty log message ***
[gnu-emacs] / man / misc.texi
index d5c7572abcf5df25940c308dc8009c2e092f0ecb..0b07e04ed68140b27824ae34d30c4743ec79ced1 100644 (file)
@@ -1,6 +1,6 @@
 @c This is part of the Emacs manual.
-@c Copyright (C) 1985, 86, 87, 93, 94, 95, 97, 2000, 2001, 2004
-@c   Free Software Foundation, Inc.
+@c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001,
+@c   2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
 @c See file emacs.texi for copying conditions.
 @iftex
 @chapter Miscellaneous Commands
@@ -9,9 +9,10 @@
 else: reading netnews, running shell commands and shell subprocesses,
 using a single shared Emacs for utilities that expect to run an editor
 as a subprocess, printing hardcopy, sorting text, narrowing display to
-part of the buffer, editing double-column files and binary files, saving
-an Emacs session for later resumption, emulating other editors, and
-various diversions and amusements.
+part of the buffer, editing double-column files and binary files,
+saving an Emacs session for later resumption, following hyperlinks,
+browsing images, emulating other editors, and various diversions and
+amusements.
 
 @end iftex
 
@@ -49,15 +50,15 @@ To start Gnus, type @kbd{M-x gnus @key{RET}}.
 @node Buffers of Gnus
 @subsection Gnus Buffers
 
-As opposed to most normal Emacs packages, Gnus uses a number of
-different buffers to display information and to receive commands.  The
-three buffers users spend most of their time in are the @dfn{group
-buffer}, the @dfn{summary buffer} and the @dfn{article buffer}.
+Unlike most Emacs packages, Gnus uses several buffers to display
+information and to receive commands.  The three Gnus buffers users use
+most are the @dfn{group buffer}, the @dfn{summary buffer} and the
+@dfn{article buffer}.
 
-The @dfn{group buffer} contains a list of groups.  This is the first
-buffer Gnus displays when it starts up.  It normally displays only the
-groups to which you subscribe and that contain unread articles.  Use
-this buffer to select a specific group.
+The @dfn{group buffer} contains a list of newsgroups.  This is the
+first buffer Gnus displays when it starts up.  It normally displays
+only the groups to which you subscribe and that contain unread
+articles.  Use this buffer to select a specific group.
 
 The @dfn{summary buffer} lists one line for each article in a single
 group.  By default, the author, the subject and the line number are
@@ -67,9 +68,10 @@ in the group buffer, and is killed when you exit the group.  Use this
 buffer to select an article.
 
 The @dfn{article buffer} displays the article.  In normal Gnus usage,
-you don't select this buffer---all useful article-oriented commands work
-in the summary buffer.  But you can select the article buffer, and
-execute all Gnus commands from that buffer, if you want to.
+you see this buffer but you don't select it---all useful
+article-oriented commands work in the summary buffer.  But you can
+select the article buffer, and execute all Gnus commands from that
+buffer, if you want to.
 
 @node Gnus Startup
 @subsection When Gnus Starts Up
@@ -111,9 +113,9 @@ displayed in the article buffer in a large window, below the summary
 buffer in its small window.
 @end enumerate
 
-  Each Gnus buffer has its own special commands; however, the meanings
-of any given key in the various Gnus buffers are usually analogous, even
-if not identical.  Here are commands for the group and summary buffers:
+  Each Gnus buffer has its own special commands; the meanings of any
+given key in the various Gnus buffers are usually analogous, even if
+not identical.  Here are commands for the group and summary buffers:
 
 @table @kbd
 @kindex q @r{(Gnus Group mode)}
@@ -315,9 +317,6 @@ processes; it can also run a shell interactively with input and output
 to an Emacs buffer named @samp{*shell*} or run a shell inside a terminal
 emulator window.
 
-There is a shell implemented entirely in Emacs, documented in a separate
-manual.  @xref{Top,Eshell,Eshell, eshell, Eshell: The Emacs Shell}.
-
 @table @kbd
 @item M-! @var{cmd} @key{RET}
 Run the shell command line @var{cmd} and display the output
@@ -333,15 +332,17 @@ You can then give commands interactively.
 Run a subshell with input and output through an Emacs buffer.
 You can then give commands interactively.
 Full terminal emulation is available.
-@item M-x eshell
-@findex eshell
-Start the Emacs shell.
 @end table
 
+  @kbd{M-x eshell} invokes a shell implemented entirely in Emacs.  It
+is documented in a separate manual.  @xref{Top,Eshell,Eshell, eshell,
+Eshell: The Emacs Shell}.
+
 @menu
 * Single Shell::           How to run one shell command and return.
 * Interactive Shell::      Permanent shell taking input via Emacs.
 * Shell Mode::             Special Emacs commands used with permanent shell.
+* Shell Prompts::          Two ways to recognize shell prompts.
 * History: Shell History.  Repeating previous commands in a shell buffer.
 * Directory Tracking::     Keeping track when the subshell changes directory.
 * Options: Shell Options.  Options for customizing Shell mode.
@@ -378,37 +379,38 @@ uncompressed equivalent of @file{foo.gz} into the current buffer.
 For a synchronous shell command, @code{shell-command} returns the
 command's exit status (0 means success), when it is called from a Lisp
 program.  You do not get any status information for an asynchronous
-command, since it hasn't finished yet.
+command, since it hasn't finished yet when @code{shell-command} returns.
 
 @kindex M-|
 @findex shell-command-on-region
   @kbd{M-|} (@code{shell-command-on-region}) is like @kbd{M-!} but
 passes the contents of the region as the standard input to the shell
-command, instead of no input.  If a numeric argument is used, meaning
-insert the output in the current buffer, then the old region is deleted
-first and the output replaces it as the contents of the region.  It
-returns the command's exit status when it is called from a Lisp program.
+command, instead of no input.  With a numeric argument, meaning insert
+the output in the current buffer, it deletes the old region and the
+output replaces it as the contents of the region.  It returns the
+command's exit status, like @kbd{M-!}.
 
   One use for @kbd{M-|} is to run @code{gpg} to see what keys are in
 the buffer.  For instance, if the buffer contains a GPG key, type
-@kbd{C-x h M-| gpg @key{RET}} to feed the entire buffer contents
-to the @code{gpg} program.  That program will ignore everything except
-the encoded keys, and will output a list of the keys it contains.
+@kbd{C-x h M-| gpg @key{RET}} to feed the entire buffer contents to
+the @code{gpg} program.  That program will ignore everything except
+the encoded keys, and will output a list of the keys the buffer
+contains.
 
 @vindex shell-file-name
-  Both @kbd{M-!} and @kbd{M-|} use @code{shell-file-name} to specify the
-shell to use.  This variable is initialized based on your @env{SHELL}
-environment variable when Emacs is started.  If the file name does not
-specify a directory, the directories in the list @code{exec-path} are
-searched; this list is initialized based on the environment variable
-@env{PATH} when Emacs is started.  Your @file{.emacs} file can override
-either or both of these default initializations.@refill
+  Both @kbd{M-!} and @kbd{M-|} use @code{shell-file-name} to specify
+the shell to use.  This variable is initialized based on your
+@env{SHELL} environment variable when Emacs is started.  If the file
+name is relative, Emacs searches the directories in the list
+@code{exec-path}; this list is initialized based on the environment
+variable @env{PATH} when Emacs is started.  Your @file{.emacs} file
+can override either or both of these default initializations.
 
   Both @kbd{M-!} and @kbd{M-|} wait for the shell command to complete,
-unless you end the command with @samp{&} to make it asyncronous.  To
+unless you end the command with @samp{&} to make it asynchronous.  To
 stop waiting, type @kbd{C-g} to quit; that terminates the shell
 command with the signal @code{SIGINT}---the same signal that @kbd{C-c}
-normally generates in the shell.  Emacs waits until the command
+normally generates in the shell.  Emacs then waits until the command
 actually terminates.  If the shell command doesn't stop (because it
 ignores the @code{SIGINT} signal), type @kbd{C-g} again; this sends
 the command a @code{SIGKILL} signal which is impossible to ignore.
@@ -418,13 +420,14 @@ the buffer @samp{*Async Shell Command*}.  Output arrives in that
 buffer regardless of whether it is visible in a window.
 
   To specify a coding system for @kbd{M-!} or @kbd{M-|}, use the command
-@kbd{C-x @key{RET} c} immediately beforehand.  @xref{Specify Coding}.
+@kbd{C-x @key{RET} c} immediately beforehand.  @xref{Communication Coding}.
 
 @vindex shell-command-default-error-buffer
-  Error output from the command is normally intermixed with the regular
-output.  If you set the variable
-@code{shell-command-default-error-buffer} to a string, which is a buffer
-name, error output is inserted before point in the buffer of that name.
+  Error output from these commands is normally intermixed with the
+regular output.  But if the variable
+@code{shell-command-default-error-buffer} has a string as value, and
+it's the name of a buffer, @kbd{M-!} and @kbd{M-|} insert error output
+before point in that buffer.
 
 @node Interactive Shell
 @subsection Interactive Inferior Shell
@@ -455,8 +458,8 @@ previous input lines in the buffer.  @xref{Faces}.
 prefix argument (e.g. @kbd{C-u M-x shell}), which will read a buffer
 name and create (or reuse) a subshell in that buffer.  You can also
 rename the @samp{*shell*} buffer using @kbd{M-x rename-uniquely}, then
-create a new @samp{*shell*} buffer using plain @kbd{M-x shell}.  All the
-subshells in different buffers run independently and in parallel.
+create a new @samp{*shell*} buffer using plain @kbd{M-x shell}.
+Subshells in different buffers run independently and in parallel.
 
 @vindex explicit-shell-file-name
 @cindex environment variables for subshells
@@ -478,9 +481,10 @@ from.  For example, if you use bash, the file sent to it is
 @file{~/.emacs_bash}.
 
   To specify a coding system for the shell, you can use the command
-@kbd{C-x @key{RET} c} immediately before @kbd{M-x shell}.  You can also
-specify a coding system after starting the shell by using @kbd{C-x
-@key{RET} p} in the shell buffer.  @xref{Specify Coding}.
+@kbd{C-x @key{RET} c} immediately before @kbd{M-x shell}.  You can
+also change the coding system for a running subshell by typing
+@kbd{C-x @key{RET} p} in the shell buffer.  @xref{Communication
+Coding}.
 
 @cindex @env{EMACS} environment variable
   Unless the environment variable @env{EMACS} is already defined,
@@ -504,10 +508,10 @@ of the special key bindings of Shell mode:
 @kindex RET @r{(Shell mode)}
 @findex comint-send-input
 At end of buffer send line as input; otherwise, copy current line to
-end of buffer and send it (@code{comint-send-input}).  When a line is
-copied, any prompt at the beginning of the line (text output by
-programs preceding your input) is omitted.  (See also the variable
-@code{comint-use-prompt-regexp-instead-of-fields}.)
+end of buffer and send it (@code{comint-send-input}).  Copying a line
+in this way omits any prompt at the beginning of the line (text output
+by programs preceding your input).  @xref{Shell Prompts}, for how
+Shell mode recognizes prompts.
 
 @item @key{TAB}
 @kindex TAB @r{(Shell mode)}
@@ -562,7 +566,8 @@ the newline that separates them), when you type @key{RET}.
 @kindex C-c C-u @r{(Shell mode)}
 @findex comint-kill-input
 Kill all text pending at end of buffer to be sent as input
-(@code{comint-kill-input}).
+(@code{comint-kill-input}).  If point is not at end of buffer,
+this only kills the part of this text that precedes point.
 
 @item C-c C-w
 @kindex C-c C-w @r{(Shell mode)}
@@ -643,12 +648,13 @@ Send @var{text} as input to the shell, after reading it without
 echoing.  This is useful when a shell command runs a program that asks
 for a password.
 
-Alternatively, you can arrange for Emacs to notice password prompts
-and turn off echoing for them, as follows:
+Please note that Emacs will not echo passwords by default.  If you
+really want them to be echoed, evaluate the following Lisp
+expression:
 
 @example
-(add-hook 'comint-output-filter-functions
-          'comint-watch-for-password-prompt)
+(remove-hook 'comint-output-filter-functions
+             'comint-watch-for-password-prompt)
 @end example
 
 @item M-x comint-continue-subjob
@@ -684,10 +690,6 @@ subshell:
 @end example
 @end table
 
-  Shell mode also customizes the paragraph commands so that only shell
-prompts start new paragraphs.  Thus, a paragraph consists of an input
-command plus the output that follows it in the buffer.
-
 @cindex Comint mode
 @cindex mode, Comint
   Shell mode is a derivative of Comint mode, a general-purpose mode for
@@ -704,6 +706,45 @@ the directory tracking feature, and a few user commands.
 in a subprocess using unmodified Comint mode---without the
 specializations of Shell mode.
 
+@node Shell Prompts
+@subsection Shell Prompts
+
+@vindex shell-prompt-pattern
+@vindex comint-prompt-regexp
+@vindex comint-use-prompt-regexp
+@cindex prompt, shell
+  A prompt is text output by a program to show that it is ready to
+accept new user input.  Normally, Comint mode (and thus Shell mode)
+considers the prompt to be any text output by a program at the
+beginning of an input line.  However, if the variable
+@code{comint-use-prompt-regexp} is non-@code{nil}, then Comint mode
+uses a regular expression to recognize prompts.  In Shell mode,
+@code{shell-prompt-pattern} specifies the regular expression.
+
+  The value of @code{comint-use-prompt-regexp} also affects many
+motion and paragraph commands.  If the value is non-@code{nil}, the
+general Emacs motion commands behave as they normally do in buffers
+without special text properties.  However, if the value is @code{nil},
+the default, then Comint mode divides the buffer into two types of
+``fields'' (ranges of consecutive characters having the same
+@code{field} text property): input and output.  Prompts are part of
+the output.  Most Emacs motion commands do not cross field boundaries,
+unless they move over multiple lines.  For instance, when point is in
+input on the same line as a prompt, @kbd{C-a} puts point at the
+beginning of the input if @code{comint-use-prompt-regexp} is
+@code{nil} and at the beginning of the line otherwise.
+
+  In Shell mode, only shell prompts start new paragraphs.  Thus, a
+paragraph consists of a prompt and the input and output that follow
+it.  However, if @code{comint-use-prompt-regexp} is @code{nil}, the
+default, most paragraph commands do not cross field boundaries.  This
+means that prompts, ranges of input, and ranges of non-prompt output
+behave mostly like separate paragraphs; with this setting, numeric
+arguments to most paragraph commands yield essentially undefined
+behavior.  For the purpose of finding paragraph boundaries, Shell mode
+uses @code{shell-prompt-pattern}, regardless of
+@code{comint-use-prompt-regexp}.
+
 @node Shell History
 @subsection Shell Command History
 
@@ -784,7 +825,9 @@ same regexp used last time.
 
   When you find the previous input you want, you can resubmit it by
 typing @key{RET}, or you can edit it first and then resubmit it if you
-wish.
+wish.  Any partial input you were composing before navigating the
+history list is restored when you go to the beginning or end of the
+history ring.
 
   Often it is useful to reexecute several successive shell commands that
 were previously executed in sequence.  To do this, first find and
@@ -810,7 +853,7 @@ that these commands access.
 
 @vindex shell-input-ring-file-name
   Some shells store their command histories in files so that you can
-refer to previous commands from previous shell sessions.  Emacs reads
+refer to commands from previous shell sessions.  Emacs reads
 the command history file for your chosen shell, to initialize its own
 command history.  The file name is @file{~/.bash_history} for bash,
 @file{~/.sh_history} for ksh, and @file{~/.history} for other shells.
@@ -876,19 +919,8 @@ when you send them to the shell.  To request this, set the variable
 @key{SPC} perform history expansion by binding @key{SPC} to the
 command @code{comint-magic-space}.
 
-@vindex shell-prompt-pattern
-@vindex comint-prompt-regexp
-@vindex comint-use-prompt-regexp-instead-of-fields
-@cindex prompt, shell
   Shell mode recognizes history references when they follow a prompt.
-Normally, any text output by a program at the beginning of an input
-line is considered a prompt.  However, if the variable
-@code{comint-use-prompt-regexp-instead-of-fields} is non-@code{nil},
-then Comint mode uses a regular expression to recognize prompts.  In
-general, the variable @code{comint-prompt-regexp} specifies the
-regular expression; Shell mode uses the variable
-@code{shell-prompt-pattern} to set up @code{comint-prompt-regexp} in
-the shell buffer.
+@xref{Shell Prompts}, for how Shell mode recognizes prompts.
 
 @node Directory Tracking
 @subsection Directory Tracking
@@ -937,14 +969,14 @@ current directory.
 @vindex comint-scroll-to-bottom-on-input
   If the variable @code{comint-scroll-to-bottom-on-input} is
 non-@code{nil}, insertion and yank commands scroll the selected window
-to the bottom before inserting.
+to the bottom before inserting.  The default is @code{nil}.
 
 @vindex comint-scroll-show-maximum-output
   If @code{comint-scroll-show-maximum-output} is non-@code{nil}, then
 arrival of output when point is at the end tries to place the last line of
 text at the bottom line of the window, so as to show as much useful
-text as possible.  (This mimics the scrolling behavior of many
-terminals.)  The default is @code{nil}.
+text as possible.  (This mimics the scrolling behavior of most
+terminals.)  The default is @code{t}.
 
 @vindex comint-move-point-for-output
   By setting @code{comint-move-point-for-output}, you can opt for
@@ -1119,8 +1151,11 @@ temporarily visible, but will be erased when you hit return.  (This
 happens automatically; there is no special password processing.)
 
   When you log in to a different machine, you need to specify the type
-of terminal you're using.  Terminal types @samp{ansi} or @samp{vt100}
-will work on most systems.
+of terminal you're using, by setting the @env{TERM} environment
+variable in the environment for the remote login command.  (If you use
+bash, you do that by writing the variable assignment before the remote
+login command, without separating comma.)  Terminal types @samp{ansi}
+or @samp{vt100} will work on most systems.
 
 @c   If you are talking to a Bourne-compatible
 @c shell, and your system understands the @env{TERMCAP} variable,
@@ -1185,7 +1220,7 @@ off directory tracking.
 
 @end ignore
 
-@node Emacs Server, Hardcopy, Shell, Top
+@node Emacs Server, Printing, Shell, Top
 @section Using Emacs as a Server
 @pindex emacsclient
 @cindex Emacs as a server
@@ -1247,6 +1282,14 @@ kills it if the file name matches the regular expression
   If you set the variable @code{server-window} to a window or a frame,
 @kbd{C-x #} displays the server buffer in that window or in that frame.
 
+@vindex server-name
+  You can run multiple Emacs servers on the same machine by giving
+each one a unique ``server name'', using the variable
+@code{server-name}.  For example, @kbd{M-x set-variable @key{RET}
+server-name @key{RET} foo @key{RET}} sets the server name to
+@samp{foo}.  The @code{emacsclient} program can visit a server by name
+using the @samp{-s} option.  @xref{Invoking emacsclient}.
+
   While @code{mail} or another application is waiting for
 @code{emacsclient} to finish, @code{emacsclient} does not read terminal
 input.  So the terminal that @code{mail} was using is effectively
@@ -1277,7 +1320,7 @@ in Emacs.  Note that server buffers created in this way are not killed
 automatically when you finish with them.
 
 @menu
-* Invoking emacsclient::
+* Invoking emacsclient:: Emacs client startup options.
 @end menu
 
 @node Invoking emacsclient,, Emacs Server, Emacs Server
@@ -1329,19 +1372,25 @@ open the given files with the option @samp{--display=@var{DISPLAY}}.
 This can be used typically when connecting from home to an Emacs
 server running on your machine at your workplace.
 
+If there is more than one Emacs server running, you can specify a
+server name with the option @samp{-s @var{name}}.
+
 You can also use @code{emacsclient} to execute any piece of Emacs Lisp
 code, using the option @samp{--eval}.  When this option is given, the
 rest of the arguments is not taken as a list of files to visit but as
 a list of expressions to evaluate.
 
-@node Hardcopy, PostScript, Emacs Server, Top
-@section Hardcopy Output
+@node Printing, Sorting, Emacs Server, Top
+@section Printing Hard Copies
 @cindex hardcopy
+@cindex printing
 
-  The Emacs commands for making hardcopy let you print either an entire
-buffer or just part of one, either with or without page headers.
-See also the hardcopy commands of Dired (@pxref{Misc File Ops})
-and the diary (@pxref{Diary Commands}).
+  Emacs provides commands for printing hard copies of either an entire
+buffer or just part of one, with or without page headers.  You can
+invoke the printing commands directly, as detailed in the following
+section, or using the @samp{File} menu on the menu bar.  See also the
+hardcopy commands of Dired (@pxref{Misc File Ops}) and the diary
+(@pxref{Displaying the Diary}).
 
 @table @kbd
 @item M-x print-buffer
@@ -1388,7 +1437,13 @@ whether to supply @samp{-T} and @samp{-J} options (suitable for
 @code{lpr-add-switches} should be @code{nil} if your printer program is
 not compatible with @code{lpr}.
 
-@node PostScript, PostScript Variables, Hardcopy, Top
+@menu
+* PostScript::          Printing buffers or regions as PostScript.
+* PostScript Variables:: Customizing the PostScript printing commands.
+* Printing Package::     An optional advanced printing interface.
+@end menu
+
+@node PostScript, PostScript Variables,, Printing
 @section PostScript Hardcopy
 
   These commands convert buffer contents to PostScript,
@@ -1452,7 +1507,7 @@ supports ISO 8859-1 characters.
   The following section describes variables for customizing these commands.
 @end ifinfo
 
-@node PostScript Variables, Sorting, PostScript, Top
+@node PostScript Variables, Printing Package, PostScript, Printing
 @section Variables for PostScript Hardcopy
 
 @vindex ps-lpr-command
@@ -1544,7 +1599,34 @@ includes a single directory @file{/usr/local/share/emacs/fonts/bdf}.
   Many other customization variables for these commands are defined and
 described in the Lisp files @file{ps-print.el} and @file{ps-mule.el}.
 
-@node Sorting, Narrowing, PostScript Variables, Top
+@node Printing Package,, PostScript Variables, Printing
+@section Printing Package
+@cindex Printing package
+
+  The basic Emacs facilities for printing hardcopy can be extended
+using the Printing package.  This provides an easy-to-use interface
+for choosing what to print, previewing PostScript files before
+printing, and setting various printing options such as print headers,
+landscape or portrait modes, duplex modes, and so forth.  On GNU/Linux
+or Unix systems, the Printing package relies on the @file{gs} and
+@file{gv} utilities, which are distributed as part of the GhostScript
+program.  On MS-Windows, the @file{gstools} port of Ghostscript can be
+used.
+
+@findex pr-interface
+  To use the Printing package, add @code{(require 'printing)} to your
+init file (@pxref{Init File}), followed by @code{(pr-update-menus)}.
+This function replaces the usual printing commands in the menu bar
+with a @samp{Printing} submenu that contains various printing options.
+You can also type @kbd{M-x pr-interface RET}; this creates a
+@samp{*Printing Interface*} buffer, similar to a customization buffer,
+where you can set the printing options.  After selecting what and how
+to print, you start the print job using the @samp{Print} button (click
+@kbd{mouse-2} on it, or move point over it and type @kbd{RET}).  For
+further information on the various options, use the @samp{Interface
+Help} button.
+
+@node Sorting, Narrowing, Printing, Top
 @section Sorting Text
 @cindex sorting
 
@@ -1926,7 +2008,15 @@ another directory by typing @kbd{M-x desktop-change-dir}.  Typing
 @kbd{M-x desktop-revert} reverts to the desktop previously reloaded.
 
   Specify the option @samp{--no-desktop} on the command line when you
-don't want it to reload any saved desktop.
+don't want it to reload any saved desktop.  This turns off
+@code{desktop-save-mode} for the current session.
+
+@vindex desktop-restore-eager
+  By default, all the buffers in the desktop are restored at one go.
+However, this may be slow if there are a lot of buffers in the
+desktop.  You can specify the maximum number of buffers to restore
+immediately with the variable @code{desktop-restore-eager}; the
+remaining buffers are restored ``lazily,'' when Emacs is idle.
 
 @findex desktop-clear
 @vindex desktop-globals-to-clear
@@ -1938,6 +2028,9 @@ preserve certain buffers, customize the variable
 @code{desktop-clear-preserve-buffers-regexp}, whose value is a regular
 expression matching the names of buffers not to kill.
 
+  If you want to save minibuffer history from one session to
+another, use the @code{savehist} library.
+
 @node Recursive Edit, Emulation, Saving Emacs Sessions, Top
 @section Recursive Editing Levels
 @cindex recursive editing level
@@ -2048,42 +2141,6 @@ Emacs key bindings are still available.  The EDT emulation rebindings
 are done in the global keymap, so there is no problem switching
 buffers or major modes while in EDT emulation.
 
-@item ``PC'' bindings
-@findex pc-bindings-mode
-@cindex ``PC'' key bindings
-The command @kbd{M-x pc-bindings-mode} sets up certain key bindings
-for ``PC compatibility''---what people are often used to on PCs---as
-follows: @kbd{M-Backspace} does undo, and @kbd{C-Escape} does
-@code{list-buffers}.
-
-@item PC Selection mode
-@findex pc-selection-mode
-@cindex PC Selection minor mode
-@cindex mode, PC selection
-@cindex selection, PC
-The command @kbd{M-x pc-selection-mode} toggles a global minor mode
-that emulates the mark, copy, cut and paste commands of various other
-systems---an interface known as CUA.  It establishes the key bindings
-of PC mode, and also modifies the bindings of the cursor keys and the
-@kbd{next}, @kbd{prior}, @kbd{home} and @kbd{end} keys.  It does not
-provide the full set of CUA key bindings---the fundamental Emacs keys
-@kbd{C-c}, @kbd{C-v} and @kbd{C-x} are not changed.
-
-The standard keys for moving around (@kbd{right}, @kbd{left},
-@kbd{up}, @kbd{down}, @kbd{home}, @kbd{end}, @kbd{prior}, @kbd{next},
-called ``move-keys'') deactivate the mark in PC selection mode.
-However, using @kbd{Shift} together with the ``move keys'' activates
-the region over which they move.  The copy, cut and paste functions
-are available on @kbd{C-insert}, @kbd{S-delete} and @kbd{S-insert}
-respectively.
-
-Turning @code{pc-selection-mode} off restores the old key bindings of
-these keys.
-
-@cindex s-region package
-The @code{s-region} package provides similar, but less complete,
-facilities.
-
 @item TPU (DEC VMS editor)
 @findex tpu-edt-on
 @cindex TPU
@@ -2133,7 +2190,7 @@ not use it.
 key bindings.
 @end table
 
-@node Hyperlinking, Dissociated Press, Emulation, Top
+@node Hyperlinking, Thumbnails, Emulation, Top
 @section Hyperlinking and Navigation Features
 
 @cindex hyperlinking
@@ -2299,7 +2356,76 @@ Display a menu of files and URLs mentioned in current buffer, then
 find the one you select (@code{ffap-menu}).
 @end table
 
-@node Dissociated Press, Amusements, Hyperlinking, Top
+@node Thumbnails, Dissociated Press, Hyperlinking, Top
+@section Viewing Images as Thumbnails
+@cindex tumme mode
+@cindex thumbnails
+
+  Tumme is a facility for browsing image files.  It provides viewing
+the images either as thumbnails or in full size, either inside Emacs
+or through an external viewer.
+
+  To enter Tumme, type @kbd{M-x tumme}.  It prompts for a directory;
+specify one that has images files.  This creates thumbnails for all
+the images in that directory, and displays them all in the ``thumbnail
+buffer''.  This takes a long time if the directory contains many image
+files, and it asks for confirmation if the number of image files
+exceeds @code{tumme-show-all-from-dir-max-files}.
+
+@kindex C-t d @r{(Tumme)}
+@findex tumme-display-thumbs
+  You can also enter Tumme through Dired.  Mark the image files you
+want to look at, using @kbd{m} as usual, then type @kbd{C-t d}
+(@code{tumme-display-thumbs}).  This too creates and switches to
+a buffer containing thumbnails, corresponding to the marked files.
+
+  With point in the thumbnail buffer, type @kbd{RET}
+(@code{tumme-display-thumbnail-original-image}) to display a sized
+version of it in another window.  This sizes the image to fit the
+window.  Use the arrow keys to move around in the buffer.  For easy
+browing, type @kbd{SPC} (@code{tumme-display-next-thumbnail-original})
+to advance and display the next image.  Typing @kbd{DEL}
+(@code{tumme-display-previous-thumbnail-original}) backs up to the
+previous thumbnail and displays that instead.
+
+@vindex tumme-external-viewer
+  To view and the image in its original size, either provide a prefix
+argument (@kbd{C-u}) before pressing @kbd{RET}, or type @kbd{C-@key{RET}}
+(@code{tumme-thumbnail-display-external}) to display the image in an
+external viewer.  You must first configure
+@code{tumme-external-viewer}.
+
+  You can delete images through Tumme also.  Type @kbd{d}
+(@code{tumme-flag-thumb-original-file}) to flag the image file for
+deletion in the Dired buffer.  You can also delete the thumbnail image
+from the thumbnail buffer with @kbd{C-d} (@code{tumme-delete-char}).
+
+  More advanced features include @dfn{image tags}, which are metadata
+used to categorize image files.  The tags are stored in a plain text
+file configured by @code{tumme-db-file}.
+
+  To tag image files, mark them in the dired buffer (you can also mark
+files in Dired from the thumbnail buffer by typing @kbd{m}) and type
+@kbd{C-t t} (@code{tumme-tag-files}).  You will be prompted for a tag.
+To mark files having a certain tag, type @kbd{C-t f}
+(@code{tumme-mark-tagged-files}).  After marking image files with a
+certain tag, you can use @kbd{C-t d} to view them.
+
+  You can also tag a file directly from the thumbnail buffer by typing
+@kbd{t t} and you can remove a tag by typing @kbd{t r}.  There is also
+a special ``tag'' called ``comment'' for each file (it is not a tag in
+the exact same sense as the other tags, it is handled slightly
+different).  That is used to enter a comment or description about the
+image.  You comment a file from the thumbnail buffer by typing
+@kbd{c}.  You will be prompted for a comment.  Type @kbd{C-t c} to add
+a comment from Dired (@code{tumme-dired-comment-files}).
+
+  Tumme also provides simple image manipulation.  In the thumbnail
+buffer, type @kbd{L} to rotate the original image 90 degrees anti
+clockwise, and @kbd{R} to rotate it 90 degrees clockwise.  This
+rotation is lossless, and uses an external utility called JpegTRAN.
+
+@node Dissociated Press, Amusements, Thumbnails, Top
 @section Dissociated Press
 
 @findex dissociated-press
@@ -2324,12 +2450,13 @@ That is, if it has just output `president' and then decides to jump
 to a different point in the file, it might spot the `ent' in `pentagon'
 and continue from there, producing `presidentagon'.@footnote{This
 dissociword actually appeared during the Vietnam War, when it was very
-appropriate.}  Long sample texts produce the best results.
+appropriate.  Bush has made it appropriate again.}  Long sample texts
+produce the best results.
 
 @cindex againformation
   A positive argument to @kbd{M-x dissociated-press} tells it to operate
 character by character, and specifies the number of overlap characters.  A
-negative argument tells it to operate word by word and specifies the number
+negative argument tells it to operate word by word, and specifies the number
 of overlap words.  In this mode, whole words are treated as the elements to
 be permuted, rather than characters.  No argument is equivalent to an
 argument of two.  For your againformation, the output goes only into the
@@ -2338,13 +2465,13 @@ buffer @samp{*Dissociation*}.  The buffer you start with is not changed.
 @cindex Markov chain
 @cindex ignoriginal
 @cindex techniquitous
-  Dissociated Press produces nearly the same results as a Markov chain
-based on a frequency table constructed from the sample text.  It is,
-however, an independent, ignoriginal invention.  Dissociated Press
+  Dissociated Press produces results fairly like those of a Markov
+chain based on a frequency table constructed from the sample text.  It
+is, however, an independent, ignoriginal invention.  Dissociated Press
 techniquitously copies several consecutive characters from the sample
-between random choices, whereas a Markov chain would choose randomly for
-each word or character.  This makes for more plausible sounding results,
-and runs faster.
+between random choices, whereas a Markov chain would choose randomly
+for each word or character.  This makes for more plausible sounding
+results, and runs faster.
 
 @cindex outragedy
 @cindex buggestion
@@ -2353,7 +2480,7 @@ and runs faster.
 @cindex developediment
 @cindex userenced
   It is a mustatement that too much use of Dissociated Press can be a
-developediment to your real work.  Sometimes to the point of outragedy.
+developediment to your real work, sometimes to the point of outragedy.
 And keep dissociwords out of your documentation, if you want it to be well
 userenced and properbose.  Have fun.  Your buggestions are welcome.
 
@@ -2377,7 +2504,7 @@ which plays the game Go Moku with you.
 @findex mpuz
 @findex 5x5
 @cindex puzzles
-  @kbd{M-x blackbox}, @kbd{M-x mpuz} and @kbd{M-x 5x5} are kinds of puzzles.
+  @kbd{M-x blackbox}, @kbd{M-x mpuz} and @kbd{M-x 5x5} are puzzles.
 @code{blackbox} challenges you to determine the location of objects
 inside a box by tomography.  @code{mpuz} displays a multiplication
 puzzle with letters standing for digits in a code that you must