summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
Diffstat (limited to 'man')
-rw-r--r--man/ChangeLog414
-rw-r--r--man/Makefile.in11
-rw-r--r--man/abbrevs.texi4
-rw-r--r--man/ack.texi25
-rw-r--r--man/ada-mode.texi4
-rw-r--r--man/anti.texi4
-rw-r--r--man/autotype.texi4
-rw-r--r--man/back.texi4
-rw-r--r--man/basic.texi10
-rw-r--r--man/buffers.texi42
-rw-r--r--man/building.texi129
-rw-r--r--man/calc.texi5
-rw-r--r--man/calendar.texi75
-rw-r--r--man/cc-mode.texi5008
-rw-r--r--man/cl.texi8
-rw-r--r--man/cmdargs.texi186
-rw-r--r--man/commands.texi34
-rw-r--r--man/custom.texi295
-rw-r--r--man/dired-x.texi49
-rw-r--r--man/dired.texi40
-rw-r--r--man/display.texi36
-rw-r--r--man/doclicense.texi4
-rw-r--r--man/ebrowse.texi4
-rw-r--r--man/ediff.texi12
-rw-r--r--man/emacs-mime.texi4
-rw-r--r--man/emacs.texi44
-rw-r--r--man/entering.texi4
-rw-r--r--man/eshell.texi9
-rw-r--r--man/eudc.texi4
-rw-r--r--man/faq.texi32
-rw-r--r--man/files.texi69
-rw-r--r--man/fixit.texi6
-rw-r--r--man/forms.texi4
-rw-r--r--man/frames.texi51
-rw-r--r--man/glossary.texi53
-rw-r--r--man/gnu.texi4
-rw-r--r--man/gnus-faq.texi3
-rw-r--r--man/gnus.texi4
-rw-r--r--man/help.texi32
-rw-r--r--man/idlwave.texi4
-rw-r--r--man/indent.texi4
-rw-r--r--man/info.texi80
-rw-r--r--man/killing.texi8
-rw-r--r--man/m-x.texi4
-rw-r--r--man/macos.texi6
-rw-r--r--man/maintaining.texi4
-rw-r--r--man/major.texi4
-rw-r--r--man/makefile.w32-in329
-rw-r--r--man/mark.texi5
-rw-r--r--man/message.texi4
-rw-r--r--man/mh-e.texi7
-rw-r--r--man/mini.texi12
-rw-r--r--man/misc.texi110
-rw-r--r--man/msdog.texi13
-rw-r--r--man/mule.texi120
-rw-r--r--man/pcl-cvs.texi13
-rw-r--r--man/picture.texi4
-rw-r--r--man/programs.texi58
-rw-r--r--man/reftex.texi3
-rw-r--r--man/regs.texi4
-rw-r--r--man/rmail.texi6
-rw-r--r--man/sc.texi4
-rw-r--r--man/screen.texi28
-rw-r--r--man/search.texi154
-rw-r--r--man/sending.texi8
-rw-r--r--man/ses.texi28
-rw-r--r--man/smtpmail.texi24
-rw-r--r--man/speedbar.texi11
-rw-r--r--man/texinfo.tex6
-rw-r--r--man/text.texi7
-rw-r--r--man/tramp.texi395
-rw-r--r--man/trampver.texi10
-rw-r--r--man/trouble.texi12
-rw-r--r--man/vip.texi8
-rw-r--r--man/viper.texi8
-rw-r--r--man/widget.texi47
-rw-r--r--man/windows.texi4
-rw-r--r--man/woman.texi31
-rw-r--r--man/xresources.texi46
79 files changed, 5380 insertions, 2983 deletions
diff --git a/man/ChangeLog b/man/ChangeLog
index 3b55fff5d12..66ff49e2ced 100644
--- a/man/ChangeLog
+++ b/man/ChangeLog
@@ -1,3 +1,402 @@
+2004-04-05 Kim F. Storm <storm@cua.dk>
+
+ * custom.texi (File Variables): Add safe-local-eval-forms.
+
+2004-04-05 Jesper Harder <harder@ifa.au.dk>
+
+ * info.texi (Info Search): Add info-apropos.
+
+2004-04-02 Luc Teirlinck <teirllm@auburn.edu>
+
+ * files.texi (Reverting): Correct description of revert-buffer's
+ handling of point.
+
+2004-03-22 Juri Linkov <juri@jurta.org>
+
+ * emacs.texi (Top): Add `Misc X'.
+
+ * faq.texi, trouble.texi: Fix help key bindings.
+
+ * glossary.texi: Improve references.
+
+ * help.texi: Sync keywords with finder.el.
+
+ * mini.texi (Completion): Add description for menu items.
+
+ * misc.texi (Browse-URL, FFAP): Add information about keywords.
+
+ * sending.texi (Mail Methods): Fix xref to Message manual.
+
+2004-03-17 Luc Teirlinck <teirllm@auburn.edu>
+
+ * info.texi (Advanced): Replace @unnumberedsubsec by @subheading
+ (as suggested by Karl Berry). Update information about colored
+ stars in menus. Add new subheading describing M-n.
+
+2004-03-12 Richard M. Stallman <rms@gnu.org>
+
+ * cl.texi (Top): Rename top node's title.
+
+ * buffers.texi (Misc Buffer): Add index entry for rename-uniquely.
+
+2004-03-08 Karl Berry <karl@gnu.org>
+
+ * info.texi: \input texinfo.tex instead of just texinfo, to avoid
+ problems making the texinfo distribution.
+
+2004-03-04 Richard M. Stallman <rms@gnu.org>
+
+ * search.texi (Regexps): Explain that ^ and $ have their
+ special meanings only in certain contexts.
+
+ * programs.texi (Expressions): Doc C-M-SPC as alias for C-M-@.
+
+ * mule.texi (Specify Coding): Doc C-x RET F.
+
+ * buffers.texi (Misc Buffer): Explain use of M-x rename-uniquely
+ for multiple compile and grep buffers.
+ (Indirect Buffers): Don't recommand clone-indirect-buffer
+ for multiple compile and grep buffers.
+
+2004-02-29 Simon Josefsson <jas@extundo.com>
+
+ * smtpmail.texi (Authentication): Changed the list of supported
+ authentication mechanisms from CRAM-MD5, PLAIN and LOGIN-MD5 to
+ CRAM-MD5 and LOGIN, tiny patch from Andreas Voegele
+ <voegelas@gmx.net>.
+
+2004-02-29 Juanma Barranquero <lektu@terra.es>
+
+ * makefile.w32-in (mostlyclean, clean, maintainer-clean): Use
+ $(DEL) instead of rm, and ignore exit code.
+
+2004-02-29 Kai Grossjohann <kgrossjo@eu.uu.net>
+
+ Tramp version 2.0.39 released.
+
+2004-02-29 Michael Albinus <Michael.Albinus@alcatel.de>
+
+ * tramp.texi (Customizing Completion): Explain new functions
+ `tramp-parse-shostkeys' and `tramp-parse-sknownhosts'.
+ (all): Savannah URLs unified to "http://savannah.nongnu.org".
+ (Top): Refer to Savannah mailing list as the major one. Mention
+ older mailing lists in HTML mode only.
+ (Auto-save and Backup): Add auto-save. Based on wording of Kai.
+ (Frequently Asked Questions): Remote hosts must not be Unix-like
+ for "smb" method.
+ (Password caching): New node.
+ (External transfer methods): Refer to password caching for "smb"
+ method.
+
+2004-02-23 Nick Roberts <nick@nick.uklinux.net>
+
+ * building.texi (Watch Expressions): Update.
+
+2004-02-21 Juri Linkov <juri@jurta.org>
+
+ * cmdargs.texi (Action Arguments): Add alias --find-file. Add
+ --directory, --help, --version. Move text about command-line-args
+ to Command Arguments.
+ (Initial Options): Remove alias -batch. Add @cindex for --script.
+ Fix @cindex for -q. Add --no-desktop. Add alias --no-multibyte,
+ --no-unibyte.
+ (Window Size X): Join -g and --geometry. Add @cindex.
+ (Borders X): Fix @cindex for -ib. Add @cindex for -bw.
+ (Title X): Remove alias -title.
+ (Icons X): Remove alias -iconic.
+ (Misc X): New node.
+
+2004-02-17 Karl Berry <karl@gnu.org>
+
+ * info.texi (Help-Int): mention the new line number feature.
+
+2004-02-15 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
+
+ * frames.texi (Drag and drop): Add Motif to list of supported
+ protocols.
+
+2004-02-14 Jonathan Yavner <jyavner@member.fsf.org>
+
+ * ses.texi (Advanced Features): New functionality for
+ ses-set-header-row (defaults to current row unless C-u used).
+ (Acknowledgements): Added Stefan Monnier.
+
+2004-02-03 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
+
+ * frames.texi (Drag and drop): New section.
+
+2004-01-24 Richard M. Stallman <rms@gnu.org>
+
+ * emacs.texi (Acknowledgments): Renamed from Acknowledgements.
+ Include it only @ifnotinfo. Patch the preceding and following
+ node headers to point to each other.
+
+2004-01-11 Glenn Morris <gmorris@ast.cam.ac.uk>
+
+ * calendar.texi (Appointments): Update section.
+
+2003-12-29 Kevin Ryde <user42@zip.com.au>
+
+ * viper.texi (Vi Macros): Fix reference to the Emacs manual.
+
+ * programs.texi (C Modes): Fix the xref.
+
+2003-12-23 Nick Roberts <nick@nick.uklinux.net>
+
+ * building.texi (Watch Expressions): Update.
+ (Commands of GUD): Include use of toolbar + breakpoints set from
+ fringe/margin.
+
+2003-12-03 Andre Spiegel <spiegel@gnu.org>
+
+ * files.texi: Say how to disable VC. Suggested by Alan Mackenzie
+ <acm@muc.de>.
+
+2003-11-30 Kai Grossjohann <kai.grossjohann@gmx.net>
+
+ Tramp version 2.0.38 released.
+
+ * tramp.texi (Remote shell setup): Warn of environment variables
+ FRUMPLE if user frumple exists. Suggested by Sven Gabriel
+ <sven.gabriel@imk.fzk.de>.
+ (Configuration): Tramp now chooses base64/uuencode
+ automatically. Update wording accordingly.
+ (Top): More description for the `Default Method' menu entry.
+ (Default Method): Use @code, not @var, for Lisp variables.
+ (Default Method): New subsection `Which method is the right one
+ for me?' Suggested by Christian Kirsch.
+ (Configuration): Pointer to new subsection added.
+ (Default Method): Too many "use" in one sentence.
+ Rephrase. Reported by Christian Kirsch.
+ (Filename Syntax): Old `su' example is probably a left-over from
+ the sm/su method naming. Replace with `ssh', instead.
+ (External transfer methods, Auto-save and Backup):
+ Typo fixes.
+
+2003-11-02 Michael Albinus <Michael.Albinus@alcatel.de>
+
+ * tramp.texi (all): Harmonize all occurences of @tramp{}.
+ (Top): Mention japanese manual only if flag `jamanual' is set.
+ Insert section `Japanese manual' in menu.
+
+2003-11-29 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
+
+ * frames.texi (Dialog Boxes): Added use-file-dialog.
+
+2003-11-26 Thien-Thi Nguyen <ttn@gnu.org>
+
+ * eshell.texi (Known Problems): Add doc item.
+
+2003-11-22 Martin Stjernholm <bug-cc-mode@gnu.org>
+
+ * ack.texi: Note that Alan Mackenzie contributed the AWK support
+ in CC Mode.
+
+2003-11-22 Martin Stjernholm <bug-cc-mode@gnu.org>
+
+ * cc-mode.texi: Updated for CC Mode 5.30.
+
+ Note: Please refrain from doing purely cosmetic changes like
+ removing trailing whitespace in this manual; it clobbers cvs
+ merging for no good reason.
+
+2003-11-02 Jesper Harder <harder@ifa.au.dk> (tiny change)
+
+ * man/ack.texi, man/basic.texi, man/cmdargs.texi:
+ * man/commands.texi, man/custom.texi, man/display.texi:
+ * man/ediff.texi, man/emacs.texi, man/faq.texi, man/files.texi:
+ * man/frames.texi, man/glossary.texi, man/killing.texi:
+ * man/macos.texi, man/mark.texi, man/misc.texi, man/msdog.texi:
+ * man/mule.texi, man/rmail.texi, man/search.texi:
+ * man/sending.texi, man/text.texi, man/tramp.texi:
+ * man/trouble.texi, man/vip.texi, man/viper.texi, man/widget.texi:
+ * man/woman.texi: Replace @sc{ascii} and ASCII with @acronym{ASCII}.
+
+2003-11-01 Alan Mackenzie <acm@muc.de>
+
+ * search.texi (Scrolling During Incremental Search): Document a
+ new scrolling facility in isearch mode.
+
+2003-10-26 Karl Berry <karl@gnu.org>
+
+ * info.texi (Info Search): echo area, not echo are. From Debian
+ diff.
+
+2003-10-26 Per Abrahamsen <abraham@dina.kvl.dk>
+
+ * widget.texi (Defining New Widgets): Document new beavior of
+ :buttons and :children keywords.
+
+2003-10-22 Miles Bader <miles@gnu.org>
+
+ * Makefile.in (info): Move before $(top_srcdir)/info.
+
+2003-10-22 Nick Roberts <nick@nick.uklinux.net>
+
+ * building.texi (Watch Expressions): Update section on data display
+ to reflect code changes (GDB Graphical Interface).
+
+2003-10-17 Thien-Thi Nguyen <ttn@gnu.org>
+
+ * tramp.texi (Inline methods): Small grammar fix.
+ (External transfer methods): Likewise.
+
+2003-10-13 Richard M. Stallman <rms@gnu.org>
+
+ * xresources.texi (GTK resources): Clean up previous change.
+
+2003-10-12 Jan Dj,Ad(Brv <jan.h.d@swipnet.se>
+
+ * xresources.texi (GTK resources): Added a note that some themes
+ disallow customizations. Added scroll theme example.
+
+2003-10-08 Nick Roberts <nick@nick.uklinux.net>
+
+ * speedbar.texi: Remove paragraph for GUD that is no longer true.
+
+2003-10-06 Luc Teirlinck <teirllm@auburn.edu>
+
+ * texinfo.tex: Replace `%' in arch tagline by @ignore.
+
+2003-09-30 Richard M. Stallman <rms@gnu.org>
+
+ * dired-x.texi (Miscellaneous Commands): Delete M-g, w, T.
+
+ * widget.texi (User Interface): Fix typos.
+
+ * pcl-cvs.texi, cl.texi, woman.texi, ediff.texi: Fix @strong{Note:}.
+
+ * cmdargs.texi (General Variables): Remove MAILRC envvar.
+
+ * misc.texi (Saving Emacs Sessions): Shorten the section,
+ collapsing back into one node.
+
+2003-09-30 Lars Hansen <larsh@math.ku.dk>
+
+ * misc.texi: Section "Saving Emacs Sessions" rewritten.
+
+2003-09-29 Jan D. <jhd@gaffa.gaia.swipnet.se>
+
+ * xresources.texi (GTK names in Emacs): Correct typo.
+
+2003-09-29 Thien-Thi Nguyen <ttn@gnu.org>
+
+ * pcl-cvs.texi (Selected Files): Fix typo.
+
+2003-09-24 Luc Teirlinck <teirllm@mail.auburn.edu>
+
+ * cmdargs.texi (Font X): Mention new default font. More
+ fully describe long font names, wildcard patterns and the
+ problems involved. (Result of discussion on emacs-devel.)
+
+2003-09-22 Luc Teirlinck <teirllm@mail.auburn.edu>
+
+ * emacs.texi (Acknowledgements): Correct typo.
+
+2003-09-22 Richard M. Stallman <rms@gnu.org>
+
+ * dired.texi (Misc Dired Commands): New node.
+ (Dired Navigation): Add dired-goto-file.
+
+ * files.texi (File Aliases, Misc File Ops): Add @cindex entries.
+
+ * emacs.texi (Acknowledgements): New node, split from Distribution.
+
+ * cmdargs.texi (Action Arguments): -f reads interactive args.
+
+2003-09-21 Karl Berry <karl@gnu.org>
+
+ * info.texi (] and [ commands): no period at end of section title.
+
+2003-09-08 Lute Kamstra <lute@gnu.org>
+
+ * screen.texi (Mode Line): Say that POS comes before LINE.
+ Mention `size-indication-mode'.
+ * display.texi (Optional Mode Line): Document
+ `size-indication-mode'.
+ * basic.texi (Position Info): Mention `size-indication-mode'.
+
+2003-09-07 Luc Teirlinck <teirllm@mail.auburn.edu>
+
+ * xresources.texi (Resources): Refer to `editres' man page.
+ (Lucid Resources): Update defaults. Expand desciption of
+ `shadowThickness'.
+
+2003-09-04 Miles Bader <miles@gnu.org>
+
+ * Makefile.in (top_srcdir): New variable.
+ ($(top_srcdir)/info): New rule.
+ (info): Depend on it.
+
+2003-09-03 Peter Runestig <peter@runestig.com>
+
+ * makefile.w32-in: New file.
+
+2003-08-29 Richard M. Stallman <rms@gnu.org>
+
+ * misc.texi (Saving Emacs Sessions): Correct previous change.
+
+2003-08-26 Per Abrahamsen <abraham@dina.kvl.dk>
+
+ * widget.texi (User Interface): Explain the need of static text
+ around an editable field.
+
+2003-08-19 Luc Teirlinck <teirllm@mail.auburn.edu>
+
+ * widget.texi (Basic Types): The argument to `:help-echo' can now
+ be a form that evaluates to a string.
+
+ * emacs.texi (Top): Update menu to reflect new Keyboard Macros
+ chapter.
+ (Intro): Include kmacro.texi after fixit.texi instead of after
+ custom.texi. (As suggested by Kim Storm.)
+
+2003-08-18 Luc Teirlinck <teirllm@mail.auburn.edu>
+
+ * fixit.texi (Fixit): Update `Next' pointer.
+ * files.texi (Files): Update `Previous' pointer.
+ * kmacro.texi (Keyboard Macros): Remove redundant node and
+ section.
+ * emacs.texi (Intro): Include kmacro.texi after custom.texi.
+ (Suggested by Kim Storm.)
+ * Makefile (EMACSSOURCES): Add kmacro.texi. (Suggested by Kim
+ Storm.)
+
+2003-08-18 Kim F. Storm <storm@cua.dk>
+
+ * kmacro.texi: New file describing enhanced keyboard macro
+ functionality. Replaces old description in custom.texi.
+
+ * custom.texi (Customization): Add xref to Keyboard Macros chapter.
+ (Keyboard Macros): Move to new kmacro.texi file.
+
+ * emacs.texi (Keyboard Macros): Reference new keyboard macro topics.
+
+ * calc.texi (Queries in Macros): Update xref to keyboard macro query.
+
+2003-08-17 Edward M. Reingold <reingold@emr.cs.iit.edu>
+
+ * calendar.texi (Specified Dates): Add `calendar-goto-day-of-year'.
+
+2003-08-17 Alex Schroeder <alex@gnu.org>
+
+ * misc.texi (Saving Emacs Sessions): Manual M-x desktop-save not
+ required.
+
+2003-08-16 Richard M. Stallman <rms@gnu.org>
+
+ * dired-x.texi (Shell Command Guessing): Explain *.
+
+2003-08-16 Chunyu Wang <spr@db.cs.hit.edu.cn> (tiny change)
+
+ * pcl-cvs.texi (Log Edit Mode): Fix key binding for
+ log-edit-insert-changelog.
+
+2003-08-05 Richard M. Stallman <rms@gnu.org>
+
+ * programs.texi (Lisp Indent): Don't describe
+ lisp-indent-function property here. Use xref to Lisp Manual.
+
2003-08-03 Karl Berry <karl@gnu.org>
* info.texi: need @contents.
@@ -12,6 +411,7 @@
* buffers.texi (List Buffers): Fix previous change.
2003-07-20 Kai Gro,A_(Bjohann <kai.grossjohann@gmx.net>
+
Tramp version 2.0.36 released.
* tramp.texi (Remote shell setup): Explain about problems with
@@ -118,7 +518,7 @@
* faq.texi: Update copyright and maintenance details.
Update some package URLs, versions, and maintainers.
Remove many references to the Emacs Lisp Archive.
-
+
2003-04-23 Simon Josefsson <jas@extundo.com>
* smtpmail.texi: Fix license (the invariant sections mentioned has
@@ -174,11 +574,11 @@
(Installation): Explain what to do if files from the tramp/contrib
directory are needed.
-2003-02-23 Alex Schroeder <alex@emacswiki.org>
+2003-02-23 Alex Schroeder <alex@emacswiki.org>
* smtpmail.texi (How Mail Works): New.
-2003-02-22 Alex Schroeder <alex@emacswiki.org>
+2003-02-22 Alex Schroeder <alex@emacswiki.org>
* cmdargs.texi (General Variables): Document SMTPSERVER.
@@ -190,7 +590,7 @@
* Makefile.in: Build SMTP manual.
-2003-02-22 Alex Schroeder <alex@emacswiki.org>
+2003-02-22 Alex Schroeder <alex@emacswiki.org>
* sending.texi (Sending via SMTP): Explain MTA/MUA.
@@ -285,7 +685,7 @@
2002-08-27 Carsten Dominik <dominik@sand.science.uva.nl>
- * reftex.texi: Update to RefTeX 4.19
+ * reftex.texi: Update to RefTeX 4.19.
2002-06-17 Kai Gro,b_(Bjohann <Kai.Grossjohann@CS.Uni-Dortmund.DE>
@@ -833,10 +1233,12 @@
University of Washington.
;; Local Variables:
-;; coding: iso-2022-7bit-unix
+;; coding: iso-2022-7bit
;; End:
Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001
Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification,
are permitted provided the copyright notice and this notice are preserved.
+
+;;; arch-tag: f1d62776-3ed5-4811-9d96-267252577dbd
diff --git a/man/Makefile.in b/man/Makefile.in
index bb179e7d545..e1b971010b0 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -25,6 +25,7 @@
# utility programs is expected to be in ${srcdir}/lib-src. This is
# set by the configure script's `--srcdir' option.
srcdir=@srcdir@
+top_srcdir=@top_srcdir@
# Tell make where to find source files; this is needed for the makefiles.
VPATH=@srcdir@
@@ -99,9 +100,13 @@ EMACSSOURCES= \
${srcdir}/msdog.texi \
${srcdir}/gnu.texi \
${srcdir}/glossary.texi \
- ${srcdir}/ack.texi
+ ${srcdir}/ack.texi \
+ ${srcdir}/kmacro.texi
-info: $(INFO_TARGETS)
+info: $(top_srcdir)/info $(INFO_TARGETS)
+
+$(top_srcdir)/info:
+ mkdir $@
dvi: $(DVI_TARGETS)
@@ -301,3 +306,5 @@ maintainer-clean: distclean
# That caused trouble because this is run entirely in the source directory.
# Since we expect to get texi2dvi from elsewhere,
# it is ok to expect texindex from elsewhere also.
+
+# arch-tag: 19cdb89e-4acb-448e-b0cc-2ddc05948ee2
diff --git a/man/abbrevs.texi b/man/abbrevs.texi
index 55f9712ef92..ce6465564f5 100644
--- a/man/abbrevs.texi
+++ b/man/abbrevs.texi
@@ -445,3 +445,7 @@ customize dynamic abbreviation to handle optional prefixes by setting
the variable @code{dabbrev-abbrev-skip-leading-regexp}. Its value
should be a regular expression that matches the optional prefix that
dynamic abbreviation should ignore.
+
+@ignore
+ arch-tag: 638e0079-9540-48ec-9166-414083e16445
+@end ignore
diff --git a/man/ack.texi b/man/ack.texi
index 0f8da05f455..5d64b38cdf7 100644
--- a/man/ack.texi
+++ b/man/ack.texi
@@ -26,7 +26,7 @@ for news articles and @file{cpp.el} which hides or highlights parts of
C programs according to preprocessor conditionals.
@item
-Tomas Abrahamsson wrote @file{artist.el}, a package for producing ASCII
+Tomas Abrahamsson wrote @file{artist.el}, a package for producing @acronym{ASCII}
art with a mouse or with keyboard keys.
@item
@@ -359,7 +359,7 @@ Odd Gripenstam wrote @file{dcl-mode.el} for editing DCL command files.
@item
Michael Gschwind wrote @file{iso-cvt.el}, a package to convert between
-the ISO 8859-1 character set and the notations for non-ASCII
+the ISO 8859-1 character set and the notations for non-@acronym{ASCII}
characters used by @TeX{} and net tradition, and @file{latin-2.el}, code
which sets up case-conversion and syntax tables for the ISO Latin-2
character set.
@@ -374,10 +374,10 @@ Doug Gwyn wrote the portable @code{alloca} implementation.
@item
Ken'ichi Handa implemented most of the support for international
character sets, and wrote @file{isearch-x.el}, a facility for searching
-non-ASCII text. Together with Naoto Takahashi, he wrote
-@file{quail.el}, a simple input facility for typing non-ASCII text from
-an ASCII keyboard. Ken'ichi also wrote @file{ps-bdf.el}, a BDF font
-support for printing non-ASCII text on a PostScript printer.
+non-@acronym{ASCII} text. Together with Naoto Takahashi, he wrote
+@file{quail.el}, a simple input facility for typing non-@acronym{ASCII} text from
+an @acronym{ASCII} keyboard. Ken'ichi also wrote @file{ps-bdf.el}, a BDF font
+support for printing non-@acronym{ASCII} text on a PostScript printer.
@item
Chris Hanson wrote @file{netuname.el}, a package to use HP-UX's Remote
@@ -396,7 +396,7 @@ command loop and appropriate help facilities,
@item
@file{emacsbug.el}, a package for reporting Emacs bugs,
@item
-@file{picture.el}, a mode for editing ASCII pictures, and
+@file{picture.el}, a mode for editing @acronym{ASCII} pictures, and
@item
@file{view.el}, a package for perusing files and buffers without editing
them.
@@ -619,6 +619,9 @@ Eric Ludlam wrote the Speedbar package and @file{checkdoc.el}, a package
for checking doc strings in Emacs Lisp programs.
@item
+Alan Mackenzie wrote the integrated AWK support in CC Mode.
+
+@item
Christopher J.@: Madsen wrote @file{decipher.el}, a package for cracking
simple substitution ciphers.
@@ -776,7 +779,7 @@ Erik Naggum wrote the time-conversion functions. He also wrote
@file{disp-table.el}, a package for dealing with display tables,
@file{latin-4.el} and @file{latin-5.el}, code which sets up
case-conversion and syntax tables for the ISO Latin-4 and Latin-5
-character sets, @file{mailheader.el}, a pacakage for parsing email
+character sets, @file{mailheader.el}, a package for parsing email
headers, and @file{parse-time.el}, a package for parsing time strings.
@item
@@ -1139,7 +1142,7 @@ contexts.
@item
Martin Stjernholm co-authored CC Mode, a major editing mode for C,
-C@t{++}, Objective-C, and Java code.
+C@t{++}, Objective-C, Java, Pike, CORBA IDL, and AWK code.
@item
Steve Strassman did not write @file{spook.el}, and even if he did, he
@@ -1412,3 +1415,7 @@ in the distribution.) We thank them for their generosity as well.
This list intended to mention every contributor of a major package or
feature we currently distribute; if you know of someone we have omitted,
please report that as a manual bug.
+
+@ignore
+ arch-tag: bb1d0fa4-0240-4992-b5d4-8602d1e3d4ba
+@end ignore
diff --git a/man/ada-mode.texi b/man/ada-mode.texi
index a1012b8fbff..a74150fe75a 100644
--- a/man/ada-mode.texi
+++ b/man/ada-mode.texi
@@ -1279,3 +1279,7 @@ However, this would not work on vxworks, for instance, where
@contents
@bye
+
+@ignore
+ arch-tag: 68cf0d8a-55cc-4190-a28d-4984fa56ed1e
+@end ignore
diff --git a/man/anti.texi b/man/anti.texi
index ff3f5db7cae..edf0031ee8c 100644
--- a/man/anti.texi
+++ b/man/anti.texi
@@ -146,3 +146,7 @@ one, @kbd{C-x e}.
To keep up with decreasing computer memory capacity and disk space, many
other functions and files have been eliminated in Emacs 21.3.
@end itemize
+
+@ignore
+ arch-tag: 32932bd9-46f5-41b2-8a0e-fb0cc4caeb29
+@end ignore
diff --git a/man/autotype.texi b/man/autotype.texi
index b8f59777242..e7df280f524 100644
--- a/man/autotype.texi
+++ b/man/autotype.texi
@@ -659,3 +659,7 @@ of the expansion possibilities.
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: 54001b27-5ef8-4a9d-a199-905d650fafba
+@end ignore
diff --git a/man/back.texi b/man/back.texi
index c3372d30c71..d586b9afd63 100644
--- a/man/back.texi
+++ b/man/back.texi
@@ -66,3 +66,7 @@
}
\eject\bye
+
+@ignore
+ arch-tag: e1830f4c-dc4a-4314-b706-a03c7e93f022
+@end ignore
diff --git a/man/basic.texi b/man/basic.texi
index 6029b76cfea..3ec6e47c5bb 100644
--- a/man/basic.texi
+++ b/man/basic.texi
@@ -572,6 +572,9 @@ point, and column of point (@code{what-cursor-position}).
@item M-x hl-line-mode
Enable or disable highlighting of the current line. @xref{Cursor
Display}.
+@item M-x size-indication-mode
+Toggle automatic display of the size of the buffer.
+@xref{Optional Mode Line}.
@end table
@findex what-page
@@ -620,7 +623,7 @@ Char: c (0143, 99, 0x63) point=21044 of 26883(78%) column 53
The four values after @samp{Char:} describe the character that follows
point, first by showing it and then by giving its character code in
-octal, decimal and hex. For a non-ASCII multibyte character, these are
+octal, decimal and hex. For a non-@acronym{ASCII} multibyte character, these are
followed by @samp{ext} and the character's representation, in hex, in
the buffer's coding system, if that coding system encodes the character
safely and with a single byte (@pxref{Coding Systems}). If the
@@ -662,7 +665,7 @@ point=26957 of 26956(100%) column 0
@cindex text properties at point
@w{@kbd{C-u C-x =}} displays additional information about a
character, including the character set name and the codes that
-identify the character within that character set; ASCII characters are
+identify the character within that character set; @acronym{ASCII} characters are
identified as belonging to the @code{ascii} character set. It also
shows the character's syntax, categories, and encodings both
internally in the buffer and externally if you save the file. It also
@@ -810,3 +813,6 @@ additional times, to delete a total of 80 characters, by typing @kbd{C-x
z z z}. The first @kbd{C-x z} repeats the command once, and each
subsequent @kbd{z} repeats it once again.
+@ignore
+ arch-tag: cda8952a-c439-41c1-aecf-4bc0d6482956
+@end ignore
diff --git a/man/buffers.texi b/man/buffers.texi
index 7bb6f519f4d..c2d2a3f76e3 100644
--- a/man/buffers.texi
+++ b/man/buffers.texi
@@ -217,14 +217,19 @@ the new name as a minibuffer argument. There is no default. If you
specify a name that is in use for some other buffer, an error happens and
no renaming is done.
- @kbd{M-x rename-uniquely} renames the current buffer to a similar name
-with a numeric suffix added to make it both different and unique. This
-command does not need an argument. It is useful for creating multiple
-shell buffers: if you rename the @samp{*Shell*} buffer, then do @kbd{M-x
-shell} again, it makes a new shell buffer named @samp{*Shell*};
-meanwhile, the old shell buffer continues to exist under its new name.
-This method is also good for mail buffers, compilation buffers, and most
-Emacs features that create special buffers with particular names.
+@findex rename-uniquely
+ @kbd{M-x rename-uniquely} renames the current buffer to a similar
+name with a numeric suffix added to make it both different and unique.
+This command does not need an argument. It is useful for creating
+multiple shell buffers: if you rename the @samp{*Shell*} buffer, then
+do @kbd{M-x shell} again, it makes a new shell buffer named
+@samp{*Shell*}; meanwhile, the old shell buffer continues to exist
+under its new name. This method is also good for mail buffers,
+compilation buffers, and most Emacs features that create special
+buffers with particular names. (With some of these features, such as
+@kbd{M-x compile}, @kbd{M-x grep} an @kbd{M-x info}, you need to
+switch to some other buffer before using the command, in order for it
+to make a different buffer.)
@findex view-buffer
@kbd{M-x view-buffer} is much like @kbd{M-x view-file} (@pxref{Misc
@@ -471,22 +476,21 @@ buffer, but killing an indirect buffer has no effect on its base buffer.
One way to use indirect buffers is to display multiple views of an
outline. @xref{Outline Views}.
-@cindex multiple @samp{*info*} and @samp{*Help*} buffers
A quick and handy way to make an indirect buffer is with the command
@kbd{M-x clone-indirect-buffer}. It creates and selects an indirect
buffer whose base buffer is the current buffer. With a numeric
argument, it prompts for the name of the indirect buffer; otherwise it
defaults to the name of the current buffer, modifying it by adding a
-@samp{<@var{n}>} prefix if required. @kbd{C-x 4 c}
+@samp{<@var{n}>} suffix if required. @kbd{C-x 4 c}
(@code{clone-indirect-buffer-other-window}) works like @kbd{M-x
-clone-indirect-buffer}, but it selects the cloned buffer in another
-window. These commands come in handy if you want to create new
-@samp{*info*} or @samp{*Help*} buffers, for example.
+clone-indirect-buffer}, but it selects the new buffer in another
+window.
- The more general way is with the command @kbd{M-x
-make-indirect-buffer}. It creates an indirect buffer from buffer
-@var{base-buffer}, under the name @var{indirect-name}. It prompts for
-both @var{base-buffer} and @var{indirect-name} using the minibuffer.
+ The more general way to make an indirect buffer is with the command
+@kbd{M-x make-indirect-buffer}. It creates an indirect buffer from
+buffer @var{base-buffer}, under the name @var{indirect-name}. It
+prompts for both @var{base-buffer} and @var{indirect-name} using the
+minibuffer.
@node Buffer Convenience
@section Convenience Features and Customization of Buffer Handling
@@ -601,3 +605,7 @@ provides a different and customizable mouse buffer menu which you may
prefer. It replaces the bindings of @code{mouse-buffer-menu},
normally on @kbd{C-Down-Mouse-1}, and the menu bar buffer menu. You
can customize the menu in the @code{msb} Custom group.
+
+@ignore
+ arch-tag: 08c43460-f4f4-4b43-9cb5-1ea9ad991695
+@end ignore
diff --git a/man/building.texi b/man/building.texi
index 5cadfbcc553..2985a04895c 100644
--- a/man/building.texi
+++ b/man/building.texi
@@ -398,7 +398,10 @@ commands of Shell mode are available (@pxref{Shell Mode}). GUD mode
also provides commands for setting and clearing breakpoints, for
selecting stack frames, and for stepping through the program. These
commands are available both in the GUD buffer and globally, but with
-different key bindings.
+different key bindings. It also has its own toolbar from which you
+can invoke the more common commands by clicking on the appropriate
+icon. This is particularly useful for repetitive commands like
+gud-next and gud-step and allows the user to hide the GUD buffer.
The breakpoint commands are normally used in source file buffers,
because that is the easiest way to specify where to set or clear the
@@ -535,6 +538,12 @@ be bizarre. See the GDB manual entry regarding @code{jump} for
details.
@end table
+If you started GDB with the command @code{gdba}, you can click
+@kbd{Mouse-1} on a line of the source buffer, in the fringe or display
+margin, to set a breakpoint there. If a breakpoint already exists on
+that line, this action will remove it.
+(@code{gdb-mouse-toggle-breakpoint}).
+
These commands interpret a numeric argument as a repeat count, when
that makes sense.
@@ -631,8 +640,7 @@ to know GDB commands.
@menu
* Breakpoints Buffer:: A breakpoint control panel.
* Stack Buffer:: Select a frame from the call stack.
-* Data Display:: Display and update expressions in their own buffer.
-* Display Buffer:: Control the displayed expressions.
+* Watch Expressions:: Monitor variable values in the speedbar.
* Other Buffers:: Input/output, locals, registers and assembler buffers.
* Layout:: Control the number of displayed buffers.
@end menu
@@ -681,59 +689,41 @@ associated source in the source buffer. Alternatively, click
locals buffer is displayed then its contents update to display the
variables that are local to the new frame.
-@node Data Display
-@subsubsection Data Display
-@cindex displaying expressions in GDB
+@node Watch Expressions
+@subsubsection Watch Expressions
+@cindex Watching expressions in GDB
If you want to see how a variable changes each time your program stops
-then place the cursor over the variable name and click on the display
-icon in the toolbar (@code{gud-display}).
-
-Each displayed expression has its own frame on a graphical display and
-its own buffer on a text-only terminal. Arrays and structures have
-their own display formats. To display an array as a slice, at the top
-of the display window, click @kbd{Mouse-2} on the array index that you
-want to restrict and you will be prompted in the mini-buffer for a
-start and a stop value. Click @kbd{Mouse-2} on a pointer to
-dereference it in the same frame/buffer. Click @kbd{S-Mouse-2} there
-to do the same thing but in a new frame/buffer. There are two special
-commands for these buffers:
-
-@table @kbd
-@item @kbd{v}
-@kindex v @r{(GDB data buffer)}
-@findex gdb-array-visualise
-Visualise an array using the graph program from plotutils if this is
-installed. This only works for one dimensional arrays
-(@code{gdb-array-visualise}).
-
-@item @kbd{q}
-@kindex q @r{(GDB data buffer)}
-@findex gdb-delete-expression
-Delete the displayed expression and the associated frame
-(@code{gdb-delete-expression}).
-@end table
-
-@node Display Buffer
-@subsubsection Display Buffer
-
-The display buffer shows the list of displayed expressions
-(@pxref{Auto Display,,, gdb, The GNU debugger}). As with the
-breakpoints, you can enable/disable or delete the displayed
-expressions:
-
-@table @kbd
-@item @key{SPC}
-@kindex SPC @r{(GDB display buffer)}
-@findex gdb-toggle-display
-Enable/disable the display at the current line
-(@code{gdb-toggle-display}).
-
-@item @kbd{d}
-@kindex d @r{(GDB display buffer)}
-@findex gdb-delete-display
-Delete the display at the current line (@code{gdb-delete-display}).
-@end table
+then place the cursor over the variable name and click on the watch
+icon in the toolbar (@code{gud-watch}).
+
+Each watch expression is displayed in the speedbar. Complex data
+types, such as arrays, structures and unions are represented in a tree
+format. To expand or contract a complex data type, click @kbd{Mouse-2}
+on the tag to the left of the expression.
+
+@kindex RET @r{(GDB speedbar)}
+@findex gdb-var-delete
+With the cursor over the root expression of a complex data type, type
+@key{D} to delete it from the speedbar
+(@code{gdb-var-delete}).
+
+@findex gdb-edit-value
+With the cursor over a simple data type or an element of a complex
+data type which holds a value, type @key{RET} or click @kbd{Mouse-2} to edit
+its value. A prompt for a new value appears in the mini-buffer
+(@code{gdb-edit-value}).
+
+If you set the variable @code{gdb-show-changed-values} to
+non-@code{nil} (the default value), then Emacs will use
+font-lock-warning-face to display values that have recently changed in
+the speedbar.
+
+If you set the variable @code{gdb-use-colon-colon-notation} to a
+non-@code{nil} value, then, in C, Emacs will use the
+FUNCTION::VARIABLE format to display variables in the speedbar.
+Since this does not work for variables defined in compound statements,
+the default value is @code{nil}.
@node Other Buffers
@subsubsection Other Buffers
@@ -750,7 +740,7 @@ current frame for simple data types (@pxref{Frame Info,,, gdb, The GNU
debugger}).
Arrays and structures display their type only. You must display them
-separately to examine their values. @ref{Data Display}.
+separately to examine their values. @ref{Watch Expressions}.
@item Registers Buffer
The registers buffer displays the values held by the registers
@@ -761,18 +751,21 @@ The assembler buffer displays the current frame as machine code. An
overlay arrow points to the current instruction and you can set and
remove breakpoints as with the source buffer. Breakpoints also
appear in the margin.
+
+@item Threads Buffer
+
+The threads buffer displays a summary of all threads currently in your
+program.(@pxref{Threads,,, gdb, The GNU debugger}). Move point to
+any thread in the list and type @key{RET} to make it become the
+current thread (@code{gdb-threads-select}) and display the associated
+source in the source buffer. Alternatively, click @kbd{Mouse-2} to
+make the selected thread become the current one.
+
@end table
@node Layout
@subsubsection Layout
@cindex GDB User Interface layout
-You may choose to display the additional buffers described previously
-either in the same frame or a different one. Select GDB-windows or
-GDB-Frames from the menu-bar under the heading GUD. If the menu-bar
-is unavailable, type @code{M-x
-gdb-display-@var{buffertype}-buffer} or @code{M-x
-gdb-frame-@var{buffertype}-buffer} respectively, where @var{buffertype}
-is the relevant buffer type e.g breakpoints.
@findex gdb-many-windows
@vindex gdb-many-windows
@@ -800,6 +793,14 @@ If you change the window layout, for example, while editing and
re-compiling your program, then you can restore it with
@code{gdb-restore-windows}.
+You may also choose which additional buffers you want to display,
+either in the same frame or a different one. Select GDB-windows or
+GDB-Frames from the menu-bar under the heading GUD. If the menu-bar
+is unavailable, type @code{M-x
+gdb-display-@var{buffertype}-buffer} or @code{M-x
+gdb-frame-@var{buffertype}-buffer} respectively, where @var{buffertype}
+is the relevant buffer type e.g breakpoints.
+
@node Executing Lisp
@section Executing Lisp Expressions
@@ -1088,3 +1089,7 @@ programs to be run in Emacs): in both modes it has the effect of installing
the function definition that point is in, but the way of doing so is
different according to where the relevant Lisp environment is found.
@xref{Executing Lisp}.
+
+@ignore
+ arch-tag: 9c3c2f71-b332-4144-8500-3ff9945a50ed
+@end ignore
diff --git a/man/calc.texi b/man/calc.texi
index 5d43afefd23..2ada16ce1bf 100644
--- a/man/calc.texi
+++ b/man/calc.texi
@@ -30801,7 +30801,7 @@ This command allows your keyboard macros to accept numbers or formulas
as interactive input. All the normal conventions of algebraic input,
including the use of @kbd{$} characters, are supported.
-@xref{Kbd Macro Query, , , emacs, the Emacs Manual}, for a description of
+@xref{Keyboard Macro Query, , , emacs, the Emacs Manual}, for a description of
@kbd{C-x q} (@code{kbd-macro-query}), the standard Emacs way to accept
keyboard input during a keyboard macro. In particular, you can use
@kbd{C-x q} to enter a recursive edit, which allows the user to perform
@@ -35612,3 +35612,6 @@ the corresponding full Lisp name is derived by adding a prefix of
@bye
+@ignore
+ arch-tag: 77a71809-fa4d-40be-b2cc-da3e8fb137c0
+@end ignore
diff --git a/man/calendar.texi b/man/calendar.texi
index b5695c8c88b..3d3f84b4ba3 100644
--- a/man/calendar.texi
+++ b/man/calendar.texi
@@ -183,6 +183,8 @@ specified in various ways.
@table @kbd
@item g d
Move point to specified date (@code{calendar-goto-date}).
+@item g D
+Move point to specified day of year (@code{calendar-goto-day-of-year}).
@item o
Center calendar around specified month (@code{calendar-other-month}).
@item .
@@ -196,6 +198,12 @@ of the month, and then moves to that date. Because the calendar includes all
dates from the beginning of the current era, you must type the year in its
entirety; that is, type @samp{1990}, not @samp{90}.
+@kindex g D @r{(Calendar mode)}
+@findex calendar-goto-day-of-year
+ @kbd{g D} (@code{calendar-goto-day-of-year}) prompts for a year and
+day number, and moves to that date. Negative day numbers count backward
+from the end of the year.
+
@kindex o @r{(Calendar mode)}
@findex calendar-other-month
@kbd{o} (@code{calendar-other-month}) prompts for a month and year,
@@ -1317,36 +1325,22 @@ Reference Manual}.
@section Appointments
@cindex appointment notification
+@vindex appt-display-format
+@vindex appt-audible
If you have a diary entry for an appointment, and that diary entry
begins with a recognizable time of day, Emacs can warn you several
minutes beforehand that that appointment is pending. Emacs alerts you
-to the appointment by displaying a message in the mode line.
-
-@vindex diary-hook
-@findex appt-make-list
- To enable appointment notification, you must enable the time display
-feature of Emacs, @kbd{M-x display-time} (@pxref{Mode Line}). You must
-also add the function @code{appt-make-list} to the
-@code{diary-hook}, like this:
-
-@example
-(add-hook 'diary-hook 'appt-make-list)
-@end example
-
-@noindent
-Adding this text to your @file{.emacs} file does the whole job:
-
-@example
-(display-time)
-(add-hook 'diary-hook 'appt-make-list)
-(diary 0)
-@end example
-
- With these preparations done, when you display the diary (either with
-the @kbd{d} command in the calendar window or with the @kbd{M-x diary}
-command), it sets up an appointment list of all the diary entries found
-with recognizable times of day, and reminds you just before each of
-them.
+to the appointment by displaying a message in your chosen format, as
+specified by the variable @code{appt-display-format}. If the value
+of @code{appt-audible} is non-nil, an audible reminder is also given.
+
+@findex appt-activate
+ To enable appointment notification, call the function
+@code{appt-activate} with a positive argument. This sets up an
+appointment list for today from the diary file, giving all diary entries
+found with recognizable times of day, and reminds you just before each
+of them. Calling @code{appt-activate} with a negative argument disables
+the appointment package.
For example, suppose the diary file contains these lines:
@@ -1356,19 +1350,26 @@ Monday
12:00pm Lunch
@end example
+@vindex appt-message-warning-time
@noindent
-Then on Mondays, after you have displayed the diary, you will be
-reminded at 9:20am about your coffee break and at 11:50am about lunch.
+Then on Mondays, you will be reminded at around 9:20am about your coffee
+break and at around 11:50am about lunch. How many minutes in advance you
+are first warned is determined by the value of
+@code{appt-message-warning-time}.
You can write times in am/pm style (with @samp{12:00am} standing
for midnight and @samp{12:00pm} standing for noon), or 24-hour
European/military style. You need not be consistent; your diary file
-can have a mixture of the two styles.
+can have a mixture of the two styles. Times must be at the beginning
+of lines if they are to be recognized.
@vindex appt-display-diary
- Emacs updates the appointments list automatically just after
-midnight. This also displays the next day's diary entries in the diary
-buffer, unless you set @code{appt-display-diary} to @code{nil}.
+ Emacs updates the appointments list from the diary file automatically
+just after midnight. An update can be forced at any time by
+re-activating the appointment package. Both these actions also display
+the day's diary buffer, unless you set @code{appt-display-diary} to
+@code{nil}. The appointments list is also updated whenever the
+diary file is saved.
@findex appt-add
@findex appt-delete
@@ -1378,10 +1379,6 @@ clock. The command @kbd{M-x appt-add} adds entries to the appointment
list without affecting your diary file. You delete entries from the
appointment list with @kbd{M-x appt-delete}.
-@vindex appt-issue-message
- You can turn off the appointment notification feature at any time by
-setting @code{appt-issue-message} to @code{nil}.
-
@node Daylight Savings
@section Daylight Savings Time
@cindex daylight savings time
@@ -1498,3 +1495,7 @@ timeclock file manually, or if you change the value of any of
timeclock's customizable variables, you should run the command
@kbd{M-x timeclock-reread-log} to update the data in Emacs from the
file.
+
+@ignore
+ arch-tag: 4531ef09-9df3-449d-9c52-2b5a4a337f92
+@end ignore
diff --git a/man/cc-mode.texi b/man/cc-mode.texi
index 25f39d75cd6..0f1e65051d8 100644
--- a/man/cc-mode.texi
+++ b/man/cc-mode.texi
@@ -1,5 +1,28 @@
\input texinfo
+@c Notes to self regarding line handling:
+@c
+@c Empty lines are often significant before @end directives; avoid them.
+@c
+@c Empty lines before and after @example directives are significant in
+@c info output but not in TeX. Empty lines inside @example directives
+@c are significant.
+
+@c Conventions for formatting examples:
+@c o If the example contains empty lines then put the surrounding empty
+@c lines inside the @example directives. Put them outside otherwise.
+@c o Use @group inside the example only if it shows indentation where
+@c the relation between lines inside is relevant.
+@c o Format line number columns like this:
+@c 1: foo
+@c 2: bar
+@c ^ one space
+@c ^^ two columns, right alignment
+@c o Check line lengths in TeX output; they can typically be no longer
+@c than 70 chars, 60 if the paragraph is indented.
+
+@comment TBD: Document the finer details of statement anchoring?
+
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@comment %**start of header (This is for running Texinfo on a region)
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -18,7 +41,7 @@
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@comment
+@comment
@comment Texinfo manual for CC Mode
@comment Generated from the original README file by Krishna Padmasola
@comment <krishna@earth-gw.njit.edu>
@@ -28,14 +51,21 @@
@comment Martin Stjernholm
@comment
@comment Maintained by Martin Stjernholm <bug-cc-mode@gnu.org>
-@comment
+@comment
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@comment Define an index for syntactic symbols.
+@defindex ss
+
+@comment Combine key, syntactic symbol and concept indices into one.
+@syncodeindex ss cp
+@syncodeindex ky cp
+
@copying
This manual is for CC Mode in Emacs.
-Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002 Free
-Software Foundation, Inc.
+Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+2003 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -58,13 +88,12 @@ license to the document, as described in section 6 of the license.
@end quotation
@end copying
-
@comment Info directory entry for use by install-info. The indentation
@comment here is by request from the FSF folks.
@dircategory Emacs
@direntry
-* CC Mode: (ccmode). Emacs mode for editing C, C++, Objective-C,
- Java, Pike, and IDL code.
+* CC Mode: (ccmode). Emacs mode for editing C, C++, Objective-C,
+ Java, Pike, AWK, and CORBA IDL code.
@end direntry
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -74,11 +103,11 @@ license to the document, as described in section 6 of the license.
@titlepage
@sp 10
-@center @titlefont{CC Mode 5.28}
+@center @titlefont{CC Mode 5.30}
@sp 2
@center @subtitlefont{A GNU Emacs mode for editing C and C-like languages}
@sp 2
-@center Barry A. Warsaw, Martin Stjernholm
+@center Barry A. Warsaw, Martin Stjernholm, Alan Mackenzie (AWK support)
@page
@vskip 0pt plus 1filll
@@ -101,10 +130,12 @@ CC Mode
@top @ccmode{}
@ccmode{} is a GNU Emacs mode for editing files containing C, C++,
-Objective-C, Java, CORBA IDL, and Pike code. It provides syntax-based
-indentation and has several handy commands and some minor modes to make
-the editing easier. Note that @ccmode{} does @emph{not} provide
-font-locking; there are other Emacs packages for that.
+Objective-C, Java, CORBA IDL (and the variants PSDL and CIDL), Pike
+code and to a certain extent, AWK code @xref{AWK Mode}. It provides
+syntax-based indentation, font locking, and has several handy commands
+and some minor modes to make the editing easier. It does not provide
+tools to look up and navigate between functions, classes etc - there are
+other packages for that.
@end ifinfo
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -113,13 +144,17 @@ font-locking; there are other Emacs packages for that.
@menu
* Introduction::
* Getting Connected::
-* New Indentation Engine::
+* Indentation Engine::
* Minor Modes::
* Text Filling and Line Breaking::
+* Macro Handling::
+* Font Locking::
* Commands::
* Customizing Indentation::
* Syntactic Symbols::
* Indentation Functions::
+* AWK Mode::
+* Odds and Ends::
* Performance Issues::
* Limitations and Known Bugs::
* Frequently Asked Questions::
@@ -129,14 +164,14 @@ font-locking; there are other Emacs packages for that.
--- Indices ---
-* Concept Index::
-* Command Index::
-* Key Index::
+* Command and Function Index::
* Variable Index::
+* Concept Index::
+@detailmenu
--- The Detailed Node Listing ---
-New Indentation Engine
+Indentation Engine
* Syntactic Analysis::
* Indentation Calculation::
@@ -146,11 +181,17 @@ Minor Modes
* Auto-newline Insertion::
* Hungry-deletion of Whitespace::
+Font Locking
+
+* Font Locking Preliminaries::
+* Faces::
+* Documentation Comments::
+
Auto-newline Insertion
* Hanging Braces::
* Hanging Colons::
-* Hanging Semi-colons and Commas::
+* Hanging Semicolons and Commas::
* Other Electric Commands::
* Clean-ups::
@@ -171,6 +212,7 @@ Customizing Indentation
Styles
* Built-in Styles::
+* Choosing a Style::
* Adding Styles::
* File Styles::
@@ -178,59 +220,50 @@ Advanced Customizations
* Custom Indentation Functions::
* Custom Brace and Colon Hanging::
-* Customizing Semi-colons and Commas::
+* Customizing Semicolons and Commas::
* Other Special Indentations::
+
+AWK Mode
+
+* Initialising AWK Mode::
+* AWK Mode Font Locking::
+* AWK Mode Defuns::
+@end detailmenu
@end menu
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Introduction, Getting Connected, Top, Top
@comment node-name, next, previous, up
-@chapter Introduction
+@chapter Introduction
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@cindex BOCM
Welcome to @ccmode{}, a GNU Emacs mode for editing files containing C,
-C++, Objective-C, Java, CORBA IDL, and Pike code. This incarnation of
-the mode is descendant from @file{c-mode.el} (also called "Boring Old C
-Mode" or BOCM @t{:-)}, and @file{c++-mode.el} version 2, which Barry has
-been maintaining since 1992. @ccmode{} represents a significant
-milestone in the mode's life. It has been fully merged back with Emacs
-19's @file{c-mode.el}. Also a new, more intuitive and flexible mechanism
-for controlling indentation has been developed. Late in 1997, Martin
+C++, Objective-C, Java, CORBA IDL (and the variants CORBA PSDL and
+CIDL), Pike and to a certain extent, AWK code (@pxref{AWK Mode}). This
+incarnation of the mode is descended from @file{c-mode.el} (also called
+``Boring Old C Mode'' or BOCM @t{:-)}, and @file{c++-mode.el} version 2,
+which Barry has been maintaining since 1992. Late in 1997, Martin
joined the @ccmode{} Maintainers Team, and implemented the Pike support.
-As of 2000 Martin has taken over as the sole maintainer.
+As of 2000 Martin has taken over as the sole maintainer. @ccmode{} did
+not originally contain the font lock support for its languages --- that
+was added in version 5.30. AWK support was also added in 5.30 by Alan
+Mackenzie.
This manual describes @ccmode{}
@comment The following line must appear on its own, so that the automated
-version 5.28.
+version 5.30.
@comment Release.py script can update the version number automatically
-@ccmode{} supports the editing of K&R and ANSI C, @dfn{ARM}
-@footnote{@cite{The Annotated C++ Reference Manual}, by Ellis and
-Stroustrup.} C++, Objective-C, Java, CORBA's Interface Definition
-Language, and Pike@footnote{A C-like scripting language with its roots
-in the LPC language used in some MUD engines. See
-@uref{http://pike.idonex.se/}.} files. In this way, you can easily set
-up consistent coding styles for use in editing all of these languages.
-@ccmode{} does @emph{not} handle font-locking (a.k.a. syntax coloring,
-keyword highlighting) or anything of that nature, for any of these
-modes. Font-locking is handled by other Emacs packages.
-
-This manual will describe the following:
-
-@itemize @bullet
-@item
-How to get started using @ccmode{}.
-
-@item
-How the new indentation engine works.
-
-@item
-How to customize the new indentation engine.
-
-@end itemize
+@ccmode{} supports the editing of K&R and ANSI C, C++, Objective-C,
+Java, CORBA's Interface Definition Language, Pike@footnote{A C-like
+scripting language with its roots in the LPC language used in some MUD
+engines. See @uref{http://pike.ida.liu.se/}.} and AWK files. In this
+way, you can easily set up consistent font locking and coding styles for
+use in editing all of these languages, although AWK is not yet as
+uniformly integrated as the other languages.
@findex c-mode
@findex c++-mode
@@ -238,23 +271,24 @@ How to customize the new indentation engine.
@findex java-mode
@findex idl-mode
@findex pike-mode
+@findex awk-mode
Note that the name of this package is ``@ccmode{},'' but there is no top
level @code{cc-mode} entry point. All of the variables, commands, and
-functions in @ccmode{} are prefixed with @code{c-@var{<thing>}}, and
+functions in @ccmode{} are prefixed with @code{c-@var{thing}}, and
@code{c-mode}, @code{c++-mode}, @code{objc-mode}, @code{java-mode},
-@code{idl-mode}, and @code{pike-mode} entry points are provided. This
-package is intended to be a replacement for @file{c-mode.el} and
-@file{c++-mode.el}.
-
-@cindex @file{cc-compat.el} file
-This distribution also contains a file
-called @file{cc-compat.el} which should ease your transition from BOCM
-to @ccmode{}. If you have a BOCM configuration you are really happy
-with, and want to postpone learning how to configure @ccmode{}, take a
-look at that file. It maps BOCM configuration variables to @ccmode{}'s
-new indentation model. It is not actively supported so for the long
-run, you should learn how to customize @ccmode{} to support your coding
-style.
+@code{idl-mode}, @code{pike-mode}, and @code{awk-mode} entry points are
+provided. This package is intended to be a replacement for
+@file{c-mode.el}, @file{c++-mode.el} and @file{awk-mode.el}.
+
+@c @cindex @file{cc-compat.el} file
+@c This distribution also contains a file
+@c called @file{cc-compat.el} which should ease your transition from BOCM
+@c to @ccmode{}. If you have a BOCM configuration you are really happy
+@c with, and want to postpone learning how to configure @ccmode{}, take a
+@c look at that file. It maps BOCM configuration variables to @ccmode{}'s
+@c indentation model. It is not actively supported so for the long run,
+@c you should learn how to customize @ccmode{} to support your coding
+@c style.
A special word of thanks goes to Krishna Padmasola for his work in
converting the original @file{README} file to Texinfo format. I'd also
@@ -263,9 +297,9 @@ early beta stages of @ccmode{}'s development.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Getting Connected, New Indentation Engine, Introduction, Top
+@node Getting Connected, Indentation Engine, Introduction, Top
@comment node-name, next, previous, up
-@chapter Getting Connected
+@chapter Getting Connected
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
If you got this version of @ccmode{} with Emacs or XEmacs, it should
@@ -275,47 +309,53 @@ the latest @ccmode{} release and may want to upgrade your copy.
If you are upgrading an existing @ccmode{} installation, please see the
@file{README} file for installation details. @ccmode{} may not work
with older versions of Emacs or XEmacs. See the @ccmode{} release notes
-Web pages for the latest information on Emacs version and package
-compatibility (@pxref{Getting the Latest CC Mode Release}).
-
-@cindex @file{cc-mode-18.el} file
-@emph{Note that @ccmode{} no longer
-works with Emacs 18!}, so if you haven't upgraded from Emacs 18 by now,
-you are out of luck.
+at @uref{http://cc-mode.sourceforge.net} for the latest information on
+Emacs version and package compatibility (@pxref{Getting the Latest CC
+Mode Release}).
-@findex c-version
+@deffn Command c-version
@findex version (c-)
You can find out what version of @ccmode{} you are using by visiting a C
file and entering @kbd{M-x c-version RET}. You should see this message in
the echo area:
-@example
+@example
Using CC Mode version 5.XX
-
@end example
@noindent
where @samp{XX} is the minor release number.
+@end deffn
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node New Indentation Engine, Minor Modes, Getting Connected, Top
+@node Indentation Engine, Minor Modes, Getting Connected, Top
@comment node-name, next, previous, up
-@chapter New Indentation Engine
-@cindex indentation engine
+@chapter Indentation Engine
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@ccmode{} has a new indentation engine, providing a simplified, yet
-flexible and general mechanism for customizing indentation. It separates
-indentation calculation into two steps: first, @ccmode{} analyzes the
-line of code being indented to determine the kind of language construct
-it's looking at, then it applies user defined offsets to the current
-line based on this analysis.
+@ccmode{} has an indentation engine that provides a flexible and general
+mechanism for customizing indentation. It separates indentation
+calculation into two steps: first, @ccmode{} analyzes the line of code
+being indented to determine the kind of language construct it's looking
+at, then it applies user defined offsets to the current line based on
+this analysis.
This section will briefly cover how indentation is calculated in
-@ccmode{}. It is important to understand the indentation model
-being used so that you will know how to customize @ccmode{} for
-your personal coding style.
+@ccmode{}. It is important to understand the indentation model being
+used so that you will know how to customize @ccmode{} for your personal
+coding style. All the details are in @ref{Customizing Indentation}, and
+later chapters.
+
+@defopt c-syntactic-indentation
+@vindex syntactic-indentation (c-)
+Syntactic analysis for indentation is done when this is non-@code{nil}
+(which is the default). When it's @code{nil} every line is just
+indented to the same level as the previous one, and @kbd{TAB}
+(@code{c-indent-command}) adjusts the indentation in steps of
+@code{c-basic-offset}. The indentation style has no effect, nor any of
+the indentation associated variables, e.g. @code{c-special-indent-hook}.
+@end defopt
@menu
* Syntactic Analysis::
@@ -324,23 +364,23 @@ your personal coding style.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Syntactic Analysis, Indentation Calculation, , New Indentation Engine
+@node Syntactic Analysis, Indentation Calculation, , Indentation Engine
@comment node-name, next, previous, up
-@section Syntactic Analysis
+@section Syntactic Analysis
@cindex syntactic analysis
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@cindex relative buffer position
-@cindex syntactic symbol
+@cindex syntactic symbols
@cindex syntactic component
@cindex syntactic component list
The first thing @ccmode{} does when indenting a line of code, is to
analyze the line, determining the @dfn{syntactic component list} of the
construct on that line. A syntactic component consists of a pair of
-information (in lisp parlance, a @emph{cons cell}), where the first part
-is a @dfn{syntactic symbol}, and the second part is a @dfn{relative
+elements (in lisp parlance, a @emph{cons cell}), the first being
+a @dfn{syntactic symbol}, the second being a @dfn{relative
buffer position}. Syntactic symbols describe elements of C code
-@footnote{Unless otherwise noted, the term ``C code'' to refers to all
+@footnote{Unless otherwise noted, the term ``C code'' refers to all
the C-like languages.}, e.g. @code{statement}, @code{substatement},
@code{class-open}, @code{class-close}, etc. @xref{Syntactic Symbols},
for a complete list of currently recognized syntactic symbols and their
@@ -354,43 +394,37 @@ by the relative buffer position in the syntactic component.
Here is an example. Suppose we had the following code as the only thing
in a C++ buffer @footnote{The line numbers in this and future examples
don't actually appear in the buffer, of course!}:
-@example
-@group
- 1: void swap( int& a, int& b )
- 2: @{
- 3: int tmp = a;
- 4: a = b;
- 5: b = tmp;
- 6: @}
-
-@end group
+@example
+ 1: void swap( int& a, int& b )
+ 2: @{
+ 3: int tmp = a;
+ 4: a = b;
+ 5: b = tmp;
+ 6: @}
@end example
@kindex C-c C-s
@findex c-show-syntactic-information
@findex show-syntactic-information (c-)
-We can use the command @kbd{C-c C-s}
-(@code{c-show-syntactic-information}) to simply report what the
+We can use the command @kbd{C-c C-s} (bound to
+@code{c-show-syntactic-information}) to simply report what the
syntactic analysis is for the current line. Running this command on
-line 4 of this example, we'd see in the echo area@footnote{With a universal
-argument (i.e. @kbd{C-u C-c C-s}) the analysis is inserted into the
-buffer as a comment
-on the current line.}:
-@example
-
-((statement . 35))
+line 4 of this example, we'd see in the echo area@footnote{With a
+universal argument (i.e. @kbd{C-u C-c C-s}) the analysis is inserted
+into the buffer as a comment on the current line.}:
+@example
+((statement 35))
@end example
This tells us that the line is a statement and it is indented relative
to buffer position 35, which happens to be the @samp{i} in @code{int} on
line 3. If you were to move point to line 3 and hit @kbd{C-c C-s}, you
would see:
-@example
-
-((defun-block-intro . 29))
+@example
+((defun-block-intro 29))
@end example
This indicates that the @samp{int} line is the first statement in a top
@@ -398,27 +432,23 @@ level function block, and is indented relative to buffer position 29,
which is the brace just after the function header.
Here's another example:
-@example
-@group
-
- 1: int add( int val, int incr, int doit )
- 2: @{
- 3: if( doit )
- 4: @{
- 5: return( val + incr );
- 6: @}
- 7: return( val );
- 8: @}
-@end group
+@example
+ 1: int add( int val, int incr, int doit )
+ 2: @{
+ 3: if( doit )
+ 4: @{
+ 5: return( val + incr );
+ 6: @}
+ 7: return( val );
+ 8: @}
@end example
@noindent
Hitting @kbd{C-c C-s} on line 4 gives us:
-@example
-
-((substatement-open . 46))
+@example
+((substatement-open 46))
@end example
@cindex substatement
@@ -435,27 +465,23 @@ Syntactic component lists can contain more than one component, and
individual syntactic components need not have relative buffer positions.
The most common example of this is a line that contains a @dfn{comment
only line}.
-@example
-@group
-
- 1: void draw_list( List<Drawables>& drawables )
- 2: @{
- 3: // call the virtual draw() method on each element in list
- 4: for( int i=0; i < drawables.count(), ++i )
- 5: @{
- 6: drawables[i].draw();
- 7: @}
- 8: @}
-@end group
+@example
+ 1: void draw_list( List<Drawables>& drawables )
+ 2: @{
+ 3: // call the virtual draw() method on each element in list
+ 4: for( int i=0; i < drawables.count(), ++i )
+ 5: @{
+ 6: drawables[i].draw();
+ 7: @}
+ 8: @}
@end example
@noindent
Hitting @kbd{C-c C-s} on line 3 of this example gives:
-@example
-
-((comment-intro) (defun-block-intro . 46))
+@example
+((comment-intro) (defun-block-intro 46))
@end example
@noindent
@@ -465,10 +491,10 @@ components. Also notice that the first component,
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Indentation Calculation, , Syntactic Analysis, New Indentation Engine
+@node Indentation Calculation, , Syntactic Analysis, Indentation Engine
@comment node-name, next, previous, up
-@section Indentation Calculation
-@cindex indentation calculation
+@section Indentation Calculation
+@cindex indentation
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Indentation for a line is calculated using the syntactic
@@ -488,26 +514,22 @@ the final total indentation for the current line is computed.
Let's use our two code examples above to see how this works. Here is
our first example again:
-@example
-@group
-
- 1: void swap( int& a, int& b )
- 2: @{
- 3: int tmp = a;
- 4: a = b;
- 5: b = tmp;
- 6: @}
-@end group
+@example
+ 1: void swap( int& a, int& b )
+ 2: @{
+ 3: int tmp = a;
+ 4: a = b;
+ 5: b = tmp;
+ 6: @}
@end example
-Let's say point is on line 3 and we hit the @kbd{TAB} key to re-indent
+Let's say point is on line 3 and we hit the @kbd{TAB} key to reindent
the line. Remember that the syntactic component list for that
line is:
-@example
-
-((defun-block-intro . 29))
+@example
+((defun-block-intro 29))
@end example
@noindent
@@ -524,28 +546,24 @@ complete, and the total indentation for the line
is 4 spaces.
Here's another example:
-@example
-@group
-
- 1: int add( int val, int incr, int doit )
- 2: @{
- 3: if( doit )
- 4: @{
- 5: return( val + incr );
- 6: @}
- 7: return( val );
- 8: @}
-@end group
+@example
+ 1: int add( int val, int incr, int doit )
+ 2: @{
+ 3: if( doit )
+ 4: @{
+ 5: return( val + incr );
+ 6: @}
+ 7: return( val );
+ 8: @}
@end example
If we were to hit @kbd{TAB} on line 4 in the above example, the same
basic process is performed, despite the differences in the syntactic
component list. Remember that the list for this line is:
-@example
-
-((substatement-open . 46))
+@example
+((substatement-open 46))
@end example
Here, @ccmode{} first looks up the @code{substatement-open} symbol
@@ -562,8 +580,6 @@ to think about it in this much detail. But when customizing
indentation, it's helpful to understand the general indentation model
being used.
-@vindex c-echo-syntactic-information-p
-@vindex echo-syntactic-information-p (c-)
As you configure @ccmode{}, you might want to set the variable
@code{c-echo-syntactic-information-p} to non-@code{nil} so that the
syntactic component list and calculated offset will always be echoed in
@@ -571,13 +587,13 @@ the minibuffer when you hit @kbd{TAB}.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Minor Modes, Text Filling and Line Breaking, New Indentation Engine, Top
+@node Minor Modes, Text Filling and Line Breaking, Indentation Engine, Top
@comment node-name, next, previous, up
-@chapter Minor Modes
+@chapter Minor Modes
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@ccmode{} contains two minor-mode-like features that you should
-find useful while you enter new C code. The first is called
+find useful while entering new C code. The first is called
@dfn{auto-newline} mode, and the second is called @dfn{hungry-delete}
mode. These minor modes can be toggled on and off independently, and
@ccmode{} can be configured so that it starts up with any
@@ -586,11 +602,11 @@ are turned off.
The state of the minor modes is always reflected in the minor mode list
on the modeline of the @ccmode{} buffer. When auto-newline mode is
-enabled, you will see @samp{C/a} on the mode line @footnote{The @samp{C}
-would be replaced with @samp{C++}, @samp{ObjC}, @samp{Java}, @samp{IDL},
-or @samp{Pike} for the respective languages.}. When hungry delete mode
-is enabled you would see @samp{C/h} and when both modes are enabled,
-you'd see @samp{C/ah}.
+enabled, you will see @samp{C/a} on the mode line@footnote{The @samp{C}
+would be replaced with the name of the language in question for the
+other languages @ccmode{} supports.}. When hungry delete mode is
+enabled you will see @samp{C/h} and if both modes were enabled, you'd
+see @samp{C/ah}.
@kindex C-c C-a
@kindex C-c C-d
@@ -603,11 +619,12 @@ you'd see @samp{C/ah}.
@findex toggle-auto-hungry-state (c-)
@ccmode{} provides key bindings which allow you to toggle the minor
modes on the fly while editing code. To toggle just the auto-newline
-state, hit @kbd{C-c C-a} (@code{c-toggle-auto-state}). When you do
-this, you should see the @samp{a} indicator either appear or disappear
-on the modeline. Similarly, to toggle just the hungry-delete state, use
-@kbd{C-c C-d} (@code{c-toggle-hungry-state}), and to toggle both states,
-use @kbd{C-c C-t} (@code{c-toggle-auto-hungry-state}).
+state, hit @kbd{C-c C-a} (bound to @code{c-toggle-auto-state}). When
+you do this, you should see the @samp{a} indicator either appear or
+disappear on the modeline. Similarly, to toggle just the
+hungry-delete state, use @kbd{C-c C-d} (@code{c-toggle-hungry-state}),
+and to toggle both states, use @kbd{C-c C-t}
+(@code{c-toggle-auto-hungry-state}).
To set up the auto-newline and hungry-delete states to your preferred
values, you would need to add some lisp to your @file{.emacs} file that
@@ -619,16 +636,12 @@ mode, and zero toggles the current state of the mode.
So for example, if you wanted to enable both auto-newline and
hungry-delete for all your C file editing, you could add the following
to your @file{.emacs} file:
-@example
+@example
(add-hook 'c-mode-common-hook
- (lambda () (c-toggle-auto-hungry-state 1)))
-
+ (lambda () (c-toggle-auto-hungry-state 1)))
@end example
-
-@cindex electric characters
-
@menu
* Auto-newline Insertion::
* Hungry-deletion of Whitespace::
@@ -638,42 +651,40 @@ to your @file{.emacs} file:
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Auto-newline Insertion, Hungry-deletion of Whitespace, , Minor Modes
@comment node-name, next, previous, up
-@section Auto-newline Insertion
-@cindex auto-newline insertion
+@section Auto-newline Insertion
+@cindex auto-newline
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@cindex electric commands
+@cindex electric characters
Auto-newline minor mode works by enabling certain @dfn{electric
-commands}. Electric commands are typically bound to special characters
-such as the left and right braces, colons, semi-colons, etc., which when
-typed, perform some magic formatting in addition to inserting the typed
-character. As a general rule, electric commands are only electric when
-the following conditions apply:
+characters}. Special characters such as the left and right braces,
+colons, semicolons, etc., have been made electric to perform some
+magic formatting in addition to inserting the typed character. As a
+general rule, electric characters are only electric when the following
+conditions apply:
@itemize @bullet
@item
Auto-newline minor mode is enabled, as evidenced by a @samp{C/a} or
@samp{C/ah} indicator on the modeline.
+@item
@cindex literal
@cindex syntactic whitespace
-@item
The character was not typed inside of a literal @footnote{A
-@dfn{literal} is defined as any comment, string, or C preprocessor macro
+@dfn{literal} is defined as any comment, string, or preprocessor macro
definition. These constructs are also known as @dfn{syntactic
whitespace} since they are usually ignored when scanning C code.}.
@item
-@kindex C-u
No numeric argument was supplied to the command (i.e. it was typed as
normal, with no @kbd{C-u} prefix).
-
@end itemize
@menu
* Hanging Braces::
* Hanging Colons::
-* Hanging Semi-colons and Commas::
+* Hanging Semicolons and Commas::
* Other Electric Commands::
* Clean-ups::
@end menu
@@ -688,89 +699,65 @@ normal, with no @kbd{C-u} prefix).
@findex c-electric-brace
@findex electric-brace (c-)
-@vindex c-hanging-braces-alist
-@vindex hanging-braces-alist (c-)
+@kindex @{
+@kindex @}
+
When you type either an open or close brace (i.e. @kbd{@{} or @kbd{@}}),
the electric command @code{c-electric-brace} gets run. This command has
two electric formatting behaviors. First, it will perform some
-re-indentation of the line the brace was typed on, and second, it will
+reindentation of the line the brace was typed on, and second, it will
add various newlines before and/or after the typed brace.
-Re-indentation occurs automatically whenever the electric behavior is
+Reindentation occurs automatically whenever the electric behavior is
enabled. If the brace ends up on a line other than the one it was typed
-on, then that line is also re-indented.
-
-@cindex class-open syntactic symbol
-@cindex class-close syntactic symbol
-@cindex defun-open syntactic symbol
-@cindex defun-close syntactic symbol
-@cindex inline-open syntactic symbol
-@cindex inline-close syntactic symbol
-@cindex brace-list-open syntactic symbol
-@cindex brace-list-close syntactic symbol
-@cindex brace-list-intro syntactic symbol
-@cindex brace-entry-open syntactic symbol
-@cindex block-open syntactic symbol
-@cindex block-close syntactic symbol
-@cindex substatement-open syntactic symbol
-@cindex statement-case-open syntactic symbol
-@cindex extern-lang-open syntactic symbol
-@cindex extern-lang-close syntactic symbol
-@cindex namespace-open syntactic symbol
-@cindex namespace-close syntactic symbol
-@cindex inexpr-class-open symbol
-@cindex inexpr-class-close symbol
+on, then that line is also reindented.
The default in auto-newline mode is to insert newlines both before and
after a brace, but that can be controlled by the
-@code{c-hanging-braces-alist} style variable. This variable contains a
-mapping between syntactic symbols related to braces, and a list of
-places to insert a newline. The syntactic symbols that are useful for
-this list are: @code{class-open}, @code{class-close}, @code{defun-open},
-@code{defun-close}, @code{inline-open}, @code{inline-close},
-@code{brace-list-open}, @code{brace-list-close},
-@code{brace-list-intro}, @code{brace-entry-open}, @code{block-open},
-@code{block-close}, @code{substatement-open},
-@code{statement-case-open}, @code{extern-lang-open},
-@code{extern-lang-close}, @code{namespace-open}, @code{namespace-close},
-@code{inexpr-class-open}, and @code{inexpr-class-close}@footnote{Note
-that the aggregate constructs in Pike mode, @samp{(@{}, @samp{@})},
-@samp{([}, @samp{])}, and @samp{(<}, @samp{>)}, do not count as brace
-lists in this regard, even though they do for normal indentation
-purposes. It's currently not possible to set automatic newlines on
-these constructs.}. @xref{Syntactic Symbols}, for a more detailed
-description of these syntactic symbols, except for
-@code{inexpr-class-open} and @code{inexpr-class-close}, which aren't
-actual syntactic symbols.
+@code{c-hanging-braces-alist} style variable.
+
+@defopt c-hanging-braces-alist
+@vindex hanging-braces-alist (c-)
+
+This variable contains a mapping between syntactic symbols related to
+braces, and a list of places to insert a newline. The syntactic symbols
+that are useful for this list are @code{brace-list-intro},
+@code{statement-cont}, @code{inexpr-class-open},
+@code{inexpr-class-close}, and all the @code{*-open} and @code{*-close}
+symbols. @xref{Syntactic Symbols}, for a more detailed description of
+these syntactic symbols, except for @code{inexpr-class-open} and
+@code{inexpr-class-close}, which aren't actual syntactic symbols.
The braces of anonymous inner classes in Java are given the special
symbols @code{inexpr-class-open} and @code{inexpr-class-close}, so that
they can be distinguished from the braces of normal classes@footnote{The
-braces of anonymous classes produces a combination of
+braces of anonymous classes produce a combination of
@code{inexpr-class}, and @code{class-open} or @code{class-close} in
normal indentation analysis.}.
+Note that the aggregate constructs in Pike mode, @samp{(@{}, @samp{@})},
+@samp{([}, @samp{])}, and @samp{(<}, @samp{>)}, do not count as brace
+lists in this regard, even though they do for normal indentation
+purposes. It's currently not possible to set automatic newlines on
+these constructs.
+
The value associated with each syntactic symbol in this association list
-is called an @var{ACTION} which can be either a function or a list.
+is called an @var{action}, which can be either a function or a list.
@xref{Custom Brace and Colon Hanging}, for a more detailed discussion of
-using a function as a brace hanging @var{ACTION}.
+using a function as a brace hanging @var{action}.
-When the @var{ACTION} is a list, it can contain any combination of the
+When the @var{action} is a list, it can contain any combination of the
symbols @code{before} and @code{after}, directing @ccmode{} where to
put newlines in relationship to the brace being inserted. Thus, if the
list contains only the symbol @code{after}, then the brace is said to
@dfn{hang} on the right side of the line, as in:
-@example
-@group
+@example
// here, open braces always `hang'
void spam( int i ) @{
if( i == 7 ) @{
dosomething(i);
@}
@}
-
-
-@end group
@end example
When the list contains both @code{after} and @code{before}, the braces
@@ -780,71 +767,71 @@ are added either before or after the brace.
If a syntactic symbol is missing entirely from
@code{c-hanging-braces-alist}, it's treated in the same way as an
-@var{ACTION} with a list containing @code{before} and @code{after}, so
+@var{action} with a list containing @code{before} and @code{after}, so
that braces by default end up on their own line.
For example, the default value of @code{c-hanging-braces-alist} is:
-@example
-@group
-
- ((brace-list-open)
- (brace-entry-open)
- (substatement-open after)
- (block-close . c-snug-do-while)
- (extern-lang-open after)
- (inexpr-class-open after)
- (inexpr-class-close before))
-@end group
+@example
+((brace-list-open)
+ (brace-entry-open)
+ (statement-cont)
+ (substatement-open after)
+ (block-close . c-snug-do-while)
+ (extern-lang-open after)
+ (inexpr-class-open after)
+ (inexpr-class-close before))
@end example
-@noindent which says that @code{brace-list-open} and
-@code{brace-entry-open} braces should both hang on the right side, and
-allow subsequent text to follow on the same line as the brace. Also,
-@code{substatement-open}, @code{extern-lang-open}, and
-@code{inexpr-class-open} braces should hang on the right side, but
-subsequent text should follow on the next line. The opposite holds for
-@code{inexpr-class-close} braces; they won't hang, but the following
-text continues on the same line. Here, in the @code{block-close} entry,
-you also see an example of using a function as an @var{ACTION}. In all
-other cases, braces are put on a line by themselves.
-
-A word of caution: it is not a good idea to hang top-level construct
-introducing braces, such as @code{class-open} or @code{defun-open}.
-Emacs makes an assumption that such braces will always appear in column
-zero, hanging them can introduce performance problems.
-@xref{Performance Issues}, for more information.
+@noindent which says that @code{brace-list-open},
+@code{brace-entry-open} and @code{statement-cont}@footnote{Brace lists
+inside statements, such as initializers for static array variables
+inside functions in C, are recognized as @code{statement-cont}. All
+normal substatement blocks are recognized with other symbols.} braces
+should both hang on the right side and allow subsequent text to follow
+on the same line as the brace. Also, @code{substatement-open},
+@code{extern-lang-open}, and @code{inexpr-class-open} braces should hang
+on the right side, but subsequent text should follow on the next line.
+The opposite holds for @code{inexpr-class-close} braces; they won't
+hang, but the following text continues on the same line. Here, in the
+@code{block-close} entry, you also see an example of using a function as
+an @var{action}. In all other cases, braces are put on a line by
+themselves.
+@end defopt
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Hanging Colons, Hanging Semi-colons and Commas, Hanging Braces, Auto-newline Insertion
+@node Hanging Colons, Hanging Semicolons and Commas, Hanging Braces, Auto-newline Insertion
@comment node-name, next, previous, up
@subsection Hanging Colons
@cindex hanging colons
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex hanging-colons-alist (c-)
-@vindex c-hanging-colons-alist
Using a mechanism similar to brace hanging (@pxref{Hanging Braces}),
colons can also be made to hang using the style variable
-@code{c-hanging-colons-alist}. The syntactic symbols appropriate for
-this association list are: @code{case-label}, @code{label},
-@code{access-label}, @code{member-init-intro}, and @code{inher-intro}.
-Note however that for @code{c-hanging-colons-alist}, @var{ACTION}s as
-functions are not supported. See also @ref{Custom Brace and Colon
-Hanging} for details.
+@code{c-hanging-colons-alist}.
+
+@defopt c-hanging-colons-alist
+@vindex hanging-colons-alist (c-)
+
+The syntactic symbols appropriate for this association list are:
+@code{case-label}, @code{label}, @code{access-label},
+@code{member-init-intro}, and @code{inher-intro}. Note however that for
+@code{c-hanging-colons-alist}, @var{action}s as functions are not
+supported. See also @ref{Custom Brace and Colon Hanging} for details.
In C++, double-colons are used as a scope operator but because these
colons always appear right next to each other, newlines before and after
them are controlled by a different mechanism, called @dfn{clean-ups} in
@ccmode{}. @xref{Clean-ups}, for details.
+@end defopt
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Hanging Semi-colons and Commas, Other Electric Commands, Hanging Colons, Auto-newline Insertion
+@node Hanging Semicolons and Commas, Other Electric Commands, Hanging Colons, Auto-newline Insertion
@comment node-name, next, previous, up
-@subsection Hanging Semi-colons and Commas
-@cindex hanging semi-colons
+@subsection Hanging Semicolons and Commas
+@cindex hanging semicolons
@cindex hanging commas
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -852,75 +839,128 @@ Semicolons and commas are also electric in @ccmode{}, but since
these characters do not correspond directly to syntactic symbols, a
different mechanism is used to determine whether newlines should be
automatically inserted after these characters. @xref{Customizing
-Semi-colons and Commas}, for details.
+Semicolons and Commas}, for details.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Other Electric Commands, Clean-ups, Hanging Semi-colons and Commas, Auto-newline Insertion
+@node Other Electric Commands, Clean-ups, Hanging Semicolons and Commas, Auto-newline Insertion
@comment node-name, next, previous, up
@subsection Other Electric Commands
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+A few other keys also provide electric behavior, often only to reindent
+the line. Common to all of them is that they only reindent if used in
+normal code (as opposed to in a string literal or comment), and
+@code{c-syntactic-indentation} isn't @code{nil}. They are:
+
+@table @kbd
+@item #
@kindex #
@findex c-electric-pound
-@vindex c-electric-pound-behavior
@findex electric-pound (c-)
+@vindex c-electric-pound-behavior
@vindex electric-pound-behavior (c-)
-A few other keys also provide electric behavior. For example
-@kbd{#} (@code{c-electric-pound}) is electric when typed as
-the first non-whitespace character on a line. In this case, the
-variable @code{c-electric-pound-behavior} is consulted for the electric
-behavior. This variable takes a list value, although the only element
-currently defined is @code{alignleft}, which tells this command to force
-the @samp{#} character into column zero. This is useful for entering
-C preprocessor macro definitions.
+Pound (bound to @code{c-electric-pound}) is electric when typed as the
+first non-whitespace character on a line and not within a macro
+definition. In this case, the variable @code{c-electric-pound-behavior}
+is consulted for the electric behavior. This variable takes a list
+value, although the only element currently defined is @code{alignleft},
+which tells this command to force the @samp{#} character into column
+zero. This is useful for entering preprocessor macro definitions.
+
+Pound is not electric in AWK buffers, where @samp{#} starts a comment,
+and is bound to @code{self-insert-command} like any typical printable
+character.
+@item *
+@kindex *
+@itemx /
+@kindex /
@findex c-electric-star
-@findex c-electric-slash
@findex electric-star (c-)
+@findex c-electric-slash
@findex electric-slash (c-)
-Stars and slashes (i.e. @kbd{*} and @kbd{/}, @code{c-electric-star} and
-@code{c-electric-slash} respectively) are also electric under
-certain circumstances. If a star is inserted as the second character of
-a C style block comment on a comment-only line, then the comment
-delimiter is indented as defined by @code{c-offsets-alist}. A
-comment-only line is defined as a line which contains only a comment, as
-in:
+Stars and slashes (bound to @code{c-electric-star} and
+@code{c-electric-slash} respectively) are also electric under certain
+circumstances. If a @samp{*} is inserted as the second character of a C
+style block comment on a comment-only line, then the comment delimiter
+is indented as defined by @code{c-offsets-alist}. A comment-only line
+is defined as a line which contains only a comment, as in:
+
@example
@group
-
void spam( int i )
@{
- // this is a comment-only line...
- if( i == 7 ) // but this is not
+ // this is a comment-only line...
+ if( i == 7 ) // but this is not
@{
dosomething(i);
@}
@}
-
@end group
@end example
-Likewise, if a slash is inserted as the second slash in a C++ style line
-comment (also only on a comment-only line), then the line is indented as
-defined by @code{c-offsets-alist}.
+Likewise, if a @samp{/} is inserted as the second slash in a C++ style
+line comment (also only on a comment-only line), then the line is
+indented as defined by @code{c-offsets-alist}.
-@findex c-electric-lt-gt
-@findex electric-lt-gt (c-)
+In AWK mode, @samp{*} and @samp{/} do not delimit comments and are
+bound to @code{self-insert-command}.
+
+@item <
@kindex <
+@itemx >
@kindex >
-Less-than and greater-than signs (@code{c-electric-lt-gt}) are also
+@findex c-electric-lt-gt
+@findex electric-lt-gt (c-)
+Less-than and greater-than signs (bound to @code{c-electric-lt-gt}) are
electric, but only in C++ mode. Hitting the second of two @kbd{<} or
-@kbd{>} keys re-indents the line if it is a C++ style stream operator.
+@kbd{>} keys reindents the line if it is a C++ style stream operator.
-@findex c-electric-paren
-@findex electric-paren (c-)
+@item (
@kindex (
+@itemx )
@kindex )
-The normal parenthesis characters @samp{(} and @samp{)} also reindent
-the current line if they are used in normal code. This is useful for
-getting the closing parenthesis of an argument list aligned
-automatically.
+@findex c-electric-paren
+@findex electric-paren (c-)
+The normal parenthesis characters @samp{(} and @samp{)} reindent the
+current line. This is useful for getting the closing parenthesis of an
+argument list aligned automatically.
+@end table
+
+@deffn Command c-electric-continued-statement
+@findex electric-continued-statement (c-)
+
+Certain keywords, depending on language, are electric to cause
+reindentation when they are preceded only by whitespace on the line.
+The keywords are those that continue an earlier statement instead of
+starting a new one: @code{else}, @code{while}, @code{catch} (only in C++
+and Java) and @code{finally} (only in Java).
+
+An example:
+
+@example
+@group
+for (i = 0; i < 17; i++)
+ if (a[i])
+ res += a[i]->offset;
+else
+@end group
+@end example
+
+Here, the @code{else} should be indented like the preceding @code{if},
+since it continues that statement. @ccmode{} will automatically reindent
+it after the @code{else} has been typed in full, since it's not until
+then it's possible to decide whether it's a new statement or a
+continuation of the preceding @code{if}.
+
+@vindex abbrev-mode
+@findex abbrev-mode
+@cindex Abbrev mode
+@ccmode{} uses Abbrev mode (@pxref{Abbrevs,,, emacs, The Emacs Editor})
+to accomplish this. It's therefore turned on by default in all language
+modes except IDL mode, since CORBA IDL doesn't have any statements.
+@end deffn
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -940,9 +980,10 @@ Most of the clean-ups are only applicable to counteract automatically
inserted newlines, and will therefore only have any effect if the
auto-newline minor mode is turned on. Others will work all the time.
-@vindex c-cleanup-list
+@defopt c-cleanup-list
@vindex cleanup-list (c-)
@cindex literal
+
You can configure @ccmode{}'s clean-ups by setting the style variable
@code{c-cleanup-list}, which is a list of clean-up symbols. By default,
@ccmode{} cleans up only the @code{scope-operator} construct, which is
@@ -950,190 +991,180 @@ necessary for proper C++ support. Note that clean-ups are only
performed when the construct does not occur within a literal
(@pxref{Auto-newline Insertion}), and when there is nothing but
whitespace appearing between the individual components of the construct.
+@end defopt
-These are the clean-ups that only are active in the auto-newline minor
+These are the clean-ups that are only active in the auto-newline minor
mode:
-@itemize @bullet
-@item
-@code{brace-else-brace} --- Clean up @samp{@} else @{} constructs by
-placing the entire construct on a single line. Clean-up occurs when the
-open brace after the @samp{else} is typed. So for example, this:
+@c TBD: Would like to use some sort of @deffoo here; @table indents a
+@c bit too much in dvi output.
+@table @code
+@item brace-else-brace
+Clean up @samp{@} else @{} constructs by placing the entire construct on
+a single line. Clean-up occurs when the open brace after the
+@samp{else} is typed. So for example, this:
+
@example
@group
-
void spam(int i)
@{
- if( i==7 )
- @{
+ if( i==7 ) @{
dosomething();
@}
else
@{
-
@end group
@end example
+
@noindent
-appears like this after the open brace is typed:
+appears like this after the last open brace is typed:
+
@example
@group
-
void spam(int i)
@{
if( i==7 ) @{
dosomething();
@} else @{
-
@end group
@end example
-@item
-@code{brace-elseif-brace} --- Similar to the @code{brace-else-brace}
-clean-up, but this cleans up @samp{@} else if (...) @{} constructs. For
-example:
+@item brace-elseif-brace
+Similar to the @code{brace-else-brace} clean-up, but this cleans up
+@samp{@} else if (...) @{} constructs. For example:
+
@example
@group
-
void spam(int i)
@{
- if( i==7 )
- @{
+ if( i==7 ) @{
dosomething();
@}
else if( i==3 )
@{
-
@end group
@end example
+
@noindent
-appears like this after the open parenthesis is typed:
+appears like this after the last open parenthesis is typed:
+
@example
@group
-
void spam(int i)
@{
if( i==7 ) @{
dosomething();
@} else if( i==3 )
@{
-
@end group
@end example
+
@noindent
-and like this after the open brace is typed:
+and like this after the last open brace is typed:
+
@example
@group
-
void spam(int i)
@{
if( i==7 ) @{
dosomething();
@} else if( i==3 ) @{
-
@end group
@end example
-@item
-@code{brace-catch-brace} --- Analogous to @code{brace-elseif-brace}, but
-cleans up @samp{@} catch (...) @{} in C++ and Java mode.
+@item brace-catch-brace
+Analogous to @code{brace-elseif-brace}, but cleans up @samp{@} catch
+(...) @{} in C++ and Java mode.
+
+@item empty-defun-braces
+Clean up braces following a top-level function or class definition that
+contains no body. Clean up occurs when the closing brace is typed.
+Thus the following:
-@item
-@code{empty-defun-braces} --- Clean up braces following a top-level
-function or class definition that contains no body. Clean up occurs
-when the closing brace is typed. Thus the following:
@example
@group
-
class Spam
@{
@}
-
@end group
@end example
+
@noindent
is transformed into this when the close brace is typed:
+
@example
@group
-
class Spam
@{@}
-
@end group
@end example
-@item
-@code{defun-close-semi} --- Clean up the terminating semi-colon on
-top-level function or class definitions when they follow a close
-brace. Clean up occurs when the semi-colon is typed.
-So for example, the following:
+@item defun-close-semi
+Clean up the terminating semicolon on top-level function or class
+definitions when they follow a close brace. Clean up occurs when the
+semicolon is typed. So for example, the following:
+
@example
@group
-
class Spam
@{
@}
;
-
@end group
@end example
+
@noindent
-is transformed into this when the semi-colon is typed:
+is transformed into this when the semicolon is typed:
@example
@group
-
class Spam
@{
@};
-
@end group
@end example
-@item
-@code{list-close-comma} --- Clean up commas following braces in array
-and aggregate initializers. Clean up occurs when the comma is typed.
-
-@item
-@code{scope-operator} --- Clean up double colons which may designate a
-C++ scope operator split across multiple lines@footnote{Certain C++
-constructs introduce ambiguous situations, so @code{scope-operator}
-clean-ups may not always be correct. This usually only occurs when
-scoped identifiers appear in switch label tags.}. Clean up occurs when
-the second colon is typed. You will always want @code{scope-operator}
-in the @code{c-cleanup-list} when you are editing C++ code.
-
-@end itemize
+@item list-close-comma
+Clean up commas following braces in array and aggregate initializers.
+Clean up occurs when the comma is typed.
+
+@item scope-operator
+Clean up double colons which may designate a C++ scope operator split
+across multiple lines@footnote{Certain C++ constructs introduce
+ambiguous situations, so @code{scope-operator} clean-ups may not always
+be correct. This usually only occurs when scoped identifiers appear in
+switch label tags.}. Clean up occurs when the second colon is typed.
+You will always want @code{scope-operator} in the @code{c-cleanup-list}
+when you are editing C++ code.
+@end table
The following clean-ups are always active when they occur on
@code{c-cleanup-list}, and are thus not affected by the auto-newline
minor mode:
-@itemize @bullet
-@item
-@code{space-before-funcall} --- Insert a space between the function name
-and the opening parenthesis of a function call. This produces function
-calls in the style mandated by the GNU coding standards,
-e.g. @samp{signal (SIGINT, SIG_IGN)} and @samp{abort ()}. Clean up
-occurs when the opening parenthesis is typed.
-
-@item
-@code{compact-empty-funcall} --- Clean up any space between the function
-name and the opening parenthesis of a function call that have no
-arguments. This is typically used together with
-@code{space-before-funcall} if you prefer the GNU function call style
-for functions with arguments but think it looks ugly when it's only an
-empty parenthesis pair. I.e. you will get @samp{signal (SIGINT,
-SIG_IGN)}, but @samp{abort()}. Clean up occurs when the closing
-parenthesis is typed.
-
-@end itemize
+@table @code
+@item space-before-funcall
+Insert a space between the function name and the opening parenthesis of
+a function call. This produces function calls in the style mandated by
+the GNU coding standards, e.g. @samp{signal (SIGINT, SIG_IGN)} and
+@samp{abort ()}. Clean up occurs when the opening parenthesis is typed.
+
+@item compact-empty-funcall
+Clean up any space between the function name and the opening parenthesis
+of a function call that has no arguments. This is typically used
+together with @code{space-before-funcall} if you prefer the GNU function
+call style for functions with arguments but think it looks ugly when
+it's only an empty parenthesis pair. I.e. you will get @samp{signal
+(SIGINT, SIG_IGN)}, but @samp{abort()}. Clean up occurs when the
+closing parenthesis is typed.
+@end table
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Hungry-deletion of Whitespace, , Auto-newline Insertion, Minor Modes
@comment node-name, next, previous, up
-@section Hungry-deletion of Whitespace
-@cindex hungry-deletion of whitespace
+@section Hungry-deletion of Whitespace
+@cindex hungry-deletion
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Hungry deletion of whitespace, or as it more commonly called,
@@ -1142,75 +1173,107 @@ extremely useful. In fact, you might find yourself wanting
hungry-delete in @strong{all} your editing modes!
@kindex DEL
-@kindex Backspace
-In a nutshell, when hungry-delete mode is enabled, hitting the
-@key{Backspace} key@footnote{I say ``hit the @key{Backspace} key'' but
-what I really mean is ``when Emacs receives the @code{BackSpace} key
-event.'' The difference usually isn't significant to most users, but
-advanced users will realize that under window systems such as X, any
-physical key (keycap) on the keyboard can be configured to generate any
-keysym, and thus any Emacs key event. Also, the use of Emacs on TTYs
-will affect which keycap generates which key event. From a pedantic
-point of view, here we are only concerned with the key event that
-Emacs receives.} will consume all preceding whitespace, including
-newlines and tabs. This can really cut down on the number of
-@key{Backspace}'s you have to type if, for example you made a mistake on
+@kindex C-d
+
+In a nutshell, when hungry-delete mode is enabled, hitting the @kbd{DEL}
+or @kbd{C-d} keys will consume all preceding or following whitespace,
+including newlines and tabs. This can really cut down on the number of
+times you have to hit these keys if, for example, you made a mistake on
the preceding line.
-@findex c-electric-backspace
+@deffn Command c-electric-backspace
@findex electric-backspace (c-)
-@vindex c-backspace-function
+This command is run by default when you hit the @kbd{DEL} key. It
+deletes any amount of whitespace in the backwards direction if
+hungry-delete mode is enabled. When it's disabled, or when used with
+a prefix argument or in a literal (@pxref{Auto-newline Insertion}),
+the function contained in the @code{c-backspace-function} variable is
+called with the prefix argument.
+@end deffn
+
+@defvar c-backspace-function
@vindex backspace-function (c-)
+@findex backward-delete-char-untabify
+Hook that gets called by @code{c-electric-backspace} when it doesn't
+do an ``electric'' deletion of the preceding whitespace. The default
+value is @code{backward-delete-char-untabify}.
+@end defvar
+
+@deffn Command c-electric-delete-forward
+@findex electric-delete-forward (c-)
+This function, which is bound to @kbd{C-d} by default, works just like
+@code{c-electric-backspace} but in the forward direction. When it
+doesn't do an ``electric'' deletion of the following whitespace, it
+calls the function in @code{c-delete-function} with its prefix
+argument.
+@end deffn
+
+@defvar c-delete-function
+@vindex delete-function (c-)
+@findex delete-char
+Hook that gets called by @code{c-electric-delete-forward} when it
+doesn't do an ``electric'' deletion of the following whitespace. The
+default value is @code{delete-char}.
+@end defvar
+
+Above we have only talked about the @kbd{DEL} and @kbd{C-d} key events,
+without connecting them to the physical keys commonly known as
+@key{Backspace} and @key{Delete}. The default behavior of those two
+depends on the flavor of (X)Emacs you are using.
@findex c-electric-delete
@findex electric-delete (c-)
-@vindex c-delete-function
-@vindex delete-function (c-)
-@cindex literal
+@vindex delete-key-deletes-forward
-@findex backward-delete-char-untabify
+In XEmacs 20.3 and beyond, the @key{Backspace} key is bound to
+@code{c-electric-backspace} and the @key{Delete} key is bound to
+@code{c-electric-delete}. You control the direction it deletes in by
+setting the variable @code{delete-key-deletes-forward}, a standard
+XEmacs variable. When this variable is non-@code{nil},
+@code{c-electric-delete} will do forward deletion with
+@code{c-electric-delete-forward}, otherwise it does backward deletion
+with @code{c-electric-backspace}.
+
+In other Emacs versions, @ccmode{} doesn't bind either @key{Backspace}
+or @key{Delete}. In XEmacs 19 and Emacs prior to 21 that means that
+it's up to you to fix them. Emacs 21 automatically binds them as
+appropriate to @kbd{DEL} and @kbd{C-d}.
+
+Another way to use hungry deletion is to bind
+@code{c-hungry-backspace} and @code{c-hungry-delete-forward} directly
+to keys, and not use the mode toggling. For example @kbd{C-c C-d} and
+@kbd{C-c DEL} to match plain @kbd{C-d} and @kbd{DEL},
-By default, when you hit the @key{Backspace} key @ccmode{} runs the
-command @code{c-electric-backspace}, which deletes text in the backwards
-direction. When deleting a single character, or when @key{Backspace} is
-hit in a literal (@pxref{Auto-newline Insertion}), or when hungry-delete
-mode is disabled, the function contained in the
-@code{c-backspace-function} variable is called with one argument (the
-number of characters to delete). This variable is set to
-@code{backward-delete-char-untabify} by default.
+@example
+(add-hook
+ 'c-mode-common-hook
+ (lambda ()
+ (define-key c-mode-base-map
+ [?\C-c ?\d] 'c-hungry-backspace)
+ (define-key c-mode-base-map
+ [?\C-c ?\C-d] 'c-hungry-delete-forward)))
+@end example
-@vindex delete-key-deletes-forward
-@findex delete-char
+@deffn Command c-hungry-backspace
+@findex hungry-backspace (c-)
+Delete any amount of whitespace in the backwards direction (regardless
+whether hungry-delete mode is enabled or not).
+@end deffn
-The default behavior of the @key{Delete} key depends on the flavor of
-Emacs you are using. By default in XEmacs 20.3 and beyond, the
-@key{Delete} key is bound to @code{c-electric-delete}. You control the
-direction that the @key{Delete} key deletes by setting the variable
-@code{delete-key-deletes-forward}, a standard XEmacs variable. When
-this variable is non-@code{nil} and hungry-delete mode is enabled,
-@code{c-electric-delete} will consume all whitespace @emph{following}
-point. When @code{delete-key-deletes-forward} is @code{nil}, it deletes
-all whitespace @emph{preceding} point@footnote{i.e. it literally calls
-@code{c-electric-backspace}.} When deleting a single character, or if
-@key{Delete} is hit in a literal, or hungry-delete mode is disabled, the
-function contained in @code{c-delete-function} is called with one
-argument: the number of characters to delete. This variable is set to
-@code{delete-char} by default.
-
-In Emacs 19 or Emacs 20, both the @key{Delete} and @key{Backspace} keys
-are bound to @code{c-electric-backspace}, however you can change this by
-explicitly binding @code{[delete]}@footnote{E.g. to
-@code{c-electric-delete} in your @file{.emacs} file. Note however, that
-Emacs 20 does not have a standard variable such as
-@code{delete-key-deletes-forward}.}.
-
-XEmacsen older than 20.3 behave similar to Emacs 19 and Emacs 20.
+@deffn Command c-hungry-delete-forward
+@findex hungry-delete-forward (c-)
+Delete any amount of whitespace in the forward direction (regardless
+whether hungry-delete mode is enabled or not).
+@end deffn
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Text Filling and Line Breaking, Commands, Minor Modes, Top
+@node Text Filling and Line Breaking, Macro Handling, Minor Modes, Top
@comment node-name, next, previous, up
-@chapter Text Filling and Line Breaking
+@chapter Text Filling and Line Breaking
+@cindex text filling
+@cindex line breaking
+@cindex comment handling
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Since there's a lot of normal text in comments and string literals,
@@ -1242,42 +1305,51 @@ variables@footnote{@code{comment-start}, @code{comment-end},
@code{paragraph-separate}, @code{paragraph-ignore-fill-prefix},
@code{adaptive-fill-mode}, @code{adaptive-fill-regexp}, and
@code{adaptive-fill-first-line-regexp}.} buffer local and modifies them
-according to the language syntax and the style of line decoration that
-starts every line in a comment. The style variable
-@code{c-comment-prefix-regexp} contains the regexp used to recognize
-this @dfn{comment line prefix}. The default is @samp{//+\\|\\**}, which
+according to the language syntax and the comment line prefix.
+
+@defopt c-comment-prefix-regexp
+@vindex comment-prefix-regexp (c-)
+This style variable contains the regexp used to recognize the
+@dfn{comment line prefix}, which is the line decoration that starts
+every line in a comment. The default is @samp{//+\\|\\**}, which
matches C++ style line comments like
-@example
+@example
// blah blah
-
@end example
@noindent
with two or more slashes in front of them, and C style block comments
like
+
@example
@group
-
/*
* blah blah
*/
-
@end group
@end example
@noindent
with zero or more stars at the beginning of every line. If you change
-that variable, please make sure it still matches the comment starter
+this variable, please make sure it still matches the comment starter
(i.e. @code{//}) of line comments @emph{and} the line prefix inside
-block comments. Also note that since @ccmode{} uses the value of
+block comments.
+
+@findex c-setup-paragraph-variables
+@findex setup-paragraph-variables (c-)
+Also note that since @ccmode{} uses the value of
@code{c-comment-prefix-regexp} to set up several other variables at mode
-initialization, you need to reinitialize the program mode if you change
-it inside a @ccmode{} buffer.
+initialization, there won't have any effect if you change it inside a
+@ccmode{} buffer. You need to call the command
+@code{c-setup-paragraph-variables} to update those other variables with
+the new value. That's also the case if you modify this variable in a
+mode hook, since @ccmode{} sets up all variables before calling them.
+@end defopt
@findex auto-fill-mode
-@cindex auto fill mode
-@cindex paragraph fill
+@cindex Auto Fill mode
+@cindex paragraph filling
Line breaks are by default handled (almost) the same regardless whether
they are made by auto fill mode (@pxref{Auto Fill,,, emacs, The Emacs
Editor}), paragraph filling (e.g. with @kbd{M-q}), or explicitly with
@@ -1288,15 +1360,16 @@ same indentation as the previous nonempty line (may be changed with the
lines in the comment.
@vindex adaptive-fill-mode
-@cindex adaptive fill mode
+@cindex Adaptive Fill mode
@ccmode{} uses adaptive fill mode (@pxref{Adaptive Fill,,, emacs, The
Emacs Editor}) to make Emacs correctly keep the line prefix when filling
paragraphs. That also makes Emacs preserve the text indentation
@emph{inside} the comment line prefix. E.g. in the following comment,
-both paragraphs will be filled with the left margins kept intact:
+both paragraphs will be filled with the left margins of the texts kept
+intact:
+
@example
@group
-
/* Make a balanced b-tree of the nodes in the incoming
* stream. But, to quote the famous words of Donald E.
* Knuth,
@@ -1304,7 +1377,6 @@ both paragraphs will be filled with the left margins kept intact:
* Beware of bugs in the above code; I have only
* proved it correct, not tried it.
*/
-
@end group
@end example
@@ -1319,76 +1391,75 @@ E. Jones' Filladapt package@footnote{It's available from
lack a feature that makes it work suboptimally when
@code{c-comment-prefix-regexp} matches the empty string (which it does
by default). A patch for that is available from
-@uref{http://cc-mode.sourceforge.net/,, the CC Mode site}.},
+@uref{http://cc-mode.sourceforge.net/,, the CC Mode web site}.},
which handles things like bulleted lists nicely. There's a convenience
function @code{c-setup-filladapt} that tunes the relevant variables in
Filladapt for use in @ccmode{}. Call it from a mode hook, e.g. with
something like this in your @file{.emacs}:
-@example
-@group
+@example
(defun my-c-mode-common-hook ()
(c-setup-filladapt)
(filladapt-mode 1))
(add-hook 'c-mode-common-hook 'my-c-mode-common-hook)
-
-@end group
@end example
-@vindex c-block-comment-prefix
+@defopt c-block-comment-prefix
@vindex block-comment-prefix (c-)
@vindex c-comment-continuation-stars
@vindex comment-continuation-stars (c-)
Normally the comment line prefix inserted for a new line inside a
comment is deduced from other lines in it. However there's one
-situation when there's no clue about how the prefix should look, namely
-when a block comment is broken for the first time. The string in the
-style variable @code{c-block-comment-prefix}@footnote{In versions before
-5.26, this variable was called @code{c-comment-continuation-stars}. As
-a compatibility measure, @ccmode{} still uses the value on that variable
-if it's set.} is used in that case. It defaults to @samp{* }, which
-makes a comment
-@example
+situation when there's no hint about what the prefix should look like,
+namely when a block comment is broken for the first time. This style
+variable@footnote{In versions before 5.26, this variable was called
+@code{c-comment-continuation-stars}. As a compatibility measure,
+@ccmode{} still uses the value on that variable if it's set.} is used
+then as the comment prefix. It defaults to @samp{* }, which makes a
+comment
+@example
/* Got O(n^2) here, which is a Bad Thing. */
-
@end example
@noindent
break into
+
@example
@group
-
/* Got O(n^2) here,
* which is a Bad Thing. */
-
@end group
@end example
-Note that it won't work to justify the indentation by putting leading
-spaces in the @code{c-block-comment-prefix} string, since @ccmode{}
-still uses the normal indentation engine to indent the line. Thus, the
-right way to fix the indentation is by setting the @code{c} syntactic
-symbol. It defaults to @code{c-lineup-C-comments}, which handles the
-indentation of most common comment styles, see @ref{Indentation
-Functions}.
+Note that it won't work to adjust the indentation by putting leading
+spaces in @code{c-block-comment-prefix}, since @ccmode{} still uses the
+normal indentation engine to indent the line. Thus, the right way to
+fix the indentation is by customizing the @code{c} syntactic symbol. It
+defaults to @code{c-lineup-C-comments}, which handles the indentation of
+most common comment styles, see @ref{Indentation Functions}.
+@end defopt
-@vindex c-ignore-auto-fill
+@defopt c-ignore-auto-fill
@vindex ignore-auto-fill (c-)
When auto fill mode is enabled, @ccmode{} can selectively ignore it
depending on the context the line break would occur in, e.g. to never
-break a line automatically inside a string literal. This behavior can
-be controlled with the @code{c-ignore-auto-fill} variable. It takes a
-list of symbols for the different contexts where auto-filling never
-should occur:
+break a line automatically inside a string literal. This variable
+takes a list of symbols for the different contexts where auto-filling
+never should occur:
-@itemize @bullet
-@item @code{string} --- Inside a string or character literal.
-@item @code{c} --- Inside a C style block comment.
-@item @code{c++} --- Inside a C++ style line comment.
-@item @code{cpp} --- Inside a preprocessor directive.
-@item @code{code} --- Anywhere else, i.e. in normal code.
-@end itemize
+@table @code
+@item string
+Inside a string or character literal.
+@item c
+Inside a C style block comment.
+@item c++
+Inside a C++ style line comment.
+@item cpp
+Inside a preprocessor directive.
+@item code
+Anywhere else, i.e. in normal code.
+@end table
By default, @code{c-ignore-auto-fill} is set to @code{'(string cpp
code)}, which means that auto-filling only occurs in comments when
@@ -1400,17 +1471,17 @@ code. In normal code, line breaks are normally dictated by some logical
structure in the code rather than the last whitespace character, so
automatic line breaks there will produce poor results in the current
implementation.
+@end defopt
-The commands that does the actual work follows.
+The commands that do the actual work follow.
@table @asis
-
+@item @kbd{M-q} (@code{c-fill-paragraph})
@kindex M-q
@findex c-fill-paragraph
@findex fill-paragraph (c-)
@cindex Javadoc markup
@cindex Pike autodoc markup
-@item @kbd{M-q} (@code{c-fill-paragraph})
This is the replacement for @code{fill-paragraph} in @ccmode{}
buffers. It's used to fill multiline string literals and both block and
line style comments. In Java buffers, the Javadoc markup words are
@@ -1426,10 +1497,10 @@ starter is handled similarly@footnote{This means that the variables
which controlled this behavior in earlier versions of @ccmode{}, are now
obsolete.}.
+@item @kbd{M-j} (@code{c-indent-new-comment-line})
@kindex M-j
@findex c-indent-new-comment-line
@findex indent-new-comment-line (c-)
-@item @kbd{M-j} (@code{c-indent-new-comment-line})
This is the replacement for @code{indent-new-comment-line}. It breaks
the line at point and indents the new line like the current one.
@@ -1439,27 +1510,424 @@ indentation and line prefix are preserved. If inside a comment and
@code{comment-multi-line} is @code{nil}, a new comment of the same type
is started on the next line and indented as appropriate for comments.
+Note that @ccmode{} sets @code{comment-multi-line} to @code{t} at
+startup. The reason is that @kbd{M-j} could otherwise produce sequences
+of single line block comments for texts that should logically be treated
+as one comment, and the rest of the paragraph handling code
+(e.g. @kbd{M-q} and @kbd{M-a}) can't cope with that, which would lead to
+inconsistent behavior.
+
+@item @kbd{M-x c-context-line-break}
@findex c-context-line-break
@findex context-line-break (c-)
-@item @kbd{M-x c-context-line-break}
This is a function that works like @code{indent-new-comment-line} in
comments and @code{newline-and-indent} elsewhere, thus combining those
two in a way that uses each one in the context it's best suited for.
-I.e. in comments the comment line prefix and indentation is kept for the
-new line, and in normal code it's indented according to context by the
-indentation engine.
+I.e. in comments the comment line prefix and indentation is kept for
+the new line, and in normal code it's indented according to context by
+the indentation engine.
+
+In macros it acts like @code{newline-and-indent} but additionally
+inserts and optionally aligns the line ending backslash so that the
+macro remains unbroken. @xref{Macro Handling}, for details about the
+backslash alignment.
It's not bound to a key by default, but it's intended to be used on the
@kbd{RET} key. If you like the behavior of @code{newline-and-indent} on
-@kbd{RET}, you might consider switching to this function.
+@kbd{RET}, you should consider switching to this function.
+
+@item @kbd{M-x c-context-open-line}
+@findex c-context-open-line
+@findex context-open-line (c-)
+This is to @kbd{C-o} (@kbd{M-x open-line}) as
+@code{c-context-line-break} is to @kbd{RET}. I.e. it works just like
+@code{c-context-line-break} but leaves the point before the inserted
+line break.
+@end table
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Macro Handling, Font Locking, Text Filling and Line Breaking, Top
+@comment node-name, next, previous, up
+@chapter Macro Handling
+@cindex macros
+@cindex preprocessor directives
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+Preprocessor directives are handled as syntactic whitespace from other
+code, i.e. they can be interspersed anywhere without affecting the
+syntactic analysis, just like comments.
+
+The code inside macro definitions is still analyzed syntactically so
+that you get relative indentation there just as you'd get if the same
+code was outside a macro. However, since there is no hint about the
+syntactic context, i.e. whether the macro expands to an expression, to some
+statements, or perhaps to whole functions, the syntactic recognition can be
+wrong. @ccmode{} manages to figure it out correctly most of the time,
+though. @xref{Syntactic Symbols}, for details about the indentation.
+
+@defopt c-syntactic-indentation-in-macros
+@vindex syntactic-indentation-in-macros (c-)
+Enable syntactic analysis inside macros, which is the default. If this
+is @code{nil}, all lines inside macro definitions are analyzed as
+@code{cpp-macro-cont}.
+@end defopt
+
+@ccmode{} provides some tools to help keep the line continuation
+backslashes in macros neat and tidy:
+
+@table @asis
+@item @kbd{C-c C-\} (@code{c-backslash-region})
+@kindex C-c C-\
+@findex c-backslash-region
+@findex backslash-region (c-)
+This function inserts and aligns or deletes the end-of-line backslashes
+in the current region.
+
+With no prefix argument, it inserts any missing backslashes and aligns
+them according to the @code{c-backslash-column} and
+@code{c-backslash-max-column} variables. With a prefix argument, it
+deletes any backslashes.
+
+The function does not modify blank lines at the start of the region. If
+the region ends at the start of a line, it always deletes the backslash
+(if any) at the end of the previous line.
+@end table
+
+@defopt c-backslash-column
+@vindex backslash-column (c-)
+@defoptx c-backslash-max-column
+@vindex backslash-max-column (c-)
+These variables control the alignment columns for line continuation
+backslashes in multiline macros. They are used by the functions that
+automatically insert or align such backslashes,
+e.g. @code{c-backslash-region} and @code{c-context-line-break}.
+
+@code{c-backslash-column} specifies the minimum column for the
+backslashes. If any line in the macro exceeds it then the next tab
+stop from that line is used as the alignment column for all the
+backslashes, so that they remain in a single column. However, if some
+lines exceed @code{c-backslash-max-column} then the backslashes in the
+rest of the macro will be kept at that column, so that the
+lines which are too long ``stick out'' instead.
+@end defopt
+
+@defopt c-auto-align-backslashes
+@vindex auto-align-backslashes (c-)
+Align automatically inserted line continuation backslashes if
+non-@code{nil}. When line continuation backslashes are inserted
+automatically for line breaks in multiline macros, e.g. by
+@code{c-context-line-break}, they are aligned with the other backslashes
+in the same macro if this flag is set. Otherwise the inserted
+backslashes are preceded by a single space.
+@end defopt
+
+The recommended line breaking function, @code{c-context-line-break}
+(@pxref{Text Filling and Line Breaking}), is especially nice if you edit
+multiline macros frequently. When used inside a macro, it automatically
+inserts and adjusts the mandatory backslash at the end of the line to
+keep the macro together, and it leaves the point at the right
+indentation column for the code. Thus you can write code inside macros
+almost exactly as you can elsewhere, without having to bother with the
+trailing backslashes.
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Font Locking, Commands, Macro Handling, Top
+@comment node-name, next, previous, up
+@chapter Font Locking
+@cindex font locking
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+@strong{Note:} The font locking in AWK mode is currently not integrated
+with the rest of @ccmode{}, so this section does not apply there.
+@xref{AWK Mode Font Locking}, instead.
+
+@cindex Font Lock mode
+
+@ccmode{} provides font locking for its supported languages by supplying
+patterns for use with Font Lock mode. This means that you get distinct
+faces on the various syntactic parts such as comments, strings, keywords
+and types, which is very helpful in telling them apart at a glance and
+discovering syntactic errors. @xref{Font Lock,,, emacs, The Emacs
+Editor}, for ways to enable font locking in @ccmode{} buffers.
+
+@menu
+* Font Locking Preliminaries::
+* Faces::
+* Documentation Comments::
+@end menu
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Font Locking Preliminaries, Faces, , Font Locking
+@comment node-name, next, previous, up
+@section Font Locking Preliminaries
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+The font locking for most of the @ccmode{} languages were provided
+directly by the Font Lock package prior to version 5.30 of @ccmode{}.
+In the transition to @ccmode{} the patterns have been reworked
+completely and are applied uniformly across all the languages except AWK
+mode, just like the indentation rules (although each language still has
+some pecularities of its own, of course). Since the languages
+previously had completely separate font locking patterns, this means
+that it's a bit different in most languages now.
+
+The main goal for the font locking in @ccmode{} is accuracy, to provide
+a dependable aid in recognizing the various constructs. Some, like
+strings and comments, are easy to recognize while others like
+declarations and types can be very tricky. @ccmode{} can go to great
+lengths to recognize declarations and casts correctly, especially when
+the types aren't recognized by standard patterns. This is a fairly
+demanding analysis which can be slow on older hardware, and it can
+therefore be disabled by choosing a lower decoration level with the
+variable @code{font-lock-maximum-decoration}.
+
+@vindex font-lock-maximum-decoration
+
+The decoration levels are used as follows:
+
+@enumerate
+@comment 1
+@item
+Minimal font locking: Fontify only comments, strings and preprocessor
+directives (in the languages that use cpp).
+
+@comment 2
+@item
+Fast normal font locking: In addition to level 1, fontify keywords,
+simple types and declarations that are easy to recognize. The variables
+@code{*-font-lock-extra-types} (where @samp{*} is the name of the
+language) are used to recognize types (see below). Documentation
+comments like Javadoc are fontified according to
+@code{c-doc-comment-style} (@pxref{Documentation Comments}).
+
+Use this if you think the font locking is too slow. It's the closest
+corresponding level to level 3 in the old font lock patterns.
+
+@comment 3
+@item
+Accurate normal font locking: Like level 2 but uses a different approach
+that can recognize types and declarations much more accurately. The
+@code{*-font-lock-extra-types} variables are still used, but user
+defined types are recognized correctly anyway in most cases. Therefore
+those variables should be fairly restrictive and not contain patterns
+that are uncertain.
+
+@cindex Lazy Lock mode
+@cindex Just-in-time Lock mode
+
+This level is designed for fairly modern hardware and a font lock
+support mode like Lazy Lock or Just-in-time Lock mode that only
+fontifies the parts that are actually shown.
+@end enumerate
+
+@cindex user defined types
+@cindex types, user defined
+
+Since user defined types are hard to recognize you can provide
+additional regexps to match those you use:
+
+@defopt c-font-lock-extra-types
+@defoptx c++-font-lock-extra-types
+@defoptx objc-font-lock-extra-types
+@defoptx java-font-lock-extra-types
+@defoptx idl-font-lock-extra-types
+@defoptx pike-font-lock-extra-types
+For each language there's a variable @code{*-font-lock-extra-types},
+where @samp{*} stands for the language in question. It contains a list
+of regexps that matches identifiers that should be recognized as types,
+e.g. @samp{\\sw+_t} to recognize all identifiers ending with @samp{_t}
+as is customary in C code. Each regexp should not match more than a
+single identifier.
+
+The default values contain regexps for many types in standard runtime
+libraries that are otherwise difficult to recognize, and patterns for
+standard type naming conventions like the @samp{_t} suffix in C and C++.
+Java, Objective-C and Pike have as a convention to start class names
+with capitals, so there are patterns for that in those languages.
+
+Despite the names of these variables, they are not only used for
+fontification but in other places as well where @ccmode{} needs to
+recognize types.
+@end defopt
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Faces, Documentation Comments, Font Locking Preliminaries, Font Locking
+@comment node-name, next, previous, up
+@section Faces
+@cindex faces
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+@ccmode{} attempts to use the standard faces for programming languages
+in accordance with their intended purposes as far as possible. No extra
+faces are currently provided, with the exception of a replacement face
+@code{c-invalid-face} for emacsen that don't provide
+@code{font-lock-warning-face}.
+
+@itemize @bullet
+@item
+@vindex font-lock-comment-face
+Normal comments are fontified in @code{font-lock-comment-face}.
+
+@item
+@vindex font-lock-doc-face
+@vindex font-lock-doc-string-face
+@vindex font-lock-comment-face
+Comments that are recognized as documentation (@pxref{Documentation
+Comments}) get @code{font-lock-doc-face} (Emacs) or
+@code{font-lock-doc-string-face} (XEmacs) if those faces exist. If they
+don't then @code{font-lock-comment-face} is used.
+
+@item
+@vindex font-lock-string-face
+String and character literals are fontified in
+@code{font-lock-string-face}.
+
+@item
+@vindex font-lock-keyword-face
+Keywords are fontified with @code{font-lock-keyword-face}.
+
+@item
+@vindex font-lock-function-name-face
+@code{font-lock-function-name-face} is used for function names in
+declarations and definitions, and classes in those contexts. It's also
+used for preprocessor defines with arguments.
+
+@item
+@vindex font-lock-variable-name-face
+Variables in declarations and definitions, and other identifiers in such
+variable contexts, get @code{font-lock-variable-name-face}. It's also
+used for preprocessor defines without arguments.
+
+@item
+@vindex font-lock-constant-face
+@vindex font-lock-reference-face
+Builtin constants are fontified in @code{font-lock-constant-face} if it
+exists, @code{font-lock-reference-face} otherwise. As opposed to the
+preceding two faces, this is used on the names in expressions, and it's
+not used in declarations, even if there happen to be a @samp{const} in
+them somewhere.
+
+@item
+@vindex font-lock-type-face
+@code{font-lock-type-face} is put on types (both predefined and user
+defined) and classes in type contexts.
+
+@item
+@vindex font-lock-constant-face
+@vindex font-lock-reference-face
+Label identifiers get @code{font-lock-constant-face} if it exists,
+@code{font-lock-reference-face} otherwise.
+@item
+Name qualifiers and identifiers for scope constructs are fontified like
+labels.
+
+@item
+Special markup inside documentation comments are also fontified like
+labels.
+
+@item
+@vindex font-lock-preprocessor-face
+@vindex font-lock-builtin-face
+@vindex font-lock-reference-face
+Preprocessor directives get @code{font-lock-preprocessor-face} if it
+exists (i.e. XEmacs). In Emacs they get @code{font-lock-builtin-face}
+or @code{font-lock-reference-face}, for lack of a closer equivalent.
+
+@item
+@vindex font-lock-warning-face
+@vindex c-invalid-face
+@vindex invalid-face (c-)
+Some kinds of syntactic errors are fontified with
+@code{font-lock-warning-face} in Emacs. In older XEmacs versions
+there's no corresponding standard face, so there a special
+@code{c-invalid-face} is used, which is defined to stand out sharply by
+default.
+
+Note that it's not used for @samp{#error} or @samp{#warning} directives,
+since those aren't syntactic errors in themselves.
+@end itemize
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Documentation Comments, , Faces, Font Locking
+@comment node-name, next, previous, up
+@section Documentation Comments
+@cindex documentation comments
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+There are various tools to supply documentation in the source as
+specially structured comments, e.g. the standard Javadoc tool in Java.
+@ccmode{} provides an extensible mechanism to fontify such comments and
+the special markup inside them.
+
+@defopt c-doc-comment-style
+@vindex doc-comment-style (c-)
+This is a style variable that specifies which documentation comment
+style to recognize, e.g. @code{javadoc} for Javadoc comments.
+
+The value may also be a list of styles, in which case all of them are
+recognized simultaneously (presumably with markup cues that don't
+conflict).
+
+The value may also be an association list to specify different comment
+styles for different languages. The symbol for the major mode is then
+looked up in the alist, and the value of that element is interpreted as
+above if found. If it isn't found then the symbol `other' is looked up
+and its value is used instead.
+
+Note that @ccmode{} uses this variable to set other variables that
+handle fontification etc. That's done at mode initialization or when
+you switch to a style which sets this variable. Thus, if you change it
+in some other way, e.g. interactively in a CC Mode buffer, you will need
+to do @kbd{M-x java-mode} (or whatever mode you're currently using) to
+reinitialize.
+
+@findex c-setup-doc-comment-style
+@findex setup-doc-comment-style (c-)
+Note also that when @ccmode{} starts up, the other variables are
+modified before the mode hooks are run. If you change this variable in
+a mode hook, you have to call @code{c-setup-doc-comment-style}
+afterwards to redo that work.
+@end defopt
+
+@ccmode{} currently provides handing of the following doc comment
+styles:
+
+@table @code
+@item javadoc
+@cindex Javadoc markup
+Javadoc comments, the standard tool in Java.
+
+@item autodoc
+@cindex Pike autodoc markup
+For Pike autodoc markup, the standard in Pike.
@end table
+The above is by no means complete. If you'd like to see support for
+other doc comment styles, please let us know (@pxref{Mailing Lists and
+Submitting Bug Reports}).
+
+You can also write your own doc comment fontification support to use
+with @code{c-doc-comment-style}: Supply a variable or function
+@code{*-font-lock-keywords} where @samp{*} is the name you want to use
+in @code{c-doc-comment-style}. If it's a variable, it's prepended to
+@code{font-lock-keywords}. If it's a function, it's called at mode
+initialization and the result is prepended. For an example, see
+@code{javadoc-font-lock-keywords} in @file{cc-fonts.el}.
+
+If you add support for another doc comment style, please consider
+contributing it --- send a note to @email{bug-cc-mode@@gnu.org}.
+
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Commands, Customizing Indentation, Text Filling and Line Breaking, Top
+@node Commands, Customizing Indentation, Font Locking, Top
@comment node-name, next, previous, up
-@chapter Commands
+@chapter Commands
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@menu
@@ -1468,152 +1936,179 @@ It's not bound to a key by default, but it's intended to be used on the
* Other Commands::
@end menu
-See also @ref{Text Filling and Line Breaking}, for commands concerning
-that bit.
+See also @ref{Text Filling and Line Breaking} and @ref{Macro Handling},
+for commands concerning those bits.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Indentation Commands, Movement Commands, , Commands
@comment node-name, next, previous,up
-@section Indentation Commands
-@cindex indentation commands
+@section Indentation Commands
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-The following list of commands re-indent C constructs. Note that when
-you change your coding style, either interactively or through some other
-means, your file does @emph{not} automatically get re-indented. You
-will need to execute one of the following commands to see the effects of
+The following list of commands reindent C constructs. Note that when
+you change your coding style, either interactively or through some other
+means, your file does @emph{not} automatically get reindented. You
+will need to execute one of the following commands to see the effects of
your changes.
@cindex GNU indent program
Also, variables like @code{c-hanging-*} and @code{c-cleanup-list}
only affect how on-the-fly code is formatted. Changing the
-``hanginess'' of a brace and then re-indenting, will not move the brace
+``hanginess'' of a brace and then reindenting, will not move the brace
to a different line. For this, you're better off getting an external
-program like GNU @code{indent}, which will re-arrange brace location,
+program like GNU @code{indent}, which will rearrange brace location,
among other things.
-Re-indenting large sections of code can take a long time. When
+Reindenting large sections of code can take a long time. When
@ccmode{} reindents a region of code, it is essentially equivalent to
-hitting @kbd{TAB} on every line of the region. Especially vulnerable is
-code generator output@footnote{In particular, I have had people
-complain about the speed with which @code{lex(1)} output is re-indented.
-Lex, yacc, and other code generators usually output some pretty
-perversely formatted code. Re-indenting such code will be slow.}.
+hitting @kbd{TAB} on every line of the region.
These commands are useful when indenting code:
@table @asis
-
+@item @kbd{TAB} (@code{c-indent-command})
@kindex TAB
@findex c-indent-command
@findex indent-command (c-)
-@item @kbd{TAB} (@code{c-indent-command})
Indents the current line. The actual behavior is controlled by several
variables, described below. See @code{c-tab-always-indent},
@code{c-insert-tab-function}, and @code{indent-tabs-mode}. With a
numeric argument, this command rigidly indents the region, preserving
the relative indentation among the lines.
+@item @kbd{C-M-q} (@code{c-indent-exp})
@kindex C-M-q
@findex c-indent-exp
@findex indent-exp (c-)
-@item @kbd{C-M-q} (@code{c-indent-exp})
Indent an entire balanced brace or parenthesis expression. Note that
point must be on the opening brace or parenthesis of the expression you
want to indent.
+@item @kbd{C-c C-q} (@code{c-indent-defun})
@kindex C-c C-q
@findex c-indent-defun
@findex indent-defun (c-)
-@item @kbd{C-c C-q} (@code{c-indent-defun})
-Indents the entire top-level function or class definition encompassing
-point. It leaves point unchanged. This function can't be used to
-re-indent a nested brace construct, such as a nested class or function,
-or a Java method. The top-level construct being re-indented must be
-complete, i.e. it must have both a beginning brace and an ending brace.
+Indents the entire top-level function, class or macro definition
+encompassing point. It leaves point unchanged. This function can't be
+used to reindent a nested brace construct, such as a nested class or
+function, or a Java method. The top-level construct being reindented
+must be complete, i.e. it must have both a beginning brace and an ending
+brace.
+@item @kbd{C-M-\} (@code{indent-region})
@kindex C-M-\
@findex indent-region
-@item @kbd{C-M-\} (@code{indent-region})
Indents an arbitrary region of code. This is a standard Emacs command,
-tailored for C code in a @ccmode{} buffer. Note that of course, point
+tailored for C code in a @ccmode{} buffer. Note, of course, that point
and mark must delineate the region you want to indent.
+@item @kbd{M-;} (@code{indent-for-comment})
+@kindex M-;
+@findex indent-for-comment
+Insert a comment at the end of the current line, if none is there already.
+Then reindent the comment according to the variables
+@code{c-indent-comment-alist}, @code{c-indent-comments-syntactically-p}
+and @code{comment-column}. Then position the point after the comment
+starter. This is a standard Emacs command, but @ccmode{} enhances it a
+bit with two variables:
+
+@defopt c-indent-comment-alist
+@vindex indent-comment-alist (c-)
+@vindex comment-column
+This style variable allows you to control which column @kbd{M-;}
+indents the comment to, depending on the preceding code and the
+indentation of a similar comment on the preceding line, if there is
+any. It is an association list that maps different types of lines to
+actions describing how they should be handled. If a certain line type
+isn't present on the list then the line is indented to the column
+specified by @code{comment-column}. See the documentation string for
+@code{c-indent-comment-alist} for a full description of the available
+line types and actions (use @kbd{C-h v c-indent-comment-alist}).
+@end defopt
+
+@defopt c-indent-comments-syntactically-p
+@vindex indent-comments-syntactically-p (c-)
+Normally, when this variable is @code{nil}, @kbd{M-;} will indent
+comment-only lines according to @code{c-indent-comment-alist}, just as
+it does with lines where other code precede the comments. However, if
+you want it to act just like @kbd{TAB} for comment-only lines you can
+get that by setting @code{c-indent-comments-syntactically-p} to
+non-@code{nil}.
+
+If @code{c-indent-comments-syntactically-p} is non-@code{nil} then
+@code{c-indent-comment-alist} won't be consulted at all for comment-only
+lines.
+@end defopt
+
+@item @kbd{C-M-h} (@code{c-mark-function})
@kindex C-M-h
@findex c-mark-function
@findex mark-function (c-)
-@item @kbd{C-M-h} (@code{c-mark-function})
While not strictly an indentation command, this is useful for marking
the current top-level function or class definition as the current
region. As with @code{c-indent-defun}, this command operates on
top-level constructs, and can't be used to mark say, a Java method.
-
@end table
These variables are also useful when indenting code:
-@table @code
-
-@vindex c-tab-always-indent
+@defopt c-tab-always-indent
@vindex tab-always-indent (c-)
@kindex TAB
@cindex literal
-@item c-tab-always-indent
-This variable controls how @kbd{TAB} @code{c-indent-command} operates.
-When this variable is @code{t}, @kbd{TAB} always just indents the
-current line. When it is @code{nil}, the line is indented only if point
-is at the left margin, or on or before the first non-whitespace
-character on the line, otherwise some whitespace is inserted. If this
-variable is the symbol @code{other}, then some whitespace is inserted
-only within strings and comments (literals), an inside preprocessor
-directives, but the line is always reindented.
-
-@vindex c-insert-tab-function
+This variable controls how @kbd{TAB} (@code{c-indent-command}) operates.
+When it is @code{t}, @kbd{TAB} always indents the current line. When it
+is @code{nil}, the line is indented only if point is at the left margin,
+or on or before the first non-whitespace character on the line,
+otherwise some whitespace is inserted. If this variable is the symbol
+@code{other}, then some whitespace is inserted only within strings and
+comments (literals), and inside preprocessor directives, but the line is
+always reindented.
+@end defopt
+
+@defopt c-insert-tab-function
@vindex insert-tab-function (c-)
@findex tab-to-tab-stop
-@item c-insert-tab-function
When ``some whitespace'' is inserted as described above, what actually
happens is that the function stored in @code{c-insert-tab-function} is
called. Normally, this just inserts a real tab character, or the
equivalent number of spaces, depending on @code{indent-tabs-mode}.
Some people, however, set @code{c-insert-tab-function} to
@code{tab-to-tab-stop} so as to get hard tab stops when indenting.
+@end defopt
-@vindex indent-tabs-mode
-@item indent-tabs-mode
-This is a standard Emacs variable that controls how line indentation is
-composed. When this variable is non-@code{nil}, then tabs can be used
-in a line's indentation, otherwise only spaces can be used.
+@defopt indent-tabs-mode
+This is a standard Emacs variable that controls how line indentation
+is composed. When it's non-@code{nil}, tabs can be used in a line's
+indentation, otherwise only spaces can be used.
+@end defopt
-@vindex c-progress-interval
+@defopt c-progress-interval
@vindex progress-interval (c-)
-@item c-progress-interval
When indenting large regions of code, this variable controls how often a
progress message is displayed. Set this variable to @code{nil} to
-inhibit the progress messages, or set it to an integer which is the
-interval in seconds that progress messages are displayed.
-
-@end table
+inhibit the progress messages, or set it to an integer which is how
+often (in seconds) progress messages are to be displayed.
+@end defopt
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Movement Commands, Other Commands, Indentation Commands, Commands
@comment node-name, next, previous, up
-@section Movement Commands
-@cindex movement commands
+@section Movement Commands
+@cindex movement
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@ccmode{} contains some useful command for moving around in C
+@ccmode{} contains some useful commands for moving around in C
code.
@table @asis
-
+@item @kbd{M-x c-beginning-of-defun}
@findex c-beginning-of-defun
@findex beginning-of-defun (c-)
@findex beginning-of-defun
-@item @kbd{M-x c-beginning-of-defun}
-Moves point back to the least-enclosing brace. This function is
+Move point back to the least-enclosing brace. This function is
analogous to the Emacs built-in command @code{beginning-of-defun},
except it eliminates the constraint that the top-level opening brace
must be in column zero. See @code{beginning-of-defun} for more
@@ -1624,14 +2119,20 @@ Depending on the coding style being used, you might prefer
consider binding @kbd{C-M-a} to the former instead. For backwards
compatibility reasons, the default binding remains in effect.
+In AWK mode, a defun doesn't necessarily have braces at all. AWK Mode
+therefore has its own version of this function which is bound by
+default to @kbd{C-M-a}. You can thus chose freely which function to
+bind to @kbd{C-M-a} for the other modes without worrying about AWK
+buffers. @xref{AWK Mode Defuns}.
+
+@item @kbd{M-x c-end-of-defun}
@findex c-end-of-defun
@findex end-of-defun (c-)
@findex end-of-defun
-@item @kbd{M-x c-end-of-defun}
Moves point to the end of the current top-level definition. This
function is analogous to the Emacs built-in command @code{end-of-defun},
except it eliminates the constraint that the top-level opening brace of
-the defun must be in column zero. See @code{beginning-of-defun} for more
+the defun must be in column zero. See @code{end-of-defun} for more
information.
Depending on the coding style being used, you might prefer
@@ -1639,10 +2140,16 @@ Depending on the coding style being used, you might prefer
consider binding @kbd{C-M-e} to the former instead. For backwards
compatibility reasons, the default binding remains in effect.
+In AWK Mode, a defun doesn't necessarily have braces at all. AWK Mode
+therefore has its own version of this function which is bound by
+default to @kbd{C-M-e}. You can thus chose freely which function to
+bind to @kbd{C-M-e} for the other modes without worrying about AWK
+buffers. @ref{AWK Mode Defuns}.
+
+@item @kbd{C-c C-u} (@code{c-up-conditional})
@kindex C-c C-u
@findex c-up-conditional
@findex up-conditional (c-)
-@item @kbd{C-c C-u} (@code{c-up-conditional})
Move point back to the containing preprocessor conditional, leaving the
mark behind. A prefix argument acts as a repeat count. With a negative
argument, move point forward to the end of the containing
@@ -1651,15 +2158,15 @@ preprocessor conditional.
@samp{#elif} is treated like @samp{#else} followed by @samp{#if}, so the
function stops at them when going backward, but not when going forward.
+@item @kbd{M-x c-up-conditional-with-else}
@findex c-up-conditional-with-else
@findex up-conditional-with-else (c-)
-@item @kbd{M-x c-up-conditional-with-else}
A variety of @code{c-up-conditional} that also stops at @samp{#else}
lines. Normally those lines are ignored.
+@item @kbd{M-x c-down-conditional}
@findex c-down-conditional
@findex down-conditional (c-)
-@item @kbd{M-x c-down-conditional}
Move point forward into the next nested preprocessor conditional,
leaving the mark behind. A prefix argument acts as a repeat count.
With a negative argument, move point backward into the previous
@@ -1668,32 +2175,32 @@ nested preprocessor conditional.
@samp{#elif} is treated like @samp{#else} followed by @samp{#if}, so the
function stops at them when going forward, but not when going backward.
+@item @kbd{M-x c-down-conditional-with-else}
@findex c-down-conditional-with-else
@findex down-conditional-with-else (c-)
-@item @kbd{M-x c-down-conditional-with-else}
A variety of @code{c-down-conditional} that also stops at @samp{#else}
lines. Normally those lines are ignored.
+@item @kbd{C-c C-p} (@code{c-backward-conditional})
@kindex C-c C-p
@findex c-backward-conditional
@findex backward-conditional (c-)
-@item @kbd{C-c C-p} (@code{c-backward-conditional})
Move point back over a preprocessor conditional, leaving the mark
behind. A prefix argument acts as a repeat count. With a negative
argument, move forward.
+@item @kbd{C-c C-n} (@code{c-forward-conditional})
@kindex C-c C-n
@findex c-forward-conditional
@findex forward-conditional (c-)
-@item @kbd{C-c C-n} (@code{c-forward-conditional})
Move point forward across a preprocessor conditional, leaving the mark
behind. A prefix argument acts as a repeat count. With a negative
argument, move backward.
+@item @kbd{M-a} (@code{c-beginning-of-statement})
@kindex M-a
@findex c-beginning-of-statement
@findex beginning-of-statement (c-)
-@item @kbd{M-a} (@code{c-beginning-of-statement})
Move point to the beginning of the innermost C statement. If point is
already at the beginning of a statement, move to the beginning of the
closest preceding statement, even if that means moving into a block (you
@@ -1708,10 +2215,10 @@ arguments: the repetition count, a buffer position limit which is the
farthest back to search for the syntactic context, and a flag saying
whether to do sentence motion in or near comments and multiline strings.
+@item @kbd{M-e} (@code{c-end-of-statement})
@kindex M-e
@findex c-end-of-statement
@findex end-of-statement (c-)
-@item @kbd{M-e} (@code{c-end-of-statement})
Move point to the end of the innermost C statement. If point is at the
end of a statement, move to the end of the next statement, even if it's
inside a nested block (use @kbd{C-M-f} to move to the other side of the
@@ -1726,9 +2233,9 @@ arguments: the repetition count, a buffer position limit which is the
farthest back to search for the syntactic context, and a flag saying
whether to do sentence motion in or near comments and multiline strings.
+@item @kbd{M-x c-forward-into-nomenclature}
@findex c-forward-into-nomenclature
@findex forward-into-nomenclature (c-)
-@item @kbd{M-x c-forward-into-nomenclature}
A popular programming style, especially for object-oriented languages
such as C++ is to write symbols in a mixed case format, where the first
letter of each word is capitalized, and not separated by underscores.
@@ -1737,69 +2244,51 @@ E.g. @samp{SymbolsWithMixedCaseAndNoUnderlines}.
This command moves point forward to next capitalized word. With prefix
argument @var{n}, move @var{n} times.
+@item @kbd{M-x c-backward-into-nomenclature}
@findex c-backward-into-nomenclature
@findex backward-into-nomenclature (c-)
-@item @kbd{M-x c-backward-into-nomenclature}
Move point backward to beginning of the next capitalized
word. With prefix argument @var{n}, move @var{n} times. If
@var{n} is negative, move forward.
-
@end table
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Other Commands, , Movement Commands, Commands
@comment node-name, next, previous, up
-@section Other Commands
+@section Other Commands
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@ccmode{} contains a few other useful commands:
+Here are the various other commands that didn't fit anywhere else:
@table @asis
-
+@item @kbd{C-c :} (@code{c-scope-operator})
@kindex C-c :
@findex c-scope-operator
@findex scope-operator (c-)
-@item @kbd{C-c :} (@code{c-scope-operator})
In C++, it is also sometimes desirable to insert the double-colon scope
operator without performing the electric behavior of colon insertion.
@kbd{C-c :} does just this.
-
-@kindex C-c C-\
-@findex c-backslash-region
-@findex backslash-region (c-)
-@item @kbd{C-c C-\} (@code{c-backslash-region})
-This function is handy when editing macros split over several lines by
-ending each line with a backslash. It inserts and aligns, or deletes
-these end-of-line backslashes in the current region.
-
-@vindex c-backslash-column
-@vindex backslash-column (c-)
-With no prefix argument, it inserts any missing backslashes and aligns
-them to the column specified by the @code{c-backslash-column} style
-variable. With a prefix argument, it deletes any backslashes.
-
-The function does not modify blank lines at the start of the region. If
-the region ends at the start of a line, it always deletes the backslash
-(if any) at the end of the previous line.
-
@end table
-
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Customizing Indentation, Syntactic Symbols, Commands, Top
@comment node-name, next, previous, up
-@chapter Customizing Indentation
-@cindex customizing indentation
+@chapter Customizing Indentation
+@cindex customization, indentation
+@cindex indentation
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-offsets-alist
+The context sensitive indentation is mainly controlled by the variable
+@code{c-offsets-alist}:
+
+@defopt c-offsets-alist
@vindex offsets-alist (c-)
-The style variable @code{c-offsets-alist} contains the mappings between
-syntactic symbols and the offsets to apply for those symbols. It's set
-at mode initialization from a @emph{style} you may specify. Styles are
+This special style variable contains the mappings between syntactic
+symbols and the offsets to apply for those symbols. It's set at mode
+initialization from a @emph{style} you may specify. Styles are
groupings of syntactic symbol offsets and other style variable values.
-Most likely, you'll find that one of the pre-defined styles will suit
+Most likely, you'll find that one of the predefined styles will suit
your needs. @xref{Styles}, for an explanation of how to set up named
styles.
@@ -1812,30 +2301,27 @@ XEmacs 19.15 and later.} to easily change indentation offsets without
having to bother about styles. Initially @code{c-offsets-alist} is
empty, so that all syntactic symbols are set by the style system.
-@kindex C-c C-o
-@findex c-set-offset
-@findex set-offset (c-)
-You can use the command @kbd{C-c C-o} (@code{c-set-offset}) as the way
-to set offsets, both interactively and from your mode
-hook@footnote{Obviously, you use the key binding interactively, and the
-function call programmatically!}.
+The offset associated with any particular syntactic symbol can be an
+integer, a function or lambda expression, a variable name, a vector, a
+list, or one of the following special symbols: @code{+}, @code{-},
+@code{++}, @code{--}, @code{*}, or @code{/}. The meaning of these
+values are described in detail below.
+@end defopt
+
+The special symbols describe an offset in multiples of the value of
+@code{c-basic-offset}:
-@vindex c-basic-offset
+@defopt c-basic-offset
@vindex basic-offset (c-)
-The offset associated with any particular syntactic symbol can be any of
-an integer, a function or lambda expression, a variable name, a vector,
-a list, or one of the following symbols: @code{+}, @code{-}, @code{++},
-@code{--}, @code{*}, or @code{/}.
-
-Those last special symbols describe an offset in multiples of the value
-of the style variable @code{c-basic-offset}. By defining a style's
-indentation in terms of this fundamental variable, you can change the
-amount of whitespace given to an indentation level while maintaining the
-same basic shape of your code. Here are the values that the special
-symbols correspond to:
+Style variable that holds the basic offset between indentation levels.
+@end defopt
-@table @code
+By defining a style's indentation in terms of @code{c-basic-offset},
+you can change the amount of whitespace given to an indentation level
+while maintaining the same basic shape of your code. Here are the
+values that the special symbols correspond to:
+@table @code
@item +
@code{c-basic-offset} times 1
@item -
@@ -1848,7 +2334,6 @@ symbols correspond to:
@code{c-basic-offset} times 0.5
@item /
@code{c-basic-offset} times -0.5
-
@end table
@cindex indentation functions
@@ -1860,7 +2345,9 @@ syntactic symbol is needed to get the desired indentation.
for details about them.
If the offset is a vector, its first element sets the absolute
-indentation column, which will override any relative indentation.
+indentation column, which will override any previous relative
+indentation. It won't override additional relative indentation for
+nested constructs, though.
@vindex c-strict-syntax-p
@vindex strict-syntax-p (c-)
@@ -1870,7 +2357,7 @@ returns a non-@code{nil} value succeeds and the evaluation stops. If
none of the list elements return a non-@code{nil} value, then an offset
of 0 (zero) is used@footnote{There is however a variable
@code{c-strict-syntax-p} that, when set to non-@code{nil}, will cause an
-error to be signaled in that case. It's now considered obsolete since
+error to be signalled in that case. It's now considered obsolete since
it doesn't work well with some of the alignment functions that now
returns @code{nil} instead of zero to be more usable in lists. You
should therefore leave @code{c-strict-syntax-p} set to @code{nil}.}.
@@ -1881,19 +2368,18 @@ indentation style, but you use 4 spaces instead of 2 spaces per level,
you can probably achieve your style just by changing
@code{c-basic-offset} like so@footnote{You can try this interactively in
a C buffer by typing the text that appears in italics.}:
-@example
+@example
@emph{M-x set-variable RET}
Set variable: @emph{c-basic-offset RET}
Set c-basic-offset to value: @emph{4 RET}
-
@end example
@noindent
This would change
+
@example
@group
-
int add( int val, int incr, int doit )
@{
if( doit )
@@ -1902,14 +2388,14 @@ int add( int val, int incr, int doit )
@}
return( val );
@}
-
@end group
@end example
+
@noindent
to
+
@example
@group
-
int add( int val, int incr, int doit )
@{
if( doit )
@@ -1918,7 +2404,6 @@ int add( int val, int incr, int doit )
@}
return( val );
@}
-
@end group
@end example
@@ -1939,42 +2424,42 @@ your @file{.emacs} file so that your changes are more permanent.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Interactive Customization, Permanent Customization, , Customizing Indentation
@comment node-name, next, previous, up
-@section Interactive Customization
+@section Interactive Customization
+@cindex customization, interactive
@cindex interactive customization
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
As an example of how to customize indentation, let's change the
-style of this example@footnote{In this an subsequent examples, the
+style of this example@footnote{In this and subsequent examples, the
original code is formatted using the @samp{gnu} style unless otherwise
indicated. @xref{Styles}.}:
+
@example
@group
-
-1: int add( int val, int incr, int doit )
-2: @{
-3: if( doit )
-4: @{
-5: return( val + incr );
-6: @}
-7: return( val );
-8: @}
-
+ 1: int add( int val, int incr, int doit )
+ 2: @{
+ 3: if( doit )
+ 4: @{
+ 5: return( val + incr );
+ 6: @}
+ 7: return( val );
+ 8: @}
@end group
@end example
+
@noindent
to:
+
@example
@group
-
-1: int add( int val, int incr, int doit )
-2: @{
-3: if( doit )
-4: @{
-5: return( val + incr );
-6: @}
-7: return( val );
-8: @}
-
+ 1: int add( int val, int incr, int doit )
+ 2: @{
+ 3: if( doit )
+ 4: @{
+ 5: return( val + incr );
+ 6: @}
+ 7: return( val );
+ 8: @}
@end group
@end example
@@ -1984,16 +2469,17 @@ conditional, instead of being indented. Notice that the construct we
want to change starts on line 4. To change the indentation of a line,
we need to see which syntactic components affect the offset calculations
for that line. Hitting @kbd{C-c C-s} on line 4 yields:
-@example
-
-((substatement-open . 44))
+@example
+((substatement-open 44))
@end example
@noindent
so we know that to change the offset of the open brace, we need to
change the indentation for the @code{substatement-open} syntactic
-symbol. To do this interactively, just hit @kbd{C-c C-o}. This prompts
+symbol.
+
+To do this interactively, just hit @kbd{C-c C-o}. This prompts
you for the syntactic symbol to change, providing a reasonable default.
In this case, the default is @code{substatement-open}, which is just the
syntactic symbol we want to change!
@@ -2007,18 +2493,17 @@ syntactic symbol @code{substatement-open}.
To check your changes quickly, just hit @kbd{C-c C-q}
(@code{c-indent-defun}) to reindent the entire function. The example
should now look like:
+
@example
@group
-
-1: int add( int val, int incr, int doit )
-2: @{
-3: if( doit )
-4: @{
-5: return( val + incr );
-6: @}
-7: return( val );
-8: @}
-
+ 1: int add( int val, int incr, int doit )
+ 2: @{
+ 3: if( doit )
+ 4: @{
+ 5: return( val + incr );
+ 6: @}
+ 7: return( val );
+ 8: @}
@end group
@end example
@@ -2027,14 +2512,27 @@ needed to do. Since the other affected lines are indented relative to
line 4, they are automatically indented the way you'd expect. For more
complicated examples, this may not always work. The general approach to
take is to always start adjusting offsets for lines higher up in the
-file, then re-indent and see if any following lines need further
+file, then reindent and see if any following lines need further
adjustments.
+@deffn Command c-set-offset symbol offset
+@findex set-offset (c-)
+@kindex C-c C-o
+This is the command bound to @kbd{C-c C-o}. It provides a convenient
+way to set offsets on @code{c-offsets-alist} both interactively (see
+the example above) and from your mode hook.
+
+It takes two arguments when used programmatically: @var{symbol} is the
+syntactic element symbol to change and @var{offset} is the new offset
+for that syntactic element.
+@end deffn
+
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Permanent Customization, Hooks, Interactive Customization, Customizing Indentation
@comment node-name, next, previous, up
-@section Permanent Customization
+@section Permanent Customization
+@cindex customization, permanent
@cindex permanent customization
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -2046,27 +2544,26 @@ precisely controlled way by using styles and hook functions.
The simplest way of customizing @ccmode{} permanently is to set the
variables in your @file{.emacs} with @code{setq} and similar commands.
-So to make the setting of @code{substatement-open} permanent, add this
-to the @file{.emacs} file:
+So to make a permanent setting of @code{substatement-open} to 0, add
+this to the @file{.emacs} file:
+
@example
@group
-
-(require 'cc-mode)
-(c-set-offset 'substatement-open 0)
-
+(setq c-offsets-alist
+ '((substatement-open . 0)))
@end group
@end example
-The @code{require} line is only needed once in the beginning to make
-sure @ccmode{} is loaded so that the @code{c-set-offset} function is
-defined.
+When @ccmode{} initializes a buffer, it will fill out
+@code{c-offsets-alist} with the remaining syntactic symbols according to
+the style system.
You can also use the more user friendly Customization interface, but
this manual does not cover how that works.
Variables set like this at the top level in @file{.emacs} take effect in
all @ccmode{} buffers, regardless of language. The indentation style
-related variables, e.g. @code{c-basic-offset}, that you don't set this
+related variables, e.g. @code{c-offsets-alist}, that you don't set this
way get their value from the style system (@pxref{Styles}), and they
therefore depend on the setting of @code{c-default-style}. Note that if
you use Customize, this means that the greyed-out default values
@@ -2075,73 +2572,55 @@ values depend on the style, which may very well be different for
different languages.
If you want to make more advanced configurations, e.g. language-specific
-customization, global variable settings isn't enough. For that you can
+customization, setting global variables isn't enough. For that you can
use the language hooks, see @ref{Hooks}, and/or the style system, see
@ref{Styles}.
-@vindex c-style-variables-are-local-p
+@defopt c-style-variables-are-local-p
@vindex style-variables-are-local-p (c-)
-By default, all style variables are global, so that every buffer will
-share the same style settings. This is fine if you primarily edit one
-style of code, but if you edit several languages and want to use
-different styles for them, you need finer control by making the style
-variables buffer local. The recommended way to do this is to set the
-variable @code{c-style-variables-are-local-p} to @code{t}. The
-variables will be made buffer local when @ccmode{} is activated in a
-buffer for the first time in the Emacs session. Note that once the
-style variables are made buffer local, they cannot be made global again,
-without restarting Emacs.
+By default, all style variables are buffer local, so that different
+buffers can have different style settings. If you only use one style
+in all the files you edit you might want to share them between buffers
+so that a change take effect in all buffers. That's done by setting
+this variable to @code{nil}. The value takes effect when @ccmode{} is
+activated in a buffer for the first time in the Emacs session, so you
+typically set it in your @file{.emacs} file and then restart Emacs.
+@end defopt
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Hooks, Styles, Permanent Customization, Customizing Indentation
@comment node-name, next, previous, up
-@section Hooks
-@cindex hooks
+@section Hooks
+@cindex mode hooks
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-mode-common-hook
-@vindex mode-common-hook (c-)
-@vindex c-mode-hook
-@vindex c++-mode-hook
-@vindex objc-mode-hook
-@vindex java-mode-hook
-@vindex idl-mode-hook
-@vindex pike-mode-hook
-@vindex c-initialization-hook
-@vindex initialization-hook (c-)
@ccmode{} provides several hooks that you can use to customize the mode
according to your coding style. Each language mode has its own hook,
adhering to standard Emacs major mode conventions. There is also one
general hook and one package initialization hook:
-@itemize @bullet
-
-@item
-@code{c-mode-hook} --- For C buffers only.
-@item
-@code{c++-mode-hook} --- For C++ buffers only.
-@item
-@code{objc-mode-hook} --- For Objective-C buffers only.
-@item
-@code{java-mode-hook} --- For Java buffers only.
-@item
-@code{idl-mode-hook} --- For CORBA IDL buffers only.
-@item
-@code{pike-mode-hook} --- For Pike buffers only.
-@item
-@code{c-mode-common-hook} --- Common across all languages.
-@item
-@code{c-initialization-hook} --- Hook run only once per Emacs session,
-when @ccmode{} is initialized.
-
-@end itemize
+@defvar c-initialization-hook
+@vindex initialization-hook (c-)
+Hook run only once per Emacs session, when @ccmode{} is initialized.
+@end defvar
-The language hooks get run as the last thing when you enter that
-language mode. The @code{c-mode-common-hook} is run by all supported
-modes @emph{before} the language specific hook, and thus can contain
-customizations that are common across all languages. Most of the
-examples in this section will assume you are using the common hook.
+@defvar c-mode-common-hook
+@vindex mode-common-hook (c-)
+Common hook across all languages. It's run immediately before the
+language specific hook.
+@end defvar
+
+@defvar c-mode-hook
+@defvarx c++-mode-hook
+@defvarx objc-mode-hook
+@defvarx java-mode-hook
+@defvarx idl-mode-hook
+@defvarx pike-mode-hook
+@defvarx awk-mode-hook
+The language specific mode hooks. The appropriate one is run as the
+last thing when you enter that language mode.
+@end defvar
Note that all the language-specific mode setup that CC Mode does is done
prior to both @code{c-mode-common-hook} and the language specific hook.
@@ -2155,23 +2634,20 @@ file to do things whenever any @ccmode{} language is edited. See the
Emacs manuals for more information on customizing Emacs via hooks.
@xref{Sample .emacs File}, for a more complete sample @file{.emacs}
file.
-@example
-@group
+@example
(defun my-c-mode-common-hook ()
;; my customizations for all of c-mode and related modes
(no-case-fold-search)
)
(add-hook 'c-mode-common-hook 'my-c-mode-common-hook)
-
-@end group
@end example
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Styles, Advanced Customizations, Hooks, Customizing Indentation
@comment node-name, next, previous, up
-@section Styles
+@section Styles
@cindex styles
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -2192,14 +2668,14 @@ variables}. They are handled specially in several ways:
@itemize @bullet
@item
-Style variables are by default global variables, i.e. they have the same
-value in all Emacs buffers. However, they can instead be made always
-buffer local by setting @code{c-style-variables-are-local-p} to
-non-@code{nil} before @ccmode{} is initialized.
+Style variables are by default buffer local variables. However, they
+can instead be made global by setting
+@code{c-style-variables-are-local-p} to @code{nil} before @ccmode{} is
+initialized.
+@item
@vindex c-old-style-variable-behavior
@vindex old-style-variable-behavior (c-)
-@item
The default value of any style variable (with two exceptions --- see
below) is the special symbol @code{set-from-style}. Variables that are
still set to that symbol when a @ccmode{} buffer is initialized will be
@@ -2232,7 +2708,6 @@ in version 5.26.}.
The global settings of style variables get captured in the special
@code{user} style, which is used as the base for all the other styles.
@xref{Built-in Styles}, for details.
-
@end itemize
The style variables are:
@@ -2245,79 +2720,79 @@ The style variables are:
@code{c-hanging-colons-alist},
@code{c-hanging-semi&comma-criteria},
@code{c-backslash-column},
+@code{c-backslash-max-column},
@code{c-special-indent-hook},
@code{c-label-minimum-indentation}, and
@code{c-offsets-alist}.
@menu
* Built-in Styles::
+* Choosing a Style::
* Adding Styles::
* File Styles::
@end menu
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Built-in Styles, Adding Styles, , Styles
+@node Built-in Styles, Choosing a Style, , Styles
@comment node-name, next, previous, up
@subsection Built-in Styles
-@cindex built-in styles
+@cindex styles, built-in
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
If you're lucky, one of @ccmode{}'s built-in styles might be just
what you're looking for. These include:
-@itemize @bullet
+@table @code
+@item gnu
@cindex GNU style
-@item
-@code{gnu} --- Coding style blessed by the Free Software Foundation
+Coding style blessed by the Free Software Foundation
for C code in GNU programs.
+@item k&r
@cindex K&R style
-@item
-@code{k&r} --- The classic Kernighan and Ritchie style for C code.
+The classic Kernighan and Ritchie style for C code.
+@item bsd
@cindex BSD style
-@item
-@code{bsd} --- Also known as ``Allman style'' after Eric Allman.
+Also known as ``Allman style'' after Eric Allman.
-@cindex Whitesmiths style
-@item
-@code{whitesmith} --- Popularized by the examples that came with
-Whitesmiths C, an early commercial C compiler.
+@item whitesmith
+@cindex Whitesmith style
+Popularized by the examples that came with Whitesmiths C, an early
+commercial C compiler.
+@item stroustrup
@cindex Stroustrup style
-@item
-@code{stroustrup} --- The classic Stroustrup style for C++ code.
+The classic Stroustrup style for C++ code.
+@item ellemtel
@cindex Ellemtel style
-@item
-@code{ellemtel} --- Popular C++ coding standards as defined by
-``Programming in C++, Rules and Recommendations,'' Erik Nyquist and Mats
-Henricson, Ellemtel@footnote{This document is available at
+Popular C++ coding standards as defined by ``Programming in C++, Rules
+and Recommendations,'' Erik Nyquist and Mats Henricson,
+Ellemtel@footnote{This document is available at
@uref{http://www.doc.ic.ac.uk/lab/cplus/c++.rules/} among other
places.}.
+@item linux
@cindex Linux style
-@item
-@code{linux} --- C coding standard for Linux (the kernel).
+C coding standard for Linux (the kernel).
+@item python
@cindex Python style
-@item
-@code{python} --- C coding standard for Python extension
-modules@footnote{Python is a high level scripting language with a C/C++
-foreign function interface. For more information, see
-@uref{http://www.python.org/}.}.
+C coding standard for Python extension modules@footnote{Python is a
+high level scripting language with a C/C++ foreign function interface.
+For more information, see @uref{http://www.python.org/}.}.
+@item java
@cindex Java style
-@findex java-mode
-@item
-@code{java} --- The style for editing Java code. Note that the default
+The style for editing Java code. Note that the default
value for @code{c-default-style} installs this style when you enter
@code{java-mode}.
+@item user
@cindex User style
-@item
-@code{user} --- This is a special style for several reasons. First, the
+This is a special style for several reasons. First, the
@ccmode{} customizations you do by using either the Customization
interface, or by writing @code{setq}'s at the top level of your
@file{.emacs} file, will be captured in the @code{user} style. Also,
@@ -2325,148 +2800,145 @@ all other styles implicitly inherit their settings from @code{user}
style. This means that for any styles you add via @code{c-add-style}
(@pxref{Adding Styles}) you need only define the differences between
your new style and @code{user} style.
+@end table
-@end itemize
-@vindex c-default-style
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Choosing a Style, Adding Styles, Built-in Styles, Styles
+@comment node-name, next, previous, up
+@subsection Choosing a Style
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+Use @kbd{C-c .} to choose a style interactively:
+
+@deffn Command c-set-style style-name
+@findex set-style (c-)
+@kindex C-c .
+Switch to the specified style in the current buffer. Use
+interactively like this:
+
+@example
+@kbd{C-c . @var{style-name} RET}
+@end example
+
+Note that all style names are case insensitive, even the ones you
+define.
+
+Setting a style in this way does @emph{not} automatically reindent your
+file. For commands that you can use to view the effect of your changes,
+see @ref{Commands}.
+@end deffn
+
+The default style in all newly created buffers is @code{gnu}, except
+in Java mode where it's @code{java}. Although the @code{user} style
+is not the default style, any style variable settings you do with the
+Customization interface or on the top level in your @file{.emacs} file
+will by default override the style system, so you don't need to set
+@code{c-default-style} to @code{user} to see the effect of such
+settings.
+
+@defopt c-default-style
@vindex default-style (c-)
-The default style in all newly created buffers is @code{gnu}, but you
-can change this by setting variable @code{c-default-style}. Although
-the @code{user} style is not the default style, any style variable
-settings you do with the Customization interface or on the top level in
-your @file{.emacs} file will by default override the style system, so
-you don't need to set @code{c-default-style} to @code{user} to see the
-effect of these settings.
-
-@code{c-default-style} takes either a style name string, or an
-association list of major mode symbols to style names. Thus you can
-control exactly which default style is used for which @ccmode{} language
-mode. Here are the rules:
-
-@vindex c-style-alist
-@vindex style-alist (c-)
-@vindex c-mode-common-hook
-@vindex mode-common-hook (c-)
+This variable specifies which style to install by default in new
+buffers. It takes either a style name string, or an association list
+of major mode symbols to style names:
+
@enumerate
@item
When @code{c-default-style} is a string, it must be an existing style
-name as found in @code{c-style-alist}. This style is then used for all
-modes.
+name. This style is then used for all modes.
@item
-When @code{c-default-style} is an association list, the current major
-mode is looked up to find a style name string. In this case, this style
-is always used exactly as specified and an error will occur if the named
-style does not exist.
+When @code{c-default-style} is an association list, the mode language
+is looked up to find a style name string.
@item
-If @code{c-default-style} is an association list, but the current major
-mode isn't found, then the special symbol @samp{other} is looked up. If
-this value is found, the associated style is used.
+If @code{c-default-style} is an association list where the mode
+language mode isn't found then the special symbol @samp{other} is
+looked up. If it's found then the associated style is used.
@item
-If @samp{other} is not found, then the @samp{gnu} style is used.
+If @samp{other} is not found then the @samp{gnu} style is used.
@item
-In all cases, the style described in @code{c-default-style} is installed
+In all cases, the style described in @code{c-default-style} is installed
@emph{before} the language hooks are run, so you can always override
-this setting by including an explicit call to @code{c-set-style} in your
+this setting by including an explicit call to @code{c-set-style} in your
language mode hook, or in @code{c-mode-common-hook}.
-
@end enumerate
+@end defopt
-@findex c-set-style
-@findex set-style (c-)
-@kindex C-c .
-If you'd like to experiment with these built-in styles you can simply
-type the following in a @ccmode{} buffer:
-@example
-@group
-
-@kbd{C-c . @var{STYLE-NAME} RET}
-
-@end group
-@end example
-@noindent
-@kbd{C-c .} runs the command @code{c-set-style}. Note that all style
-names are case insensitive, even the ones you define.
-
-Setting a style in this way does @emph{not} automatically re-indent your
-file. For commands that you can use to view the effect of your changes,
-see @ref{Commands}.
-
-@vindex c-indentation-style
+@defvar c-indentation-style
@vindex indentation-style (c-)
-Note that for BOCM compatibility, @samp{gnu} is the default style, and
-any non-style based customizations you make (i.e. in
-@code{c-mode-common-hook} in your @file{.emacs} file) will be based on
-@samp{gnu} style unless you set @code{c-default-style} or do a
-@code{c-set-style} as the first thing in your hook. The variable
-@code{c-indentation-style} always contains the buffer's current style
-name, as a string.
+This variable always contains the buffer's current style name, as a
+string.
+@end defvar
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Adding Styles, File Styles, Built-in Styles, Styles
+@node Adding Styles, File Styles, Choosing a Style, Styles
@comment node-name, next, previous, up
@subsection Adding Styles
-@cindex adding styles
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-style-alist
-@vindex style-alist (c-)
-@findex c-add-style
-@findex add-style (c-)
If none of the built-in styles is appropriate, you'll probably want to
add a new @dfn{style definition}. Styles are kept in the
-@code{c-style-alist} variable, but you should never modify this variable
-directly. Instead, @ccmode{} provides the function
+@code{c-style-alist} variable, but you should never modify this
+variable directly. Instead, @ccmode{} provides the function
@code{c-add-style} that you can use to easily add new styles or change
-existing styles. This function takes two arguments, a @var{stylename}
-string, and an association list @var{description} of style
-customizations. If @var{stylename} is not already in
-@code{c-style-alist}, the new style is added, otherwise the style is
-changed to the new @var{description}.
-This function also takes an optional third argument, which if
-non-@code{nil}, automatically applies the new style to the current
-buffer.
+existing styles:
+
+@defun c-add-style stylename description &optional set-p
+@findex add-style (c-)
+Add or update a style. If @var{stylename} is not already in
+@code{c-style-alist} then a new style according to @var{description}
+is added, otherwise the existing style is changed. If the optional
+@var{set-p} is non-@code{nil} then the new style is applied to the
+current buffer as well.
@comment TBD: The next paragraph is bogus. I really need to better
@comment document adding styles, including setting up inherited styles.
The sample @file{.emacs} file provides a concrete example of how a new
style can be added and automatically set. @xref{Sample .emacs File}.
+@end defun
+
+@defvar c-style-alist
+@vindex style-alist (c-)
+This is the variable that holds the definitions for the styles. It
+should not be changed directly; use @code{c-add-style} instead.
+@end defvar
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node File Styles, , Adding Styles, Styles
@comment node-name, next, previous, up
@subsection File Styles
-@cindex file styles
+@cindex styles, file local
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@cindex local variables
+@cindex file local variables
-The Emacs manual describes how you can customize certain variables on a
-per-file basis by including a @dfn{Local Variable} block at the end of
-the file. So far, you've only seen a functional interface to @ccmode{}
-customization, which is highly inconvenient for use in a Local Variable
-block. @ccmode{} provides two variables that make it easier for you to
-customize your style on a per-file basis.
+The Emacs manual describes how you can customize certain variables on
+a per-file basis by including a @dfn{file local variable} block at the
+end of the file. So far, you've only seen a functional interface to
+@ccmode{} customization, which can't be used there. @ccmode{}
+provides two variables allow customization of the indentation style on
+a per-file basis:
-@vindex c-file-style
+@defvar c-file-style
@vindex file-style (c-)
-@vindex c-file-offsets
-@vindex file-offsets (c-)
-
-The variable @code{c-file-style} can be set to a style name string.
-When the file is visited, @ccmode{} will automatically set the
-file's style to this style using @code{c-set-style}.
+This variable can be set to a style name string. When the file is
+visited, @ccmode{} will automatically set the file's style to this
+one using @code{c-set-style}.
+@end defvar
-Another variable, @code{c-file-offsets}, takes an association list
-similar to what is allowed in @code{c-offsets-alist}. When the file is
-visited, @ccmode{} will automatically institute these offsets using
-@code{c-set-offset}.
+@defvar c-file-offsets
+@vindex file-offsets (c-)
+This variable takes an association list similar to what is allowed in
+@code{c-offsets-alist}. When the file is visited, @ccmode{} will
+automatically institute these offsets using @code{c-set-offset}.
+@end defvar
Note that file style settings (i.e. @code{c-file-style}) are applied
before file offset settings (i.e. @code{c-file-offsets}). Also, if
@@ -2477,26 +2949,24 @@ style variable values are made local to that buffer.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Advanced Customizations, , Styles, Customizing Indentation
@comment node-name, next, previous, up
-@section Advanced Customizations
+@section Advanced Customizations
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-style-alist
-@vindex style-alist (c-)
-For most users, @ccmode{} will support their coding styles with
-very little need for more advanced customizations. Usually, one of the
-standard styles defined in @code{c-style-alist} will do the trick. At
-most, perhaps one of the syntactic symbol offsets will need to be
-tweaked slightly, or maybe @code{c-basic-offset} will need to be
-changed. However, some styles require a more flexible framework for
-customization, and one of the real strengths of @ccmode{} is that
-the syntactic analysis model provides just such a framework. This allows
+For most users, @ccmode{} will support their coding styles with very
+little need for more advanced customizations. Usually, one of the
+standard styles (@pxref{Built-in Styles}) will do the trick. At most,
+perhaps one of the syntactic symbol offsets will need to be tweaked
+slightly, or maybe @code{c-basic-offset} will need to be changed.
+However, some styles require a more flexible framework for
+customization, and one of the real strengths of @ccmode{} is that the
+syntactic analysis model provides just such a framework. This allows
you to implement custom indentation calculations for situations not
handled by the mode directly.
@menu
* Custom Indentation Functions::
* Custom Brace and Colon Hanging::
-* Customizing Semi-colons and Commas::
+* Customizing Semicolons and Commas::
* Other Special Indentations::
@end menu
@@ -2504,7 +2974,7 @@ handled by the mode directly.
@node Custom Indentation Functions, Custom Brace and Colon Hanging, , Advanced Customizations
@comment node-name, next, previous, up
@subsection Custom Indentation Functions
-@cindex custom indentation functions
+@cindex customization, indentation functions
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
The most flexible way to customize @ccmode{} is by writing custom
@@ -2512,17 +2982,16 @@ indentation functions, and associating them with specific syntactic
symbols (@pxref{Syntactic Symbols}). @ccmode{} itself uses indentation
functions to provide more sophisticated indentation, for example when
lining up C++ stream operator blocks:
+
@example
@group
-
-1: void main(int argc, char**)
-2: @{
-3: cout << "There were "
-4: << argc
-5: << "arguments passed to the program"
-6: << endl;
-7: @}
-
+ 1: void main(int argc, char**)
+ 2: @{
+ 3: cout << "There were "
+ 4: << argc
+ 5: << "arguments passed to the program"
+ 6: << endl;
+ 7: @}
@end group
@end example
@@ -2532,67 +3001,53 @@ with a @code{c-basic-offset} of 2, you can see that lines 4 through 6
are simply indented two spaces to the right of line 3. But perhaps we'd
like @ccmode{} to be a little more intelligent so that it aligns
all the @samp{<<} symbols in lines 3 through 6. To do this, we have
-to write a custom indentation function which finds the column of first
-stream operator on the first line of the statement. Here is sample
+to write a custom indentation function which finds the column of the first
+stream operator on the first line of the statement. Here is sample
lisp code implementing this:
-@example
-@group
+@example
(defun c-lineup-streamop (langelem)
- ;; lineup stream operators
(save-excursion
- (let* ((relpos (cdr langelem))
- (curcol (progn (goto-char relpos)
- (current-column))))
- (re-search-forward "<<\\|>>" (c-point 'eol) 'move)
- (goto-char (match-beginning 0))
- (- (current-column) curcol))))
-
-@end group
+ (goto-char (cdr langelem))
+ (re-search-forward "<<\\|>>" (c-point 'eol) 'move)
+ (goto-char (match-beginning 0))
+ (vector (current-column))))
@end example
-@noindent
+
Indentation functions take a single argument, which is a syntactic
-component cons cell (@pxref{Syntactic Analysis}). The function returns
-an integer offset value that will be added to the running total
-indentation for the line. Note that what actually gets returned is the
-difference between the column that the first stream operator is on, and
-the column of the buffer relative position passed in the function's
-argument. Remember that @ccmode{} automatically adds in the column of
-the component's relative buffer position and we don't the column offset
-added in twice.
+component cons cell (@pxref{Syntactic Analysis}). The function can
+return an integer which is added to the running total indentation for
+the line, or a vector containing an integer which is an absolute
+column to align to. Usually an absolute column is wanted when
+aligning to existing text, as in this example.
The function should return @code{nil} if it's used in a situation where
-it doesn't want to do any decision. If the function is used in a list
+it doesn't want to make any decision. If the function is used in a list
expression (@pxref{Customizing Indentation}), that will cause @ccmode{}
to go on and check the next entry in the list.
-@cindex stream-op syntactic symbol
-@findex c-lineup-streamop
-@findex lineup-streamop (c-)
Now, to associate the function @code{c-lineup-streamop} with the
@code{stream-op} syntactic symbol, we can add something like the
following to our @code{c++-mode-hook}@footnote{It probably makes more
sense to add this to @code{c++-mode-hook} than @code{c-mode-common-hook}
since stream operators are only relevant for C++.}:
-@example
+@example
(c-set-offset 'stream-op 'c-lineup-streamop)
-
@end example
-Now the function looks like this after re-indenting (using @kbd{C-c
+Now the function looks like this after reindenting (using @kbd{C-c
C-q}):
+
@example
@group
-
-1: void main(int argc, char**)
-2: @{
-3: cout << "There were "
-4: << argc
-5: << " arguments passed to the program"
-6: << endl;
-7: @}
-
+ 1: void main(int argc, char**)
+ 2: @{
+ 3: cout << "There were "
+ 4: << argc
+ 5: << " arguments passed to the program"
+ 6: << endl;
+ 7: @}
@end group
@end example
@@ -2609,7 +3064,7 @@ contribute it; please contact @email{bug-cc-mode@@gnu.org}.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Custom Brace and Colon Hanging, Customizing Semi-colons and Commas, Custom Indentation Functions, Advanced Customizations
+@node Custom Brace and Colon Hanging, Customizing Semicolons and Commas, Custom Indentation Functions, Advanced Customizations
@comment node-name, next, previous, up
@subsection Custom Brace and Colon Hanging
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -2620,16 +3075,16 @@ Syntactic symbols aren't the only place where you can customize
@ccmode{} with the lisp equivalent of callback functions. Brace
``hanginess'' can also be determined by custom functions associated with
syntactic symbols on the @code{c-hanging-braces-alist} style variable.
-Remember that @var{ACTION}'s are typically a list containing some
+Remember that @var{action}'s are typically a list containing some
combination of the symbols @code{before} and @code{after}
-(@pxref{Hanging Braces}). However, an @var{ACTION} can also be a
+(@pxref{Hanging Braces}). However, an @var{action} can also be a
function which gets called when a brace matching that syntactic symbol
is entered.
-@cindex customizing brace hanging
-These @var{ACTION} functions are called with two arguments: the
+@cindex customization, brace hanging
+These @var{action} functions are called with two arguments: the
syntactic symbol for the brace, and the buffer position at which the
-brace was inserted. The @var{ACTION} function is expected to return a
+brace was inserted. The @var{action} function is expected to return a
list containing some combination of @code{before} and @code{after},
including neither of them (i.e. @code{nil}). This return value has the
normal brace hanging semantics.
@@ -2637,9 +3092,8 @@ normal brace hanging semantics.
As an example, @ccmode{} itself uses this feature to dynamically
determine the hanginess of braces which close ``do-while''
constructs:
-@example
-@group
+@example
void do_list( int count, char** atleast_one_string )
@{
int i=0;
@@ -2648,28 +3102,19 @@ void do_list( int count, char** atleast_one_string )
i++;
@} while( i < count );
@}
-
-@end group
@end example
-@findex c-snug-do-while
-@findex snug-do-while (c-)
@ccmode{} assigns the @code{block-close} syntactic symbol to the
brace that closes the @code{do} construct, and normally we'd like the
line that follows a @code{block-close} brace to begin on a separate
line. However, with ``do-while'' constructs, we want the
@code{while} clause to follow the closing brace. To do this, we
-associate the @code{block-close} symbol with the @var{ACTION} function
+associate the @code{block-close} symbol with the @var{action} function
@code{c-snug-do-while}:
-@example
+@example
(defun c-snug-do-while (syntax pos)
- "Dynamically calculate brace hanginess for do-while statements.
-Using this function, `while' clauses that end a `do-while' block will
-remain on the same line as the brace that closes that block.
-
-See `c-hanging-braces-alist' for how to utilize this function as an
-ACTION associated with `block-close' syntax."
+ "Dynamically calculate brace hanginess for do-while statements."
(save-excursion
(let (langelem)
(if (and (eq syntax 'block-close)
@@ -2680,77 +3125,75 @@ ACTION associated with `block-close' syntax."
(looking-at "\\<do\\>[^_]")))
'(before)
'(before after)))))
-
@end example
+@findex c-snug-do-while
+@findex snug-do-while (c-)
This function simply looks to see if the brace closes a ``do-while''
clause and if so, returns the list @samp{(before)} indicating
that a newline should be inserted before the brace, but not after it.
In all other cases, it returns the list @samp{(before after)} so
that the brace appears on a line by itself.
-@vindex c-syntactic-context
+@defvar c-syntactic-context
@vindex syntactic-context (c-)
-During the call to the brace hanging @var{ACTION} function, the variable
-@code{c-syntactic-context} is bound to the full syntactic analysis list.
+During the call to the indentation or brace hanging @var{action}
+function, this variable is bound to the full syntactic analysis list.
+@end defvar
-@cindex customizing colon hanging
-@vindex c-hanging-colon-alist
-@vindex hanging-colon-alist (c-)
+@cindex customization, colon hanging
+@vindex c-hanging-colons-alist
+@vindex hanging-colons-alist (c-)
Note that for symmetry, colon hanginess should be customizable by
-allowing function symbols as @var{ACTION}s on the
-@code{c-hanging-colon-alist} style variable. Since no use has actually
+allowing function symbols as @var{action}s on the
+@code{c-hanging-colons-alist} style variable. Since no use has actually
been found for this feature, it isn't currently implemented!
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Customizing Semi-colons and Commas, Other Special Indentations, Custom Brace and Colon Hanging, Advanced Customizations
+@node Customizing Semicolons and Commas, Other Special Indentations, Custom Brace and Colon Hanging, Advanced Customizations
@comment node-name, next, previous, up
-@subsection Customizing Semi-colons and Commas
-@cindex customizing semi-colons and commas
+@subsection Customizing Semicolons and Commas
+@cindex customization, semicolon newlines
+@cindex customization, comma newlines
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-hanging-semi&comma-criteria
-@vindex hanging-semi&comma-criteria (c-)
-You can also customize the insertion of newlines after semi-colons and
-commas, when the auto-newline minor mode is enabled (@pxref{Minor
-Modes}). This is controlled by the style variable
-@code{c-hanging-semi&comma-criteria}, which contains a list of functions
-that are called in the order they appear. Each function is called with
-zero arguments, and is expected to return one of the following values:
-
-@itemize @bullet
-@item
-non-@code{nil} --- A newline is inserted, and no more functions from the
-list are called.
+You can also customize the insertion of newlines after semicolons and
+commas when the auto-newline minor mode is enabled (@pxref{Minor
+Modes}).
-@item
-@code{stop} --- No more functions from the list are called, but no
-newline is inserted.
-
-@item
-@code{nil} --- No determination is made, and the next function in the
-list is called.
+@defopt c-hanging-semi&comma-criteria
+@vindex hanging-semi&comma-criteria (c-)
+This style variable takes a list of hooks that get called when a
+semicolon or comma is inserted. The hooks are called in order without
+arguments, and are expected to return one of the following values:
-@end itemize
+@table @code
+@item t
+A newline is inserted, and no more functions from the list are called.
+@item stop
+No more functions from the list are called, but no newline is
+inserted.
+@item nil
+No determination is made, and the next function in the list is called.
+@end table
If every function in the list is called without a determination being
made, then no newline is added. The default value for this variable is a
list containing a single function which inserts newlines only after
-semi-colons which do not appear inside parenthesis lists (i.e. those
+semicolons which do not appear inside parenthesis lists (i.e. those
that separate @code{for}-clause statements).
+@end defopt
-@findex c-semi&comma-no-newlines-before-nonblanks
+@defun c-semi&comma-no-newlines-before-nonblanks
@findex semi&comma-no-newlines-before-nonblanks (c-)
-Here's an example of a criteria function, provided by @ccmode{}, that
-will prevent newlines from being inserted after semicolons when there is
-a non-blank following line. Otherwise, it makes no determination. To
-use, add this to the front of the @code{c-hanging-semi&comma-criteria}
-list.
+This is an example of a criteria function, provided by @ccmode{}. It
+prevents newlines from being inserted after semicolons when there is a
+non-blank following line. Otherwise, it makes no determination. To
+use, add this function to the front of the
+@code{c-hanging-semi&comma-criteria} list.
@example
-@group
-
(defun c-semi&comma-no-newlines-before-nonblanks ()
(save-excursion
(if (and (eq last-command-char ?\;)
@@ -2758,13 +3201,12 @@ list.
(not (looking-at "^[ \t]*$")))
'stop
nil)))
-
-@end group
@end example
+@end defun
-@findex c-semi&comma-inside-parenlist
-@findex c-semi&comma-no-newlines-for-oneline-inliners
+@defun c-semi&comma-inside-parenlist
@findex semi&comma-inside-parenlist (c-)
+@defunx c-semi&comma-no-newlines-for-oneline-inliners
@findex semi&comma-no-newlines-for-oneline-inliners (c-)
The function @code{c-semi&comma-inside-parenlist} is what prevents
newlines from being inserted inside the parenthesis list of @code{for}
@@ -2773,72 +3215,53 @@ statements. In addition to
@ccmode{} also comes with the criteria function
@code{c-semi&comma-no-newlines-for-oneline-inliners}, which suppresses
newlines after semicolons inside one-line inline method definitions
-(i.e. in C++ or Java).
+(e.g. in C++ or Java).
+@end defun
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Other Special Indentations, , Customizing Semi-colons and Commas, Advanced Customizations
+@node Other Special Indentations, , Customizing Semicolons and Commas, Advanced Customizations
@comment node-name, next, previous, up
@subsection Other Special Indentations
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@vindex c-label-minimum-indentation
+Here are the remaining odds and ends regarding indentation:
+
+@defopt c-label-minimum-indentation
@vindex label-minimum-indentation (c-)
In @samp{gnu} style (@pxref{Built-in Styles}), a minimum indentation
is imposed on lines inside top-level constructs. This minimum
-indentation is controlled by the style variable
-@code{c-label-minimum-indentation}. The default value for this variable
+indentation is controlled by this style variable. The default value
is 1.
+@end defopt
-@vindex c-special-indent-hook
+@defopt c-special-indent-hook
@vindex special-indent-hook (c-)
-One other customization variable is available in @ccmode{}: The style
-variable @code{c-special-indent-hook}. This is a standard hook variable
-that is called after every line is indented by @ccmode{}. You can use
-it to do any special indentation or line adjustments your style
-dictates, such as adding extra indentation to constructors or destructor
-declarations in a class definition, etc. Note however, that you should
-not change point or mark inside your @code{c-special-indent-hook}
-functions (i.e. you'll probably want to wrap your function in a
-@code{save-excursion}).
-
-Setting @code{c-special-indent-hook} in your style definition is handled
-slightly differently than other variables. In your style definition,
-you should set the value for
-@code{c-special-indent-hook} to a function or list of functions, which
-will be appended to @code{c-special-indent-hook} using @code{add-hook}.
-That way, the current setting for the buffer local value of
+This style variable is a standard hook variable that is called after
+every line is indented by @ccmode{}. You can use it to do any special
+indentation or line adjustments your style dictates, such as adding
+extra indentation to constructors or destructor declarations in a
+class definition, etc. Note that you should not change point or mark
+inside your @code{c-special-indent-hook} functions, i.e. you'll
+probably want to wrap your function in a @code{save-excursion}.
+
+Setting @code{c-special-indent-hook} in your style definition is
+handled slightly differently than other variables. In your style
+definition, you should set the value for @code{c-special-indent-hook}
+to a function or list of functions, which will be appended to
+@code{c-special-indent-hook} using @code{add-hook}. That way, the
+current setting for the buffer local value of
@code{c-special-indent-hook} won't be overridden.
-
-@kindex M-;
-@findex indent-for-comment
-@vindex c-indent-comments-syntactically-p
-@vindex indent-comments-syntactically-p (c-)
-@vindex comment-column
-Normally, the standard Emacs command @kbd{M-;}
-(@code{indent-for-comment}) will indent comment only lines to
-@code{comment-column}. Some users however, prefer that @kbd{M-;} act
-just like @kbd{TAB} for purposes of indenting comment-only lines;
-i.e. they want the comments to always indent as they would for normal
-code, regardless of whether @kbd{TAB} or @kbd{M-;} were used. This
-behavior is controlled by the variable
-@code{c-indent-comments-syntactically-p}. When @code{nil} (the
-default), @kbd{M-;} indents comment-only lines to @code{comment-column},
-otherwise, they are indented just as they would be if @kbd{TAB} were
-typed.
-
-Note that this has no effect for comment lines that are inserted with
-@kbd{M-;} at the end of regular code lines. These comments will always
-start at @code{comment-column}.
+@end defopt
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Syntactic Symbols, Indentation Functions, Customizing Indentation, Top
@comment node-name, next, previous, up
-@chapter Syntactic Symbols
-@cindex syntactic symbols
+@chapter Syntactic Symbols
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@cindex syntactic symbols, brief list
@vindex c-offsets-alist
@vindex offsets-alist (c-)
Here is a complete list of the recognized syntactic symbols as described
@@ -2847,9 +3270,9 @@ description. More detailed descriptions follow.
@table @code
@item string
-Inside a multi-line string.
+Inside a multiline string.
@item c
-Inside a multi-line C style block comment.
+Inside a multiline C style block comment.
@item defun-open
Brace that opens a top-level function definition.
@item defun-close
@@ -2877,7 +3300,9 @@ Subsequent lines in a K&R C argument declaration.
@item topmost-intro
The first line in a ``topmost'' definition.
@item topmost-intro-cont
-Topmost definition continuation lines.
+Topmost definition continuation lines. This is only used in the parts
+that aren't covered by other symbols such as @code{func-decl-cont} and
+@code{knr-argdecl}.
@item member-init-intro
First line in a member initialization list.
@item member-init-cont
@@ -2915,12 +3340,14 @@ The first line in a case block that starts with a brace.
The first line after a conditional or loop construct.
@item substatement-open
The brace that opens a substatement block.
+@item substatement-label
+The first line after a conditional or loop construct if it's a label.
@item case-label
-A @code{case} or @code{default} label.
+A label in a @code{switch} block.
@item access-label
C++ access control label.
@item label
-Any non-special C label.
+Any other label.
@item do-while-closure
The @code{while} line that ends a @code{do}-@code{while} construct.
@item else-clause
@@ -2945,31 +3372,41 @@ Lines continuing a stream operator (C++ only).
@item inclass
The line is nested inside a class definition.
@item cpp-macro
-The start of a C preprocessor macro definition.
+The start of a preprocessor macro definition.
+@item cpp-define-intro
+The first line inside a multiline preproprocessor macro if
+@code{c-syntactic-indentation-in-macros} is set.
@item cpp-macro-cont
-Subsequent lines of a multi-line C preprocessor macro definition.
+All lines inside multiline preprocessor macros if
+@code{c-syntactic-indentation-in-macros} is @code{nil}.
@item friend
A C++ friend declaration.
@item objc-method-intro
-The first line of an Objective-C method. definition.
+The first line of an Objective-C method definition.
@item objc-method-args-cont
-Lines continuing an Objective-C method. definition
+Lines continuing an Objective-C method definition.
@item objc-method-call-cont
Lines continuing an Objective-C method call.
@item extern-lang-open
-Brace that opens an external language block.
+Brace that opens an @code{extern} block (e.g. @code{extern "C" @{...@}}).
@item extern-lang-close
-Brace that closes an external language block.
+Brace that closes an @code{extern} block.
@item inextern-lang
-Analogous to @code{inclass} syntactic symbol, but used inside external
-language blocks (e.g. @code{extern "C" @{}).
+Analogous to @code{inclass} syntactic symbol, but used inside
+@code{extern} blocks.
@item namespace-open
-Brace that opens a C++ namespace block.
-@item namespace-close
-Brace that closes a C++ namespace block.
-@item innamespace
-Analogous to @code{inextern-lang} syntactic symbol, but used inside C++
-namespace blocks.
+@itemx namespace-close
+@itemx innamespace
+These are analogous to the three @code{extern-lang} symbols above, but
+are returned for C++ namespace blocks.
+@item module-open
+@itemx module-close
+@itemx inmodule
+Analogous to the above, but for CORBA IDL @code{module} blocks.
+@item composition-open
+@itemx composition-close
+@itemx incomposition
+Analogous to the above, but for CORBA CIDL @code{composition} blocks.
@item template-args-cont
C++ template argument list continuations.
@item inlambda
@@ -2988,15 +3425,15 @@ classes in Java. It's also used for anonymous array initializers in
Java.
@end table
-@cindex -open syntactic symbols
-@cindex -close syntactic symbols
+@ssindex -open symbols
+@ssindex -close symbols
Most syntactic symbol names follow a general naming convention. When a
line begins with an open or close brace, the syntactic symbol will
contain the suffix @code{-open} or @code{-close} respectively.
-@cindex -intro syntactic symbols
-@cindex -cont syntactic symbols
-@cindex -block-intro syntactic symbols
+@ssindex -intro symbols
+@ssindex -cont symbols
+@ssindex -block-intro symbols
Usually, a distinction is made between the first line that introduces a
construct and lines that continue a construct, and the syntactic symbols
that represent these lines will contain the suffix @code{-intro} or
@@ -3006,27 +3443,24 @@ contain the suffix @code{-block-intro}.
Let's look at some examples to understand how this works. Remember that
you can check the syntax of any line by using @kbd{C-c C-s}.
-@example
-@group
-
- 1: void
- 2: swap( int& a, int& b )
- 3: @{
- 4: int tmp = a;
- 5: a = b;
- 6: b = tmp;
- 7: int ignored =
- 8: a + b;
- 9: @}
-@end group
+@example
+ 1: void
+ 2: swap( int& a, int& b )
+ 3: @{
+ 4: int tmp = a;
+ 5: a = b;
+ 6: b = tmp;
+ 7: int ignored =
+ 8: a + b;
+ 9: @}
@end example
-@cindex topmost-intro syntactic symbol
-@cindex topmost-intro-cont syntactic symbol
-@cindex defun-open syntactic symbol
-@cindex defun-close syntactic symbol
-@cindex defun-block-intro syntactic symbol
+@ssindex topmost-intro
+@ssindex topmost-intro-cont
+@ssindex defun-open
+@ssindex defun-close
+@ssindex defun-block-intro
Line 1 shows a @code{topmost-intro} since it is the first line that
introduces a top-level construct. Line 2 is a continuation of the
top-level construct introduction so it has the syntax
@@ -3038,8 +3472,8 @@ function definition. Line 4 is a @code{defun-block-intro}, i.e. it is
the first line of a brace-block, enclosed in a
top-level function definition.
-@cindex statement syntactic symbol
-@cindex statement-cont syntactic symbol
+@ssindex statement
+@ssindex statement-cont
Lines 5, 6, and 7 are all given @code{statement} syntax since there
isn't much special about them. Note however that line 8 is given
@code{statement-cont} syntax since it continues the statement begun
@@ -3047,33 +3481,30 @@ on the previous line.
Here's another example, which illustrates some C++ class syntactic
symbols:
-@example
-@group
-
- 1: class Bass
- 2: : public Guitar,
- 3: public Amplifiable
- 4: @{
- 5: public:
- 6: Bass()
- 7: : eString( new BassString( 0.105 )),
- 8: aString( new BassString( 0.085 )),
- 9: dString( new BassString( 0.065 )),
- 10: gString( new BassString( 0.045 ))
- 11: @{
- 12: eString.tune( 'E' );
- 13: aString.tune( 'A' );
- 14: dString.tune( 'D' );
- 15: gString.tune( 'G' );
- 16: @}
- 17: friend class Luthier;
- 18: @}
-@end group
+@example
+ 1: class Bass
+ 2: : public Guitar,
+ 3: public Amplifiable
+ 4: @{
+ 5: public:
+ 6: Bass()
+ 7: : eString( new BassString( 0.105 )),
+ 8: aString( new BassString( 0.085 )),
+ 9: dString( new BassString( 0.065 )),
+10: gString( new BassString( 0.045 ))
+11: @{
+12: eString.tune( 'E' );
+13: aString.tune( 'A' );
+14: dString.tune( 'D' );
+15: gString.tune( 'G' );
+16: @}
+17: friend class Luthier;
+18: @};
@end example
-@cindex class-open syntactic symbol
-@cindex class-close syntactic symbol
+@ssindex class-open
+@ssindex class-close
As in the previous example, line 1 has the @code{topmost-intro} syntax.
Here however, the brace that opens a C++ class definition on line 4 is
assigned the @code{class-open} syntax. Note that in C++, classes,
@@ -3086,22 +3517,18 @@ languages are syntactically equivalent to classes. Note however that
the keyword @code{class} is meaningless in C and Objective-C.}.
Similarly, line 18 is assigned @code{class-close} syntax.
-@cindex inher-intro syntactic symbol
-@cindex inher-cont syntactic symbol
+@ssindex inher-intro
+@ssindex inher-cont
Line 2 introduces the inheritance list for the class so it is assigned
the @code{inher-intro} syntax, and line 3, which continues the
inheritance list is given @code{inher-cont} syntax.
-@cindex access-label syntactic symbol
-@cindex inclass syntactic symbol
+@ssindex access-label
+@ssindex inclass
Hitting @kbd{C-c C-s} on line 5 shows the following analysis:
@example
-@group
-
-@code{((inclass . 58) (access-label . 67))}
-
-@end group
+((inclass 58) (access-label 58))
@end example
@noindent
@@ -3114,15 +3541,11 @@ Similarly, line 6 is given both @code{inclass} and @code{topmost-intro}
syntax:
@example
-@group
-
-@code{((inclass . 58) (topmost-intro . 60))}
-
-@end group
+((inclass 58) (topmost-intro 60))
@end example
-@cindex member-init-intro syntactic symbol
-@cindex member-init-cont syntactic symbol
+@ssindex member-init-intro
+@ssindex member-init-cont
Line 7 introduces a C++ member initialization list and as such is given
@code{member-init-intro} syntax. Note that in this case it is
@emph{not} assigned @code{inclass} since this is not considered a
@@ -3131,16 +3554,12 @@ top-level construct. Lines 8 through 10 are all assigned
list started on line 7.
@cindex in-class inline methods
-@cindex inline-open syntactic symbol
-@cindex inline-close syntactic symbol
+@ssindex inline-open
+@ssindex inline-close
Line 11's analysis is a bit more complicated:
@example
-@group
-
-@code{((inclass . 58) (inline-open))}
-
-@end group
+((inclass 58) (inline-open))
@end example
This line is assigned a syntax of both @code{inline-open} and
@@ -3148,38 +3567,35 @@ This line is assigned a syntax of both @code{inline-open} and
definition. This is distinct from, but related to, the C++ notion of an
inline function in that its definition occurs inside an enclosing class
definition, which in C++ implies that the function should be inlined.
-If though, the definition of the @code{Bass} constructor appeared
+However, if the definition of the @code{Bass} constructor appeared
outside the class definition, the construct would be given the
@code{defun-open} syntax, even if the keyword @code{inline} appeared
before the method name, as in:
-@example
-@group
-
-class Bass
- : public Guitar,
- public Amplifiable
-@{
-public:
- Bass();
-@}
-
-inline
-Bass::Bass()
- : eString( new BassString( 0.105 )),
- aString( new BassString( 0.085 )),
- dString( new BassString( 0.065 )),
- gString( new BassString( 0.045 ))
-@{
- eString.tune( 'E' );
- aString.tune( 'A' );
- dString.tune( 'D' );
- gString.tune( 'G' );
-@}
-@end group
+@example
+ 1: class Bass
+ 2: : public Guitar,
+ 3: public Amplifiable
+ 4: @{
+ 5: public:
+ 6: Bass();
+ 7: @};
+ 8:
+ 9: inline
+10: Bass::Bass()
+11: : eString( new BassString( 0.105 )),
+12: aString( new BassString( 0.085 )),
+13: dString( new BassString( 0.065 )),
+14: gString( new BassString( 0.045 ))
+15: @{
+16: eString.tune( 'E' );
+17: aString.tune( 'A' );
+18: dString.tune( 'D' );
+19: gString.tune( 'G' );
+20: @}
@end example
-@cindex friend syntactic symbol
+@ssindex friend
Returning to the previous example, line 16 is given @code{inline-close}
syntax, while line 12 is given @code{defun-block-open} syntax, and lines
13 through 15 are all given @code{statement} syntax. Line 17 is
@@ -3187,9 +3603,7 @@ interesting in that its syntactic analysis list contains three
elements:
@example
-
-@code{((friend) (inclass . 58) (topmost-intro . 380))}
-
+((inclass 58) (topmost-intro 380) (friend))
@end example
The @code{friend} syntactic symbol is a modifier that typically does not
@@ -3198,13 +3612,9 @@ have a relative buffer position.
Template definitions introduce yet another syntactic symbol:
@example
-@group
-
- 1: ThingManager <int,
- 2: Framework::Callback *,
- 3: Mutex> framework_callbacks;
-
-@end group
+ 1: ThingManager <int,
+ 2: Framework::Callback *,
+ 3: Mutex> framework_callbacks;
@end example
Here, line 1 is analyzed as a @code{topmost-intro}, but lines 2 and 3
@@ -3212,98 +3622,89 @@ are both analyzed as @code{template-args-cont} lines.
Here is another (totally contrived) example which illustrates how syntax
is assigned to various conditional constructs:
-@example
-@group
-
- 1: void spam( int index )
- 2: @{
- 3: for( int i=0; i<index; i++ )
- 4: @{
- 5: if( i == 10 )
- 6: @{
- 7: do_something_special();
- 8: @}
- 9: else
- 10: do_something( i );
- 11: @}
- 12: do @{
- 13: another_thing( i-- );
- 14: @}
- 15: while( i > 0 );
- 16: @}
-
-@end group
+@example
+ 1: void spam( int index )
+ 2: @{
+ 3: for( int i=0; i<index; i++ )
+ 4: @{
+ 5: if( i == 10 )
+ 6: do_something_special();
+ 7: else
+ 8: silly_label:
+ 9: do_something( i );
+10: @}
+11: do @{
+12: another_thing( i-- );
+13: @}
+14: while( i > 0 );
+15: @}
@end example
-@noindent
Only the lines that illustrate new syntactic symbols will be discussed.
-@cindex substatement-open syntactic symbol
-@cindex substatement-block-intro syntactic symbol
-@cindex block-close syntactic symbol
+@ssindex substatement-open
+@ssindex substatement-block-intro
+@ssindex block-close
Line 4 has a brace which opens a conditional's substatement block. It
is thus assigned @code{substatement-open} syntax, and since line 5 is
the first line in the substatement block, it is assigned
-@code{substatement-block-intro} syntax. Lines 6 and 7 are assigned
-similar syntax. Line 8 contains the brace that closes the inner
-substatement block. It is given the syntax @code{block-close},
-as are lines 11 and 14.
-
-@cindex else-clause syntactic symbol
-@cindex catch-clause syntactic symbol
-Line 9 is a little different --- since it contains the keyword
-@code{else} matching the @code{if} statement introduced on line 5, it is
-given the @code{else-clause} syntax. The @code{try}-@code{catch}
-constructs in C++ and Java are treated this way too, with the only
-difference that the @code{catch}, and in Java also @code{finally}, is
-marked with @code{catch-clause}.
-
-@cindex substatement syntactic symbol
-Line 10 is also slightly different. Because @code{else} is considered a
-conditional introducing keyword @footnote{The list of conditional
-keywords are (in C, C++, Objective-C, Java, and Pike): @code{for},
-@code{if}, @code{do}, @code{else}, @code{while}, and @code{switch}. C++
-and Java have two additional conditional keywords: @code{try} and
-@code{catch}. Java also has the @code{finally} and @code{synchronized}
-keywords.}, and because the following substatement is not a brace block,
-line 10 is assigned the @code{substatement} syntax.
-
-@cindex do-while-closure syntactic symbol
-One other difference is seen on line 15. The @code{while} construct
-that closes a @code{do} conditional is given the special syntax
-@code{do-while-closure} if it appears on a line by itself. Note that if
-the @code{while} appeared on the same line as the preceding close brace,
-that line would have been assigned @code{block-close} syntax instead.
+@code{substatement-block-intro} syntax. Line 10 contains the brace that
+closes the inner substatement block, and is therefore given the syntax
+@code{block-close}. Line 13 is treated the same way.
+
+@ssindex substatement
+Lines 6 and 9 are also substatements of conditionals, but since they
+don't start blocks they are given @code{substatement} syntax
+instead of @code{substatement-open}.
+
+@ssindex substatement-label
+Line 8 contains a label, which is normally given @code{label} syntax.
+This one is however a bit special since it's between a conditional and
+its substatement. It's analyzed as @code{substatement-label} to let you
+handle this rather odd case differently from normal labels.
+
+@ssindex else-clause
+@ssindex catch-clause
+Line 7 start with an @code{else} that matches the @code{if} statement on
+line 5. It is therefore given the @code{else-clause} syntax and is
+anchored on the matching @code{if}. The @code{try}-@code{catch}
+constructs in C++ and Java are treated this way too, except that
+@code{catch} and (in Java) @code{finally}, are marked with
+@code{catch-clause}.
+
+@ssindex do-while-closure
+The @code{while} construct on line 14 that closes a @code{do}
+conditional is given the special syntax @code{do-while-closure} if it
+appears on a line by itself. Note that if the @code{while} appeared on
+the same line as the preceding close brace, that line would still have
+@code{block-close} syntax.
Switch statements have their own set of syntactic symbols. Here's an
example:
-@example
-@group
-
- 1: void spam( enum Ingredient i )
- 2: @{
- 3: switch( i ) @{
- 4: case Ham:
- 5: be_a_pig();
- 6: break;
- 7: case Salt:
- 8: drink_some_water();
- 9: break;
- 10: default:
- 11: @{
- 12: what_is_it();
- 13: break;
- 14: @}
- 15: @}
- 14: @}
-@end group
+@example
+ 1: void spam( enum Ingredient i )
+ 2: @{
+ 3: switch( i ) @{
+ 4: case Ham:
+ 5: be_a_pig();
+ 6: break;
+ 7: case Salt:
+ 8: drink_some_water();
+ 9: break;
+10: default:
+11: @{
+12: what_is_it();
+13: break;
+14: @}
+15: @}
+14: @}
@end example
-@cindex case-label syntactic symbol
-@cindex statement-case-intro syntactic symbol
-@cindex statement-case-open syntactic symbol
+@ssindex case-label
+@ssindex statement-case-intro
+@ssindex statement-case-open
Here, lines 4, 7, and 10 are all assigned @code{case-label} syntax,
while lines 5 and 8 are assigned @code{statement-case-intro}. Line 11
is treated slightly differently since it contains a brace that opens a
@@ -3316,23 +3717,20 @@ constructs inside of brace lists. A brace list is defined as an
initialize an array of structs. The three special aggregate constructs
in Pike, @code{(@{ @})}, @code{([ ])} and @code{(< >)}, are treated as
brace lists too. An example:
-@example
-@group
-
- 1: static char* ingredients[] =
- 2: @{
- 3: "Ham",
- 4: "Salt",
- 5: NULL
- 6: @}
-@end group
+@example
+ 1: static char* ingredients[] =
+ 2: @{
+ 3: "Ham",
+ 4: "Salt",
+ 5: NULL
+ 6: @};
@end example
-@cindex brace-list-open syntactic symbol
-@cindex brace-list-intro syntactic symbol
-@cindex brace-list-close syntactic symbol
-@cindex brace-list-entry syntactic symbol
+@ssindex brace-list-open
+@ssindex brace-list-intro
+@ssindex brace-list-close
+@ssindex brace-list-entry
Following convention, line 2 in this example is assigned
@code{brace-list-open} syntax, and line 3 is assigned
@code{brace-list-intro} syntax. Likewise, line 6 is assigned
@@ -3340,25 +3738,22 @@ Following convention, line 2 in this example is assigned
@code{brace-list-entry} syntax, as would all subsequent lines in this
initializer list.
-@cindex brace-entry-open syntactic symbol
+@ssindex brace-entry-open
Your static initializer might be initializing nested structures, for
example:
-@example
-@group
-
- 1: struct intpairs[] =
- 2: @{
- 3: @{ 1, 2 @},
- 4: @{
- 5: 3,
- 6: 4
- 7: @}
- 8: @{ 1,
- 9: 2 @},
- 10: @{ 3, 4 @}
- 11: @}
-@end group
+@example
+ 1: struct intpairs[] =
+ 2: @{
+ 3: @{ 1, 2 @},
+ 4: @{
+ 5: 3,
+ 6: 4
+ 7: @}
+ 8: @{ 1,
+ 9: 2 @},
+10: @{ 3, 4 @}
+11: @};
@end example
Here, you've already seen the analysis of lines 1, 2, 3, and 11. On
@@ -3371,87 +3766,96 @@ line 10.
External language definition blocks also have their own syntactic
symbols. In this example:
-@example
-@group
-
- 1: extern "C"
- 2: @{
- 3: int thing_one( int );
- 4: int thing_two( double );
- 5: @}
-@end group
+@example
+ 1: extern "C"
+ 2: @{
+ 3: int thing_one( int );
+ 4: int thing_two( double );
+ 5: @}
@end example
-@cindex extern-lang-open syntactic symbol
-@cindex extern-lang-close syntactic symbol
-@cindex inextern-lang syntactic symbol
-@cindex inclass syntactic symbol
+@ssindex extern-lang-open
+@ssindex extern-lang-close
+@ssindex inextern-lang
+@ssindex inclass
@noindent
line 2 is given the @code{extern-lang-open} syntax, while line 5 is given
the @code{extern-lang-close} syntax. The analysis for line 3 yields:
-@code{((inextern-lang) (topmost-intro . 14))}, where
-@code{inextern-lang} is a modifier similar in purpose to @code{inclass}.
-Similarly, C++ namespace constructs have their own associated syntactic
-symbols. In this example:
@example
-@group
-
- 1: namespace foo
- 2: @{
- 3: void xxx() @{@}
- 4: @}
-
-@end group
+((inextern-lang) (topmost-intro 14))
@end example
-@cindex namespace-open syntactic symbol
-@cindex namespace-close syntactic symbol
-@cindex innamespace syntactic symbol
@noindent
-line 2 is given the @code{namespace-open} syntax, while line 4 is given
-the @code{namespace-close} syntax. The analysis for line 3 yields:
-@code{((innamespace) (topmost-intro . 17))}, where @code{innamespace} is
-a modifier similar in purpose to @code{inextern-lang} and @code{inclass}.
+where @code{inextern-lang} is a modifier similar in purpose to
+@code{inclass}.
+
+There are various other top level blocks like @code{extern}, and they
+are all treated in the same way except that the symbols are named after
+the keyword that introduces the block. E.g. C++ namespace blocks get
+the three symbols @code{namespace-open}, @code{namespace-close} and
+@code{innamespace}. The currently recognized top level blocks are:
+
+@table @asis
+@item @code{extern-lang-open}, @code{extern-lang-close}, @code{inextern-lang}
+@code{extern} blocks in C and C++.@footnote{These should logically be
+named @code{extern-open}, @code{extern-close} and @code{inextern}, but
+that isn't the case for historical reasons.}
+
+@item @code{namespace-open}, @code{namespace-close}, @code{innamespace}
+@ssindex namespace-open
+@ssindex namespace-close
+@ssindex innamespace
+@code{namespace} blocks in C++.
+
+@item @code{module-open}, @code{module-close}, @code{inmodule}
+@ssindex module-open
+@ssindex module-close
+@ssindex inmodule
+@code{module} blocks in CORBA IDL.
+
+@item @code{composition-open}, @code{composition-close}, @code{incomposition}
+@ssindex composition-open
+@ssindex composition-close
+@ssindex incomposition
+@code{composition} blocks in CORBA CIDL.
+@end table
A number of syntactic symbols are associated with parenthesis lists,
a.k.a argument lists, as found in function declarations and function
calls. This example illustrates these:
-@example
-@group
-
- 1: void a_function( int line1,
- 2: int line2 );
- 3:
- 4: void a_longer_function(
- 5: int line1,
- 6: int line2
- 7: );
- 8:
- 9: void call_them( int line1, int line2 )
- 10: @{
- 11: a_function(
- 12: line1,
- 13: line2
- 14: );
- 15:
- 16: a_longer_function( line1,
- 17: line2 );
- 18: @}
-@end group
+@example
+ 1: void a_function( int line1,
+ 2: int line2 );
+ 3:
+ 4: void a_longer_function(
+ 5: int line1,
+ 6: int line2
+ 7: );
+ 8:
+ 9: void call_them( int line1, int line2 )
+10: @{
+11: a_function(
+12: line1,
+13: line2
+14: );
+15:
+16: a_longer_function( line1,
+17: line2 );
+18: @}
@end example
-@cindex arglist-intro syntactic symbol
-@cindex arglist-close syntactic symbol
+@ssindex arglist-intro
+@ssindex arglist-close
Lines 5 and 12 are assigned @code{arglist-intro} syntax since they are
the first line following the open parenthesis, and lines 7 and 14 are
assigned @code{arglist-close} syntax since they contain the parenthesis
that closes the argument list.
-@cindex arglist-cont-nonempty syntactic symbol
-@cindex arglist-cont syntactic symbol
+@ssindex arglist-cont-nonempty
+@ssindex arglist-cont
Lines that continue argument lists can be assigned one of two syntactic
symbols. For example, Lines 2 and 17
are assigned @code{arglist-cont-nonempty} syntax. What this means
@@ -3467,47 +3871,43 @@ is assigned the @code{statement-cont} syntax instead.
A few miscellaneous syntactic symbols that haven't been previously
covered are illustrated by this C++ example:
-@example
-@group
-
- 1: void Bass::play( int volume )
- 2: const
- 3: @{
- 4: /* this line starts a multi-line
- 5: * comment. This line should get `c' syntax */
- 6:
- 7: char* a_multiline_string = "This line starts a multi-line \
- 8: string. This line should get `string' syntax.";
- 9:
- 10: note:
- 11: @{
- 12: #ifdef LOCK
- 13: Lock acquire();
- 14: #endif // LOCK
- 15: slap_pop();
- 16: cout << "I played "
- 17: << "a note\n";
- 18: @}
- 19: @}
-@end group
+@example
+ 1: void Bass::play( int volume )
+ 2: const
+ 3: @{
+ 4: /* this line starts a multiline
+ 5: * comment. This line should get `c' syntax */
+ 6:
+ 7: char* a_multiline_string = "This line starts a multiline \
+ 8: string. This line should get `string' syntax.";
+ 9:
+10: note:
+11: @{
+12: #ifdef LOCK
+13: Lock acquire();
+14: #endif // LOCK
+15: slap_pop();
+16: cout << "I played "
+17: << "a note\n";
+18: @}
+19: @}
@end example
The lines to note in this example include:
@itemize @bullet
-
-@cindex func-decl-cont syntactic symbol
@item
+@ssindex func-decl-cont
Line 2 is assigned the @code{func-decl-cont} syntax.
-@cindex comment-intro syntactic symbol
@item
+@ssindex comment-intro
Line 4 is assigned both @code{defun-block-intro} @emph{and}
@code{comment-intro} syntax.
-@cindex c syntactic symbol
@item
+@ssindex c
Line 5 is assigned @code{c} syntax.
@item
@@ -3519,21 +3919,20 @@ comment on lines 4 and 5 do not cause line 6 to be assigned
@dfn{syntactic whitespace}, which are ignored when analyzing
code.
-@cindex string syntactic symbol
@item
+@ssindex string
Line 8 is assigned @code{string} syntax.
-@cindex label syntactic symbol
@item
+@ssindex label
Line 10 is assigned @code{label} syntax.
-@cindex block-open syntactic symbol
@item
+@ssindex block-open
Line 11 is assigned @code{block-open} syntax.
-@cindex cpp-macro syntactic symbol
-@cindex cpp-macro-cont syntactic symbol
@item
+@ssindex cpp-macro
Lines 12 and 14 are assigned @code{cpp-macro} syntax in addition to the
normal syntactic symbols (@code{statement-block-intro} and
@code{statement}, respectively). Normally @code{cpp-macro} is
@@ -3542,77 +3941,80 @@ preprocessor directives stick to the first column, but that's easily
changed if you want preprocessor directives to be indented like the rest
of the code.
-@cindex stream-op syntactic symbol
@item
+@ssindex stream-op
Line 17 is assigned @code{stream-op} syntax.
-
@end itemize
-@cindex multi-line macros
+@cindex multiline macros
@cindex syntactic whitespace
-Multi-line C preprocessor macros are now (somewhat) supported. At least
-@ccmode{} now recognizes the fact that it is inside a multi-line macro,
-and it properly skips such macros as syntactic whitespace. In this
-example:
-@example
-@group
+@ssindex cpp-define-intro
+Multiline preprocessor macro definitions are normally handled just like
+other code, i.e. the lines inside them are indented according to the
+syntactic analysis of the preceding lines inside the macro. The first
+line inside a macro definition (i.e. the line after the starting line of
+the cpp directive itself) gets @code{cpp-define-intro}. In this example:
- 1: #define LIST_LOOP(cons, listp) \
- 2: for (cons = listp; !NILP (cons); cons = XCDR (cons)) \
- 3: if (!CONSP (cons)) \
- 4: signal_error ("Invalid list format", listp); \
- 5: else
-
-@end group
+@example
+ 1: #define LIST_LOOP(cons, listp) \
+ 2: for (cons = listp; !NILP (cons); cons = XCDR (cons)) \
+ 3: if (!CONSP (cons)) \
+ 4: signal_error ("Invalid list format", listp); \
+ 5: else
@end example
+
@noindent
-line 1 is given the syntactic symbol @code{cpp-macro}. This first line
-of a macro is always given this symbol. The second and subsequent lines
-(e.g. lines 2 through 5) are given the @code{cpp-macro-cont} syntactic
-symbol, with a relative buffer position pointing to the @code{#} which
-starts the macro definition.
+line 1 is given the syntactic symbol @code{cpp-macro}. The first line
+of a cpp directive is always given that symbol. Line 2 is given
+@code{cpp-define-intro}, so that you can give the macro body as a whole
+some extra indentation. Lines 3 through 5 are then analyzed as normal
+code, i.e. @code{substatement} on lines 3 and 4, and @code{else-clause}
+on line 5.
+
+The syntactic analysis inside macros can be turned off with
+@code{c-syntactic-indentation-in-macros}. In that case, lines 2 through
+5 would all be given @code{cpp-macro-cont} with a relative buffer
+position pointing to the @code{#} which starts the cpp
+directive@footnote{This is how @ccmode{} 5.28 and earlier analyzed
+macros.}.
+
+@xref{Macro Handling}, for more info about the treatment of macros.
In Objective-C buffers, there are three additional syntactic symbols
assigned to various message calling constructs. Here's an example
illustrating these:
-@example
-@group
-
- 1: - (void)setDelegate:anObject
- 2: withStuff:stuff
- 3: @{
- 4: [delegate masterWillRebind:self
- 5: toDelegate:anObject
- 6: withExtraStuff:stuff];
- 7: @}
-@end group
+@example
+ 1: - (void)setDelegate:anObject
+ 2: withStuff:stuff
+ 3: @{
+ 4: [delegate masterWillRebind:self
+ 5: toDelegate:anObject
+ 6: withExtraStuff:stuff];
+ 7: @}
@end example
-@cindex objc-method-intro syntactic symbol
-@cindex objc-method-args-cont syntactic symbol
-@cindex objc-method-call-cont syntactic symbol
+@ssindex objc-method-intro
+@ssindex objc-method-args-cont
+@ssindex objc-method-call-cont
Here, line 1 is assigned @code{objc-method-intro} syntax, and line 2 is
assigned @code{objc-method-args-cont} syntax. Lines 5 and 6 are both
assigned @code{objc-method-call-cont} syntax.
Java has a concept of anonymous classes, which may look something like
this:
-@example
-@group
-
- 1: public void watch(Observable o) @{
- 2: o.addObserver(new Observer() @{
- 3: public void update(Observable o, Object arg) @{
- 4: history.addElement(arg);
- 5: @}
- 6: @});
- 7: @}
-@end group
+@example
+ 1: public void watch(Observable o) @{
+ 2: o.addObserver(new Observer() @{
+ 3: public void update(Observable o, Object arg) @{
+ 4: history.addElement(arg);
+ 5: @}
+ 6: @});
+ 7: @}
@end example
-@cindex inexpr-class syntactic symbol
+@ssindex inexpr-class
The brace following the @code{new} operator opens the anonymous class.
Lines 3 and 6 are assigned the @code{inexpr-class} syntax, besides the
@code{inclass} symbol used in normal classes. Thus, the class will be
@@ -3621,19 +4023,16 @@ indented just like a normal class, with the added indentation given to
There are a few occasions where a statement block may be used inside an
expression. One is in C code using the gcc extension for this, e.g:
-@example
-@group
-
- 1: int res = (@{
- 2: int y = foo (); int z;
- 3: if (y > 0) z = y; else z = - y;
- 4: z;
- 5: @});
-@end group
+@example
+ 1: int res = (@{
+ 2: int y = foo (); int z;
+ 3: if (y > 0) z = y; else z = - y;
+ 4: z;
+ 5: @});
@end example
-@cindex inexpr-statement syntactic symbol
+@ssindex inexpr-statement
Lines 2 and 5 get the @code{inexpr-statement} syntax, besides the
symbols they'd get in a normal block. Therefore, the indentation put on
@code{inexpr-statement} is added to the normal statement block
@@ -3641,27 +4040,24 @@ indentation.
In Pike code, there are a few other situations where blocks occur inside
statements, as illustrated here:
-@example
-@group
- 1: array itgob()
- 2: @{
- 3: string s = map (backtrace()[-2][3..],
- 4: lambda
- 5: (mixed arg)
- 6: @{
- 7: return sprintf ("%t", arg);
- 8: @}) * ", " + "\n";
- 9: return catch @{
- 10: write (s + "\n");
- 11: @};
- 12: @}
-
-@end group
+@example
+ 1: array itgob()
+ 2: @{
+ 3: string s = map (backtrace()[-2][3..],
+ 4: lambda
+ 5: (mixed arg)
+ 6: @{
+ 7: return sprintf ("%t", arg);
+ 8: @}) * ", " + "\n";
+ 9: return catch @{
+10: write (s + "\n");
+11: @};
+12: @}
@end example
-@cindex inlambda syntactic symbol
-@cindex lambda-intro-cont syntactic symbol
+@ssindex inlambda
+@ssindex lambda-intro-cont
Lines 4 through 8 contain a lambda function, which @ccmode{} recognizes
by the @code{lambda} keyword. If the function argument list is put
on a line of its own, as in line 5, it gets the @code{lambda-intro-cont}
@@ -3674,29 +4070,26 @@ opening brace, which stands on its own line in this example. If the
opening brace was hanging on the previous line, then the closing brace
would get the @code{inlambda} syntax too to be indented correctly.}.
-@cindex inexpr-statement syntactic symbol
+@ssindex inexpr-statement
On line 9, @code{catch} is a special function taking a statement block
as its argument. The block is handled as an in-expression statement
with the @code{inexpr-statement} syntax, just like the gcc extended C
example above. The other similar special function, @code{gauge}, is
handled like this too.
-@cindex knr-argdecl-intro syntactic symbol
-@cindex knr-argdecl syntactic symbol
+@ssindex knr-argdecl-intro
+@ssindex knr-argdecl
Two other syntactic symbols can appear in old style, non-prototyped C
code @footnote{a.k.a. K&R C, or Kernighan & Ritchie C}:
-@example
-@group
- 1: int add_three_integers(a, b, c)
- 2: int a;
- 3: int b;
- 4: int c;
- 5: @{
- 6: return a + b + c;
- 7: @}
-
-@end group
+@example
+ 1: int add_three_integers(a, b, c)
+ 2: int a;
+ 3: int b;
+ 4: int c;
+ 5: @{
+ 6: return a + b + c;
+ 7: @}
@end example
Here, line 2 is the first line in an argument declaration list and so is
@@ -3706,17 +4099,17 @@ syntax.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Indentation Functions, Performance Issues, Syntactic Symbols, Top
+@node Indentation Functions, AWK Mode, Syntactic Symbols, Top
@comment node-name, next, previous, up
-@chapter Indentation Functions
-@cindex indentation functions
-@cindex line-up functions
+@chapter Indentation Functions
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-Often there are cases when a simple offset setting on a syntactic symbol
-isn't enough to get the desired indentation. Therefore, it's also
-possible to use a @dfn{indentation function} (a.k.a. line-up function)
-for a syntactic symbol.
+@cindex indentation function
+@cindex line-up function
+Often there are cases when a simple offset setting on a syntactic
+symbol isn't enough to get the desired indentation. Therefore, it's
+also possible to use an @dfn{indentation function} (a.k.a. @dfn{line-up
+function}) for a syntactic symbol.
@ccmode{} comes with many predefined indentation functions for common
situations. If none of these does what you want, you can write your
@@ -3737,336 +4130,690 @@ Works with:
@end macro
@end ifinfo
-@table @code
+@macro sssTBasicOffset
+<--> @i{c-basic-offset}@c
+@end macro
+
+@macro sssTsssTBasicOffset
+<--><--> @i{c-basic-offset}@c
+@end macro
+
+@macro hereFn{func}
+<- @i{\func\}@c
+@end macro
-@findex c-lineup-arglist
+@c The TeX backend seems to insert extra spaces around the argument. :P
+@iftex
+@unmacro hereFn
+@macro hereFn{func}
+<-@i{\func\}@c
+@end macro
+@end iftex
+
+@comment ------------------------------------------------------------
+
+@defun c-indent-one-line-block
+@findex indent-one-line-block (c-)
+Indent a one line block @code{c-basic-offset} extra. E.g:
+
+@example
+@group
+if (n > 0)
+ @{m+=n; n=0;@} @hereFn{c-indent-one-line-block}
+@sssTBasicOffset{}
+@end group
+@end example
+
+@noindent
+and
+
+@example
+@group
+if (n > 0)
+@{ @hereFn{c-indent-one-line-block}
+ m+=n; n=0;
+@}
+@end group
+@end example
+
+The block may be surrounded by any kind of parenthesis characters.
+@code{nil} is returned if the line doesn't start with a one line block,
+which makes the function usable in list expressions.
+
+@workswith Almost all syntactic symbols, but most useful on the
+@code{-open} symbols.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-indent-multi-line-block
+@findex indent-multi-line-block (c-)
+Indent a multiline block @code{c-basic-offset} extra. E.g:
+
+@example
+@group
+int *foo[] = @{
+ NULL,
+ @{17@}, @hereFn{c-indent-multi-line-block}
+@end group
+@end example
+
+@noindent
+and
+
+@example
+@group
+int *foo[] = @{
+ NULL,
+ @{ @hereFn{c-indent-multi-line-block}
+ 17
+ @},
+ @sssTBasicOffset{}
+@end group
+@end example
+
+The block may be surrounded by any kind of parenthesis characters.
+@code{nil} is returned if the line doesn't start with a multiline
+block, which makes the function usable in list expressions.
+
+@workswith Almost all syntactic symbols, but most useful on the
+@code{-open} symbols.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-argcont
+@findex lineup-argcont (c-)
+Line up a continued argument. E.g:
+
+@example
+@group
+foo (xyz, aaa + bbb + ccc
+ + ddd + eee + fff); @hereFn{c-lineup-argcont}
+@end group
+@end example
+
+Only continuation lines like this are touched, @code{nil} is returned on
+lines which are the start of an argument.
+
+Within a gcc @code{asm} block, @code{:} is recognised as an argument
+separator, but of course only between operand specifications, not in the
+expressions for the operands.
+
+@workswith @code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-arglist
@findex lineup-arglist (c-)
-@item c-lineup-arglist
Line up the current argument line under the first argument.
-@workswith @code{arglist-cont-nonempty}.
+As a special case, if an argument on the same line as the open
+parenthesis starts with a brace block opener, the indentation is
+@code{c-basic-offset} only. This is intended as a ``DWIM'' measure in
+cases like macros that contains statement blocks, e.g:
+
+@example
+@group
+A_VERY_LONG_MACRO_NAME (@{
+ some (code, with + long, lines * in[it]);
+ @});
+@sssTBasicOffset{}
+@end group
+@end example
+
+This is motivated partly because it's more in line with how code
+blocks are handled, and partly since it approximates the behavior of
+earlier CC Mode versions, which due to inaccurate analysis tended to
+indent such cases this way.
-@findex c-lineup-arglist-intro-after-paren
+@workswith @code{arglist-cont-nonempty}, @code{arglist-close}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-arglist-intro-after-paren
@findex lineup-arglist-intro-after-paren (c-)
-@item c-lineup-arglist-intro-after-paren
-Line up a line just after the open paren of the surrounding paren or
+Line up a line to just after the open paren of the surrounding paren or
brace block.
@workswith @code{defun-block-intro}, @code{brace-list-intro},
@code{statement-block-intro}, @code{statement-case-intro},
@code{arglist-intro}.
+@end defun
+
+@comment ------------------------------------------------------------
-@findex c-lineup-arglist-close-under-paren
+@defun c-lineup-arglist-close-under-paren
@findex lineup-arglist-close-under-paren (c-)
-@item c-lineup-arglist-close-under-paren
-Set e.g. your @code{arglist-close} syntactic symbol to this line-up
-function so that parentheses that close argument lists will line up
-under the parenthesis that opened the argument list.
+Set your @code{arglist-close} syntactic symbol to this line-up function
+so that parentheses that close argument lists will line up under the
+parenthesis that opened the argument list. It can also be used with
+@code{arglist-cont} and @code{arglist-cont-nonempty} to line up all
+lines inside a parenthesis under the open paren.
+
+As a special case, if a brace block is opened at the same line as the
+open parenthesis of the argument list, the indentation is
+@code{c-basic-offset} only. See @code{c-lineup-arglist} for further
+discussion of this ``DWIM'' measure.
+
+@workswith Almost all symbols, but are typically most useful on
+@code{arglist-close}, @code{brace-list-close}, @code{arglist-cont} and
+@code{arglist-cont-nonempty}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-arglist-operators
+@findex lineup-arglist-operators (c-)
+Line up lines starting with an infix operator under the open paren.
+Return @code{nil} on lines that don't start with an operator, to leave
+those cases to other lineup functions. Example:
+
+@example
+@group
+if ( x < 10
+ || at_limit (x, @hereFn{c-lineup-arglist-operators}
+ list) @hereFn{c-lineup-arglist-operators@r{ returns nil}}
+ )
+@end group
+@end example
+
+Since this function doesn't do anything for lines without an infix
+operator you typically want to use it together with some other lineup
+settings, e.g. as follows (the @code{arglist-close} setting is just a
+suggestion to get a consistent style):
+
+@example
+(c-set-offset 'arglist-cont
+ '(c-lineup-arglist-operators 0))
+(c-set-offset 'arglist-cont-nonempty
+ '(c-lineup-arglist-operators c-lineup-arglist))
+(c-set-offset 'arglist-close
+ '(c-lineup-arglist-close-under-paren))
+@end example
+
+@workswith @code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-C-comments
+@findex lineup-C-comments (c-)
+Line up C block comment continuation lines. Various heuristics are used
+to handle most of the common comment styles. Some examples:
+
+@example
+@group
+/* /** /*
+ * text * text text
+ */ */ */
+@end group
+@end example
+
+@example
+@group
+/* text /* /**
+ text ** text ** text
+*/ */ */
+@end group
+@end example
+
+@example
+@group
+/**************************************************
+ * text
+ *************************************************/
+@end group
+@end example
+
+@vindex comment-start-skip
+@example
+@group
+/**************************************************
+ Free form text comments:
+ In comments with a long delimiter line at the
+ start, the indentation is kept unchanged for lines
+ that start with an empty comment line prefix. The
+ delimiter line is whatever matches the
+ @code{comment-start-skip} regexp.
+**************************************************/
+@end group
+@end example
+
+The style variable @code{c-comment-prefix-regexp} is used to recognize
+the comment line prefix, e.g. the @samp{*} that usually starts every
+line inside a comment.
+
+@workswith The @code{c} syntactic symbol.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-cascaded-calls
+@findex lineup-cascaded-calls (c-)
+Line up ``cascaded calls'' under each other. If the line begins with
+@code{->} or @code{.} and the preceding line ends with one or more
+function calls preceded by the same token, then the arrow is lined up
+with the first of those tokens. E.g:
+
+@example
+@group
+r = proc->add(17)->add(18)
+ ->add(19) + @hereFn{c-lineup-cascaded-calls}
+ offset; @hereFn{c-lineup-cascaded-calls@r{ (inactive)}}
+@end group
+@end example
+
+In any other situation @code{nil} is returned to allow use in list
+expressions.
+
+@workswith @code{topmost-intro-cont}, @code{statement-cont},
+@code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
-@workswith @code{defun-close}, @code{class-close}, @code{inline-close},
-@code{block-close}, @code{brace-list-close}, @code{arglist-close},
-@code{extern-lang-close}, @code{namespace-close} (for most of these, a
-zero offset will normally produce the same result, though).
+@comment ------------------------------------------------------------
-@findex c-lineup-close-paren
+@defun c-lineup-close-paren
@findex lineup-close-paren (c-)
-@item c-lineup-close-paren
Line up the closing paren under its corresponding open paren if the
open paren is followed by code. If the open paren ends its line, no
indentation is added. E.g:
+
@example
@group
-
main (int,
- char **
- ) // c-lineup-close-paren
-
+ char **
+ ) @hereFn{c-lineup-close-paren}
@end group
@end example
+
@noindent
and
+
@example
@group
-
main (
int, char **
-) // c-lineup-close-paren
-
+) @hereFn{c-lineup-close-paren}
@end group
@end example
-@workswith @code{defun-close}, @code{class-close}, @code{inline-close},
-@code{block-close}, @code{brace-list-close}, @code{arglist-close},
-@code{extern-lang-close}, @code{namespace-close}.
+As a special case, if a brace block is opened at the same line as the
+open parenthesis of the argument list, the indentation is
+@code{c-basic-offset} instead of the open paren column. See
+@code{c-lineup-arglist} for further discussion of this ``DWIM'' measure.
-@findex c-lineup-streamop
-@findex lineup-streamop (c-)
-@item c-lineup-streamop
-Line up C++ stream operators (i.e. @samp{<<} and @samp{>>}).
+@workswith All @code{*-close} symbols.
+@end defun
-@workswith @code{stream-op}.
+@comment ------------------------------------------------------------
+
+@defun c-lineup-comment
+@findex lineup-comment (c-)
+Line up a comment-only line according to the style variable
+@code{c-comment-only-line-offset}. If the comment is lined up with a
+comment starter on the previous line, that alignment is preserved.
+
+@defopt c-comment-only-line-offset
+@vindex comment-only-line-offset (c-)
+This style variable specifies the extra offset for the line. It can
+contain an integer or a cons cell of the form
-@findex c-lineup-multi-inher
-@findex lineup-multi-inher (c-)
-@item c-lineup-multi-inher
-Line up the classes in C++ multiple inheritance clauses and member
-initializers under each other. E.g:
@example
-@group
+(@r{@var{non-anchored-offset}} . @r{@var{anchored-offset}})
+@end example
-Foo::Foo (int a, int b):
- Cyphr (a),
- Bar (b) // c-lineup-multi-inher
+@noindent
+where @var{non-anchored-offset} is the amount of offset given to
+non-column-zero anchored lines, and @var{anchored-offset} is the amount
+of offset to give column-zero anchored lines. Just an integer as value
+is equivalent to @code{(@r{@var{value}} . -1000)}.
+@end defopt
+
+@workswith @code{comment-intro}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-cpp-define
+@findex lineup-cpp-define (c-)
+Line up macro continuation lines according to the indentation of the
+construct preceding the macro. E.g:
+
+@example
+@group
+const char msg[] = @hereFn{@r{The beginning of the preceding construct.}}
+ \"Some text.\";
+#define X(A, B) \
+do @{ \ @hereFn{c-lineup-cpp-define}
+ printf (A, B); \
+@} while (0)
@end group
@end example
+
@noindent
-and
+and:
+
@example
@group
+int dribble() @{
+ if (!running) @hereFn{@r{The beginning of the preceding construct.}}
+ error(\"Not running!\");
+
+#define X(A, B) \
+ do @{ \ @hereFn{c-lineup-cpp-define}
+ printf (A, B); \
+ @} while (0)
+@end group
+@end example
-class Foo
- : public Cyphr,
- public Bar // c-lineup-multi-inher
+If @code{c-syntactic-indentation-in-macros} is non-@code{nil}, the
+function returns the relative indentation to the macro start line to
+allow accumulation with other offsets. E.g. in the following cases,
+@code{cpp-define-intro} is combined with the
+@code{statement-block-intro} that comes from the @samp{do @{} that hangs
+on the @samp{#define} line:
+@example
+@group
+const char msg[] =
+ \"Some text.\";
+
+#define X(A, B) do @{ \
+ printf (A, B); \ @hereFn{c-lineup-cpp-define}
+ this->refs++; \
+@} while (0) @hereFn{c-lineup-cpp-define}
@end group
@end example
+
@noindent
-and
+and:
+
@example
@group
+int dribble() @{
+ if (!running)
+ error(\"Not running!\");
+
+#define X(A, B) do @{ \
+ printf (A, B); \ @hereFn{c-lineup-cpp-define}
+ this->refs++; \
+ @} while (0) @hereFn{c-lineup-cpp-define}
+@end group
+@end example
-Foo::Foo (int a, int b)
- : Cyphr (a)
- , Bar (b) // c-lineup-multi-inher
+The relative indentation returned by @code{c-lineup-cpp-define} is zero
+and two, respectively, on the two lines in each of these examples. They
+are then added to the two column indentation that
+@code{statement-block-intro} gives in both cases here.
+
+If the relative indentation is zero, then @code{nil} is returned
+instead. That is useful in a list expression to specify the default
+indentation on the top level.
+
+If @code{c-syntactic-indentation-in-macros} is @code{nil} then this
+function keeps the current indentation, except for empty lines (ignoring
+the ending backslash) where it takes the indentation from the closest
+preceding nonempty line in the macro. If there's no such line in the
+macro then the indentation is taken from the construct preceding it, as
+described above.
+
+@workswith @code{cpp-define-intro}.
+@end defun
+
+@comment ------------------------------------------------------------
+@defun c-lineup-dont-change
+@findex lineup-dont-change (c-)
+This lineup function makes the line stay at whatever indentation it
+already has; think of it as an identity function for lineups.
+
+@workswith Any syntactic symbol.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-gcc-asm-reg
+@findex lineup-gcc-asm-reg (c-)
+Line up a gcc asm register under one on a previous line.
+
+@example
+@group
+ asm ("foo %1, %0\n"
+ "bar %0, %1"
+ : "=r" (w),
+ "=r" (x)
+ : "0" (y),
+ "1" (z));
@end group
@end example
-@workswith @code{inher-cont}, @code{member-init-cont}.
+The @samp{x} line is aligned to the text after the @samp{:} on the
+@samp{w} line, and similarly @samp{z} under @samp{y}.
-@findex c-lineup-java-inher
+This is done only in an @samp{asm} or @samp{__asm__} block, and only to
+those lines mentioned. Anywhere else @code{nil} is returned. The usual
+arrangement is to have this routine as an extra feature at the start of
+arglist lineups, e.g.
+
+@example
+(c-lineup-gcc-asm-reg c-lineup-arglist)
+@end example
+
+@workswith @code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-inexpr-block
+@findex lineup-inexpr-block (c-)
+This can be used with the in-expression block symbols to indent the
+whole block to the column where the construct is started. E.g. for Java
+anonymous classes, this lines up the class under the @samp{new} keyword,
+and in Pike it lines up the lambda function body under the @samp{lambda}
+keyword. Returns @code{nil} if the block isn't part of such a
+construct.
+
+@workswith @code{inlambda}, @code{inexpr-statement},
+@code{inexpr-class}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-java-inher
@findex lineup-java-inher (c-)
-@item c-lineup-java-inher
Line up Java implements and extends declarations. If class names
-follows on the same line as the @samp{implements}/@samp{extends}
+follow on the same line as the @samp{implements}/@samp{extends}
keyword, they are lined up under each other. Otherwise, they are
indented by adding @code{c-basic-offset} to the column of the keyword.
E.g:
+
@example
@group
-
class Foo
- extends
- Bar // c-lineup-java-inher
-
- <--> c-basic-offset
-
+ extends
+ Bar @hereFn{c-lineup-java-inher}
+ @sssTBasicOffset{}
@end group
@end example
+
@noindent
and
+
@example
@group
-
class Foo
extends Cyphr,
- Bar // c-lineup-java-inher
-
+ Bar @hereFn{c-lineup-java-inher}
@end group
@end example
@workswith @code{inher-cont}.
+@end defun
+
+@comment ------------------------------------------------------------
-@findex c-lineup-java-throws
+@defun c-lineup-java-throws
@findex lineup-java-throws (c-)
-@item c-lineup-java-throws
-Line up Java throws declarations. If exception names follows on the
+Line up Java throws declarations. If exception names follow on the
same line as the throws keyword, they are lined up under each other.
Otherwise, they are indented by adding @code{c-basic-offset} to the
column of the @samp{throws} keyword. The @samp{throws} keyword itself
is also indented by @code{c-basic-offset} from the function declaration
start if it doesn't hang. E.g:
+
@example
@group
-
int foo()
- throws // c-lineup-java-throws
- Bar // c-lineup-java-throws
-
-<--><--> c-basic-offset
-
+ throws @hereFn{c-lineup-java-throws}
+ Bar @hereFn{c-lineup-java-throws}
+@sssTsssTBasicOffset{}
@end group
@end example
+
@noindent
and
+
@example
@group
-
int foo() throws Cyphr,
- Bar, // c-lineup-java-throws
- Vlod // c-lineup-java-throws
-
+ Bar, @hereFn{c-lineup-java-throws}
+ Vlod @hereFn{c-lineup-java-throws}
@end group
@end example
@workswith @code{func-decl-cont}.
+@end defun
-@findex c-indent-one-line-block
-@findex indent-one-line-block (c-)
-@item c-indent-one-line-block
-Indent a one line block @code{c-basic-offset} extra. E.g:
-@example
-@group
-
-if (n > 0)
- @{m+=n; n=0;@} // c-indent-one-line-block
+@comment ------------------------------------------------------------
-<--> c-basic-offset
+@defun c-lineup-knr-region-comment
+@findex lineup-knr-region-comment (c-)
+Line up a comment in the ``K&R region'' with the declaration. That is
+the region between the function or class header and the beginning of the
+block. E.g:
-@end group
-@end example
-@noindent
-and
@example
@group
-
-if (n > 0)
-@{ // c-indent-one-line-block
- m+=n; n=0;
+int main()
+/* Called at startup. */ @hereFn{c-lineup-knr-region-comment}
+@{
+ return 0;
@}
-
@end group
@end example
-The block may be surrounded by any kind of parenthesis characters.
-@code{nil} is returned if the line doesn't start with a one line block,
-which makes the function usable in list expressions.
+Return @code{nil} if called in any other situation, to be useful in list
+expressions.
-@workswith Almost all syntactic symbols, but most useful on the
-@code{-open} symbols.
+@workswith @code{comment-intro}.
+@end defun
-@findex c-indent-multi-line-block
-@findex indent-multi-line-block (c-)
-@item c-indent-multi-line-block
-Indent a multi line block @code{c-basic-offset} extra. E.g:
-@example
-@group
+@comment ------------------------------------------------------------
-int *foo[] = @{
- NULL,
- @{17@}, // c-indent-multi-line-block
+@defun c-lineup-math
+@findex lineup-math (c-)
+Line up the current line to after the equal sign on the first line in the
+statement. If there isn't any, indent with @code{c-basic-offset}. If
+the current line contains an equal sign too, try to align it with the
+first one.
-@end group
-@end example
-@noindent
-and
-@example
-@group
+@workswith @code{topmost-intro-cont}, @code{statement-cont},
+@code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
-int *foo[] = @{
- NULL,
- @{ // c-indent-multi-line-block
- 17
- @},
+@comment ------------------------------------------------------------
- <--> c-basic-offset
+@defun c-lineup-multi-inher
+@findex lineup-multi-inher (c-)
+Line up the classes in C++ multiple inheritance clauses and member
+initializers under each other. E.g:
+@example
+@group
+Foo::Foo (int a, int b):
+ Cyphr (a),
+ Bar (b) @hereFn{c-lineup-multi-inher}
@end group
@end example
-The block may be surrounded by any kind of parenthesis characters.
-@code{nil} is returned if the line doesn't start with a multi line
-block, which makes the function usable in list expressions.
-
-@workswith Almost all syntactic symbols, but most useful on the
-@code{-open} symbols.
+@noindent
+and
-@findex c-lineup-C-comments
-@findex lineup-C-comments (c-)
-@item c-lineup-C-comments
-Line up C block comment continuation lines. Various heuristics are used
-to handle most of the common comment styles. Some examples:
@example
-
@group
-/* /** /*
- * text * text text
- */ */ */
+class Foo
+ : public Cyphr,
+ public Bar @hereFn{c-lineup-multi-inher}
@end group
+@end example
-@group
-/* text /* /**
- text ** text ** text
-*/ */ */
-@end group
+@noindent
+and
+@example
@group
-/**************************************************
- * text
- *************************************************/
+Foo::Foo (int a, int b)
+ : Cyphr (a)
+ , Bar (b) @hereFn{c-lineup-multi-inher}
@end group
+@end example
-@vindex comment-start-skip
-@group
-/**************************************************
- Free form text comments:
- In comments with a long delimiter line at the
- start, the indentation is kept unchanged for lines
- that start with an empty comment line prefix. The
- delimiter line is whatever matches the
- @code{comment-start-skip} regexp.
-**************************************************/
-@end group
+@workswith @code{inher-cont}, @code{member-init-cont}.
+@end defun
-@end example
+@comment ------------------------------------------------------------
-The style variable @code{c-comment-prefix-regexp} is used to recognize
-the comment line prefix, e.g. the @samp{*} that usually starts every
-line inside a comment.
+@defun c-lineup-ObjC-method-call
+@findex lineup-ObjC-method-call (c-)
+For Objective-C code, line up selector args as Emacs Lisp mode does
+with function args: go to the position right after the message receiver,
+and if you are at the end of the line, indent the current line
+c-basic-offset columns from the opening bracket; otherwise you are
+looking at the first character of the first method call argument, so
+lineup the current line with it.
-@workswith The @code{c} syntactic symbol.
+@workswith @code{objc-method-call-cont}.
+@end defun
-@findex c-lineup-comment
-@findex lineup-comment (c-)
-@item c-lineup-comment
-Line up a comment-only line according to the style variable
-@code{c-comment-only-line-offset}. If the comment is lined up with a
-comment starter on the previous line, that alignment is preserved.
+@comment ------------------------------------------------------------
-@vindex c-comment-only-line-offset
-@vindex comment-only-line-offset (c-)
-@code{c-comment-only-line-offset} specifies the extra offset for the
-line. It can contain an integer or a cons cell of the form
-@example
+@defun c-lineup-ObjC-method-args
+@findex lineup-ObjC-method-args (c-)
+For Objective-C code, line up the colons that separate args. The colon
+on the current line is aligned with the one on the first line.
- (@r{<non-anchored-offset>} . @r{<anchored-offset>})
+@workswith @code{objc-method-args-cont}.
+@end defun
-@end example
+@comment ------------------------------------------------------------
-@noindent
-where @var{non-anchored-offset} is the amount of offset given to
-non-column-zero anchored lines, and @var{anchored-offset} is the amount
-of offset to give column-zero anchored lines. Just an integer as value
-is equivalent to @code{(@r{<value>} . -1000)}.
+@defun c-lineup-ObjC-method-args-2
+@findex lineup-ObjC-method-args-2 (c-)
+Similar to @code{c-lineup-ObjC-method-args} but lines up the colon on
+the current line with the colon on the previous line.
-@workswith @code{comment-intro}.
+@workswith @code{objc-method-args-cont}.
+@end defun
+
+@comment ------------------------------------------------------------
-@findex c-lineup-runin-statements
+@defun c-lineup-runin-statements
@findex lineup-runin-statements (c-)
-@item c-lineup-runin-statements
Line up statements for coding standards which place the first statement
in a block on the same line as the block opening brace@footnote{Run-in
style doesn't really work too well. You might need to write your own
custom indentation functions to better support this style.}. E.g:
+
@example
@group
-
int main()
-@{ puts (\"Hello world!\");
- return 0; // c-lineup-runin-statements
+@{ puts ("Hello!");
+ return 0; @hereFn{c-lineup-runin-statements}
@}
-
@end group
@end example
@@ -4075,20 +4822,43 @@ If there is no statement after the opening brace to align with,
expressions.
@workswith The @code{statement} syntactic symbol.
+@end defun
-@findex c-lineup-math
-@findex lineup-math (c-)
-@item c-lineup-math
-Line up the current line after the equal sign on the first line in the
-statement. If there isn't any, indent with @code{c-basic-offset}. If
-the current line contains an equal sign too, try to align it with the
-first one.
+@comment ------------------------------------------------------------
+
+@defun c-lineup-streamop
+@findex lineup-streamop (c-)
+Line up C++ stream operators (i.e. @samp{<<} and @samp{>>}).
+
+@workswith @code{stream-op}.
+@end defun
+
+@comment ------------------------------------------------------------
-@workswith @code{statement-cont}.
+@defun c-lineup-string-cont
+@findex lineup-string-cont (c-)
+Line up a continued string under the one it continues. A continued
+string in this sense is where a string literal follows directly after
+another one. E.g:
-@findex c-lineup-template-args
+@example
+@group
+result = prefix + "A message "
+ "string."; @hereFn{c-lineup-string-cont}
+@end group
+@end example
+
+@code{nil} is returned in other situations, to allow stacking with other
+lineup functions.
+
+@workswith @code{topmost-intro-cont}, @code{statement-cont},
+@code{arglist-cont}, @code{arglist-cont-nonempty}.
+@end defun
+
+@comment ------------------------------------------------------------
+
+@defun c-lineup-template-args
@findex lineup-template-args (c-)
-@item c-lineup-template-args
Line up the arguments of a template argument list under each other, but
only in the case where the first argument is on the same line as the
opening @samp{<}.
@@ -4097,74 +4867,86 @@ To allow this function to be used in a list expression, @code{nil} is
returned if there's no template argument on the first line.
@workswith @code{template-args-cont}.
+@end defun
-@findex c-lineup-ObjC-method-call
-@findex lineup-ObjC-method-call (c-)
-@item c-lineup-ObjC-method-call
-For Objective-C code, line up selector args as @code{elisp-mode} does
-with function args: go to the position right after the message receiver,
-and if you are at the end of the line, indent the current line
-c-basic-offset columns from the opening bracket; otherwise you are
-looking at the first character of the first method call argument, so
-lineup the current line with it.
+@comment ------------------------------------------------------------
-@workswith @code{objc-method-call-cont}.
+@defun c-lineup-topmost-intro-cont
+@findex lineup-topmost-intro-cont (c-)
+Line up declaration continuation lines zero or one indentation
+step@footnote{This function is mainly provided to mimic the behavior of
+CC Mode 5.28 and earlier where this case wasn't handled consistently so
+that those lines could be analyzed as either topmost-intro-cont or
+statement-cont. It's used for @code{topmost-intro-cont} by default, but
+you might consider using @code{+} instead.}. For lines preceding a
+definition, zero is used. For other lines, @code{c-basic-offset} is
+added to the indentation. E.g:
-@findex c-lineup-ObjC-method-args
-@findex lineup-ObjC-method-args (c-)
-@item c-lineup-ObjC-method-args
-For Objective-C code, line up the colons that separate args. The colon
-on the current line is aligned with the one on the first line.
+@example
+@group
+int
+neg (int i) @hereFn{c-lineup-topmost-intro-cont}
+@{
+ return -i;
+@}
+@end group
+@end example
-@workswith @code{objc-method-args-cont}.
+@noindent
+and
-@findex c-lineup-ObjC-method-args-2
-@findex lineup-ObjC-method-args-2 (c-)
-@item c-lineup-ObjC-method-args-2
-Similar to @code{c-lineup-ObjC-method-args} but lines up the colon on
-the current line with the colon on the previous line.
+@example
+@group
+struct
+larch @hereFn{c-lineup-topmost-intro-cont}
+@{
+ double height;
+@}
+ the_larch, @hereFn{c-lineup-topmost-intro-cont}
+ another_larch; @hereFn{c-lineup-topmost-intro-cont}
+@sssTBasicOffset{}
+@end group
+@end example
-@workswith @code{objc-method-args-cont}.
+@noindent
+and
-@findex c-lineup-inexpr-block
-@findex lineup-inexpr-block (c-)
-@item c-lineup-inexpr-block
-This can be used with the in-expression block symbols to indent the
-whole block to the column where the construct is started. E.g. for Java
-anonymous classes, this lines up the class under the @samp{new} keyword,
-and in Pike it lines up the lambda function body under the @samp{lambda}
-keyword. Returns @code{nil} if the block isn't part of such a
-construct.
+@example
+@group
+struct larch
+the_larch, @hereFn{c-lineup-topmost-intro-cont}
+ another_larch; @hereFn{c-lineup-topmost-intro-cont}
+@end group
+@end example
-@workswith @code{inlambda}, @code{inexpr-statement},
-@code{inexpr-class}.
+@workswith @code{topmost-intro-cont}.
+@end defun
+
+@comment ------------------------------------------------------------
-@findex c-lineup-whitesmith-in-block
+@defun c-lineup-whitesmith-in-block
@findex lineup-whitesmith-in-block (c-)
-@item c-lineup-whitesmith-in-block
-Line up lines inside a block in Whitesmiths style. It's done in a way
+Line up lines inside a block in Whitesmith style. It's done in a way
that works both when the opening brace hangs and when it doesn't. E.g:
+
@example
@group
-
something
@{
- foo; // c-lineup-whitesmith-in-block
+ foo; @hereFn{c-lineup-whitesmith-in-block}
@}
-
@end group
@end example
+
@noindent
and
+
@example
@group
-
something @{
- foo; // c-lineup-whitesmith-in-block
+ foo; @hereFn{c-lineup-whitesmith-in-block}
@}
-
-<--> c-basic-offset
-
+@sssTBasicOffset{}
@end group
@end example
@@ -4173,43 +4955,339 @@ In the first case the indentation is kept unchanged, in the second
@workswith @code{defun-close}, @code{defun-block-intro},
@code{block-close}, @code{brace-list-close}, @code{brace-list-intro},
-@code{statement-block-intro}, @code{inclass}, @code{inextern-lang},
-@code{innamespace}.
+@code{statement-block-intro} and all @code{in*} symbols,
+e.g. @code{inclass} and @code{inextern-lang}.
+@end defun
-@findex c-lineup-dont-change
-@findex lineup-dont-change (c-)
-@item c-lineup-dont-change
-This lineup function makes the line stay at whatever indentation it
-already has; think of it as an identity function for lineups. It is
-used for @code{cpp-macro-cont} lines.
-@workswith Any syntactic symbol.
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node AWK Mode, Odds and Ends, Indentation Functions, Top
+@comment node-name, next, previous, up
+@chapter Status of AWK Mode
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+@dfn{AWK mode} existed until recently in the file @file{awk-mode.el}
+as a mode derived from c-mode. It had not been actively maintained to
+keep pace with the newer @ccmode{}, and its indentation mechanism no
+longer worked satisfactorally.
+
+The current AWK mode is based around the GNU implementation,
+@emph{GAWK version 3.1.0}, though it should work pretty well with any
+AWK. It has now been updated and integrated into @ccmode{} to a
+substantial extent, though as yet not all the features of @ccmode{}
+have been adapted to support it.
+
+If your (X)Emacs is set up to use the old file @file{awk-mode.elc}
+(which will usually be the case if you have obtained this @ccmode{}
+independently of (X)Emacs itself), or if you are not sure, insert the
+following form into your @file{.emacs} or @file{init.el} so that the new
+AWK mode will be used instead:
+
+@example
+(autoload 'awk-mode "cc-mode" nil t)
+@end example
+
+You can check which AWK mode you are running by displaying the mode
+documentation string with @kbd{C-h m} from an AWK buffer. The newer
+mode's doc string contains @code{To submit a problem report, enter
+`C-c C-b'} near the top of the doc string where the older mode has
+@code{This is much like C mode except ....}.
+
+Since this newer AWK mode makes essential use of a relatively new
+Emacs Lisp feature@footnote{Specifically, the @code{syntax-table} text
+property.}, you need either GNU Emacs 20.1 (or later) or XEmacs 21.4
+(or later) to use it. If your Emacs version is earlier than one of
+these, the older @file{awk-mode.el} will get loaded and run in place
+of the AWK mode described here, even when you have put the above
+@code{autoload} form into your @file{.emacs} or @file{init.el}.
+Upgrading your (X)Emacs is strongly recommended if this is the case.
+
+Here is an overview of which @ccmode{} features currently work with
+AWK mode and which don't:
+
+@table @asis
+@item Indentation Engine
+The @ccmode{} indentation engine fully supports AWK mode.
+@xref{Indentation Engine}.
+
+AWK mode handles code formatted in the conventional AWK fashion:
+@samp{@{}s which start actions, user-defined functions, or compound
+statements are placed on the same line as the associated construct; the
+matching @samp{@}}s are normally placed under the start of the
+respective pattern, function definition, or structured statement.
+@c Add in a bit about the @samp{@}} being on the same line when the
+@c contents are short.
+
+The predefined indentation functions (@pxref{Indentation Functions})
+haven't yet been adapted for AWK mode, though some of them may work
+serendipitously. There shouldn't be any problems writing custom
+indentation functions for AWK mode.
+
+The command @kbd{C-c C-q} (@code{c-indent-defun}) hasn't yet been
+adapted for AWK, though in practice it works properly nearly all the
+time. Should it fail, explicitly set the region around the function
+(using @kbd{C-u C-SPC}: @kbd{C-M-h} probably won't work either) then do
+@kbd{C-M-\} (@code{indent-region}).
+
+@item Font Locking
+There is a single level of font locking in AWK mode, rather than the
+three distinct levels the other modes have. There are several
+idiosyncrasies in AWK mode's font-locking due to the peculiarities of
+the AWK language itself. @xref{AWK Mode Font Locking}.
+
+@item Comment Commands
+@kbd{M-;} (@code{indent-for-comment}) works fine. None of the other
+@ccmode{} comment formatting commands have yet been adapted for AWK
+mode. @xref{Text Filling and Line Breaking}.
+
+@item Movement Commands
+Most of the movement commands work in AWK mode. The most important
+exceptions are @kbd{M-a} (@code{c-beginning-of-statement}) and
+@kbd{M-e} (@code{c-end-of-statement}) which haven't yet been adapted.
+
+The notion of @dfn{defun} has been augmented to include pattern-action
+pairs. See @ref{AWK Mode Defuns} for a description of commands which
+work on AWK ``defuns''.
+
+Since there is no preprocessor in AWK, the commands which move to
+preprocessor directives (e.g. @code{c-up-conditional}) are meaningless
+in AWK mode and are not bound in the AWK mode keymap.
+
+@item Auto-newline Insertion and Clean-ups
+Auto-newline insertion hasn't yet been adapted for AWK. Some of the
+clean-ups can actually convert good AWK code into syntactically
+invalid code.
+
+If auto-newline or its associated clean-ups are enabled generally for
+the modes in @ccmode{}, you are strongly recommended to disable them
+in the AWK Mode hook. @xref{Initialising AWK Mode}.
+
+The clean-up @code{space-before-funcall}, which is independent of
+auto-newline, should never be active in AWK mode (since inserting a
+space between a user function's name and its opening @samp{(} makes
+the call syntactically invalid). If necessary, this should be
+disabled in the AWK Mode hook. @xref{Initialising AWK Mode}.
@end table
+@menu
+* Initialising AWK Mode::
+* AWK Mode Font Locking::
+* AWK Mode Defuns::
+@end menu
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Initialising AWK Mode, AWK Mode Font Locking, , AWK Mode
+@comment node-name, next, previous, up
+@section AWK mode - What to put in your @file{.emacs} or @file{init.el}
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+Much of the AWK mode initialization can, of course, be done by the
+@ccmode{} general initialization procedure. You may want to use certain
+@ccmode{} features such as @code{auto-newline} and @code{clean-ups} in
+the other modes, and you might thus have enabled them in a
+@code{c-mode-common-hook} function, as described in @ref{Sample .emacs File}.
+These features have not yet been amended for AWK mode, and far from
+being useful, can be irritating in AWK mode or actually make AWK code
+syntactically invalid. Adding the following code to your
+@file{.emacs} or @file{init.el} file will disable them for AWK mode.
+
+@example
+(defun my-awk-mode-hook ()
+ "Disable certain @ccmode{} features which could impair AWK mode."
+ (c-toggle-auto-state -1) ; disable automatic insertions of newlines
+ (if (memq 'space-before-funcall c-cleanup-list)
+ (setq c-cleanup-list ; don't automatically insert a space into "foo("
+ (remove 'space-before-funcall c-cleanup-list))))
+(add-hook 'awk-mode-hook 'my-awk-mode-hook)
+@end example
+
+Naturally you can add your own AWK-specific customizations to this
+function. @xref{Hooks}.
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node AWK Mode Font Locking, AWK Mode Defuns, Initialising AWK Mode, AWK Mode
+@comment node-name, next, previous, up
+@section AWK Mode Font Locking
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+The general appearance of font-locking in AWK mode is much like in any
+other programming mode. @xref{Faces For Font Lock,,,elisp}.
+
+The following faces are, however, used in a non-standard fashion in
+AWK mode:
+
+@table @asis
+@item @code{font-lock-variable-name-face}
+This face was intended for variable declarations. Since variables are
+not declared in AWK, this face is used instead for AWK system
+variables (such as @code{NF}) and ``Special File Names'' (such as
+@code{"/dev/stderr"}).
+
+@item @code{font-lock-builtin-face} (Emacs)/@code{font-lock-preprocessor-face} (XEmacs)
+This face is normally used for preprocessor directives in @ccmode{}.
+There are no such things in AWK, so this face is used instead for
+standard functions (such as @code{match}).
+
+@item @code{font-lock-string-face}
+As well as being used for strings, including localizable strings,
+(delimited by @samp{"} and @samp{_"}), this face is also used for AWK
+regular expressions (delimited by @samp{/}).
+
+@item @code{font-lock-warning-face} (Emacs)/@code{c-invalid-face} (XEmacs)
+This face highlights the following syntactically invalid AWK
+constructs:
+
+@itemize @bullet
+@item
+An unterminated string or regular expression. Here the opening
+delimiter (@samp{"} or @samp{/} or @samp{_"}) is displayed in
+@code{font-lock-warning-face}. This is most noticeable when typing in a
+new string/regular expression into a buffer, when the warning-face
+serves as a continual reminder to terminate the construct.
+
+AWK mode fontifies unterminated strings/regular expressions
+differently from other modes: Only the text up to the end of the line
+is fontified as a string (escaped newlines being handled correctly),
+rather than the text up to the next string quote.
+
+@item
+A space between the function name and opening parenthesis when calling
+a user function. The last character of the function name and the
+opening parenthesis are highlighted. This font-locking rule will
+spuriously highlight a valid concatenation expression where an
+identifier precedes a parenthesised expression. Unfortunately.
+
+@item
+Whitespace following the @samp{\} in what otherwise looks like an
+escaped newline. The @samp{\} is highlighted.
+@end itemize
+@end table
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node AWK Mode Defuns, , AWK Mode Font Locking, AWK Mode
+@comment node-name, next, previous, up
+@section AWK Mode Defuns
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+In AWK mode, @dfn{defun} means either a user-defined function or a
+pattern-action pair. Either the pattern or the action may be
+implicit.
+
+The beginning of a defun is recognised heuristically as, more or less,
+code which begins in column zero. Having the @samp{@{} in column zero,
+as is suggested for some modes, is neither necessary nor helpful in AWK
+mode.
+
+More precisely, the beginning of a defun is code which begins in
+column zero, and which isn't a closing brace, a comment, or a
+continuation of the previous line. Code is the @dfn{continuation of
+the previous line} when that line is syntactically incomplete, for
+example when it ends with @samp{@{} or an escaped newline.
+
+The end of a defun is the @samp{@}} which matches the @samp{@{} (if
+any) at the beginning of the action or function body, or the EOL or
+@samp{;} which marks an implicit action. Although this @samp{@}} is
+usually placed in column zero, AWK mode doesn't need it to be placed
+there.
+
+@table @asis
+@item @kbd{C-M-a} @code{c-awk-beginning-of-defun}
+@itemx @kbd{C-M-e} @code{c-awk-end-of-defun}
+@findex c-awk-beginning-of-defun
+@findex awk-beginning-of-defun (c-)
+@findex c-awk-end-of-defun
+@findex awk-end-of-defun (c-)
+Move point back to the beginning or forward to the end of the current
+AWK defun. These functions can take prefix-arguments, their
+functionality being entirely equivalent to @code{beginning-of-defun}
+and @code{end-of-defun}. @xref{Moving by Defuns,,,emacs}.
+
+@item @kbd{C-M-h} @code{c-mark-function}
+This works fine with AWK defuns. @xref{Indentation Commands}.
+@end table
+
+
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@node Odds and Ends, Performance Issues, AWK Mode, Top
+@comment node-name, next, previous, up
+@chapter Odds and Ends
+@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+The stuff that didn't fit in anywhere else is documented here.
+
+@defopt c-require-final-newline
+@vindex require-final-newline (c-)
+Controls whether a final newline is ensured when the file is saved. The
+value is an association list that for each language mode specifies the
+value to give to @code{require-final-newline} at mode initialization;
+see that variable for details about the value. If a language isn't
+present on the association list, CC Mode won't set
+@code{require-final-newline} in buffers for that language.
+
+The default is to set @code{require-final-newline} to @code{t} in the
+languages that mandates that source files should end with newlines,
+i.e. C, C++ and Objective-C.
+@end defopt
+
+@defopt c-echo-syntactic-information-p
+@vindex echo-syntactic-information-p (c-)
+If non-@code{nil}, the syntactic analysis for the current line is shown
+in the echo area when it's indented (unless
+@code{c-syntactic-indentation} is @code{nil}). That's useful when
+finding out which syntactic symbols to modify to get the indentation you
+want.
+@end defopt
+
+@defopt c-report-syntactic-errors
+@vindex report-syntactic-errors (c-)
+If non-@code{nil}, certain syntactic errors are reported with a ding and
+a message, for example when an @code{else} is indented for which there
+is no corresponding @code{if}.
+
+Note however that @ccmode{} doesn't make any special effort to check for
+syntactic errors; that's the job of the compiler. The reason it can
+report cases like the one above is that it can't find the correct
+anchoring position to indent the line in that case.
+@end defopt
+
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Performance Issues, Limitations and Known Bugs, Indentation Functions, Top
+@node Performance Issues, Limitations and Known Bugs, Odds and Ends, Top
@comment node-name, next, previous, up
-@chapter Performance Issues
-@cindex performance issues
+@chapter Performance Issues
+@cindex performance
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@comment FIXME: (ACM, 2003/5/24). Check whether AWK needs mentioning here.
+
C and its derivative languages are highly complex creatures. Often,
-ambiguous code situations arise that require @ccmode{} to scan
-large portions of the buffer to determine syntactic context. Such
-pathological code@footnote{such as the output of @code{lex(1)}!}
-can cause @ccmode{} to perform fairly badly.
-This section identifies some of the coding styles to watch out for, and
-suggests some workarounds that you can use to improve performance.
+ambiguous code situations arise that require @ccmode{} to scan large
+portions of the buffer to determine syntactic context. Such
+pathological code can cause @ccmode{} to perform fairly badly. This
+section gives some insight in how @ccmode{} operates, how that interacts
+with some coding styles, and what you can use to improve performance.
+
+The overall goal is that @ccmode{} shouldn't be overly slow (i.e. take
+more than a fraction of a second) in any interactive operation.
+I.e. it's tuned to limit the maximum response time in single operations,
+which sometimes is at the expense of batch-like operations like
+reindenting whole blocks. If you find that @ccmode{} gradually gets
+slower and slower in certain situations, perhaps as the file grows in
+size or as the macro or comment you're editing gets bigger, then chances
+are that something isn't working right. You should consider reporting
+it, unless it's something that's mentioned in this section.
Because @ccmode{} has to scan the buffer backwards from the current
insertion point, and because C's syntax is fairly difficult to parse in
the backwards direction, @ccmode{} often tries to find the nearest
-position higher up in the buffer from which to begin a forward scan.
-The farther this position is from the current insertion point, the
-slower the mode gets. Some coding styles can even force @ccmode{}
-to scan from the beginning of the buffer for every line of code!
+position higher up in the buffer from which to begin a forward scan
+(it's typically an opening or closing parethesis of some kind). The
+farther this position is from the current insertion point, the slower it
+gets.
@findex beginning-of-defun
@findex defun-prompt-regexp
@@ -4218,111 +5296,112 @@ any brace that opens a top-level construct@footnote{E.g. a function in
C, or outermost class definition in C++ or Java.} always appears in the
leftmost column. This is actually an Emacs constraint, as embodied in
the @code{beginning-of-defun} function which @ccmode{} uses heavily. If
-you insist on hanging top-level open braces on the right side of the
-line, then you might want to set the variable @code{defun-prompt-regexp}
-to something reasonable, however that ``something reasonable'' is
-difficult to define, so @ccmode{} doesn't do it for you.
+you hang top-level open braces on the right side of the line, then you
+might want to set the variable @code{defun-prompt-regexp} to something
+reasonable, however that ``something reasonable'' is difficult to
+define, so @ccmode{} doesn't do it for you.
@vindex c-Java-defun-prompt-regexp
@vindex Java-defun-prompt-regexp (c-)
-A special note about @code{defun-prompt-regexp} in Java mode: while much
-of the early sample Java code seems to encourage a style where the brace
-that opens a class is hung on the right side of the line, this is not a
-good style to pursue in Emacs. @ccmode{} comes with a variable
+A special note about @code{defun-prompt-regexp} in Java mode: The common
+style is to hang the opening braces of functions and classes on the
+right side of the line, and that doesn't work well with the Emacs
+approach. @ccmode{} comes with a variable
@code{c-Java-defun-prompt-regexp} which tries to define a regular
expression usable for this style, but there are problems with it. In
some cases it can cause @code{beginning-of-defun} to hang@footnote{This
has been observed in Emacs 19.34 and XEmacs 19.15.}. For this reason,
it is not used by default, but if you feel adventurous, you can set
@code{defun-prompt-regexp} to it in your mode hook. In any event,
-setting and rely on @code{defun-prompt-regexp} will definitely slow
-things down anyway because you'll be doing regular expression searches
-for every line you indent, so you're probably screwed either way!
+setting and relying on @code{defun-prompt-regexp} will definitely slow
+things down because (X)Emacs will be doing regular expression searches a
+lot, so you'll probably be taking a hit either way!
+
+@ccmode{} maintains a cache of the opening parentheses of the blocks
+surrounding the point, and it adapts that cache as the point is moved
+around. That means that in bad cases it can take noticeable time to
+indent a line in a new surrounding, but after that it gets fast as long
+as the point isn't moved far off. The farther the point is moved, the
+less useful is the cache. Since editing typically is done in ``chunks''
+rather than on single lines far apart from each other, the cache
+typically gives good performance even when the code doesn't fit the
+Emacs approach to finding the defun starts.
@vindex c-enable-xemacs-performance-kludge-p
@vindex enable-xemacs-performance-kludge-p (c-)
-Another alternative for XEmacs users, is to set the variable
+XEmacs users can set the variable
@code{c-enable-xemacs-performance-kludge-p} to non-@code{nil}. This
tells @ccmode{} to use XEmacs-specific built-in functions which, in some
-circumstances, can locate the top-most opening brace much quicker than
+circumstances, can locate the top-most opening brace much more quickly than
@code{beginning-of-defun}. Preliminary testing has shown that for
styles where these braces are hung (e.g. most JDK-derived Java styles),
this hack can improve performance of the core syntax parsing routines
from 3 to 60 times. However, for styles which @emph{do} conform to
Emacs' recommended style of putting top-level braces in column zero,
this hack can degrade performance by about as much. Thus this variable
-is set to @code{nil} by default, since the Emacs-friendly styles
-should be more common (and
-encouraged!). Note that this variable has no effect in Emacs since the
-necessary built-in functions don't exist (in Emacs 20.2 or 20.3 as of
-this writing 27-Apr-1998).
-
-You will probably notice pathological behavior from @ccmode{} when
-working in files containing large amounts of C preprocessor macros.
-This is because Emacs cannot skip backwards over these lines as quickly
-as it can comments.
-
-@vindex c-recognize-knr-p
-@vindex recognize-knr-p (c-)
-Previous versions of @ccmode{} had potential performance problems
-when recognizing K&R style function argument declarations. This was
-because there are ambiguities in the C syntax when K&R style argument
-lists are used@footnote{It is hard to distinguish them from top-level
-declarations.}. @ccmode{} has adopted BOCM's convention for
-limiting the search: it assumes that argdecls are indented at least one
-space, and that the function headers are not indented at all. With
-current versions of @ccmode{}, user customization of
-@code{c-recognize-knr-p} is deprecated. Just don't put argdecls in
-column zero!
-
-@cindex @file{cc-lobotomy.el} file
-@vindex cc-lobotomy-pith-list
-You might want to investigate the speed-ups contained in the
-file @file{cc-lobotomy.el}, which comes as part of the @ccmode{}
-distribution, but is completely unsupported.
-As mentioned previous, @ccmode{} always trades speed for accuracy,
-however it is recognized that sometimes you need speed and can sacrifice
-some accuracy in indentation. The file @file{cc-lobotomy.el} contains
-hacks that will ``dumb down'' @ccmode{} in some specific ways, making
-that trade-off of accuracy for speed. I won't go into details of its
-use here; you should read the comments at the top of the file, and look
-at the variable @code{cc-lobotomy-pith-list} for details.
+is set to @code{nil} by default, since the Emacs-friendly styles should
+be more common (and encouraged!). Note that this variable has no effect
+in Emacs since the necessary built-in functions don't exist (in Emacs
+21.3 as of this writing in May 2003).
+
+Text properties are used to speed up skipping over syntactic whitespace,
+i.e. comments and preprocessor directives. Indenting a line after a
+huge macro definition can be slow the first time, but after that the
+text properties are in place and it should be fast (even after you've
+edited other parts of the file and then moved back).
+
+Font locking can be a CPU hog, especially the font locking done on
+decoration level 3 which tries to be very accurate. Note that that
+level is designed to be used with a font lock support mode that only
+fontifies the text that's actually shown, i.e. Lazy Lock or Just-in-time
+Lock mode, so make sure you use one of them. Fontification of a whole
+buffer with some thousand lines can often take over a minute. That is
+a known weakness; the idea is that it never should happen.
+
+The most effective way to speed up font locking is to reduce the
+decoration level to 2 by setting @code{font-lock-maximum-decoration}
+appropriately. That level is designed to be as pretty as possible
+without sacrificing performance. @xref{Font Locking Preliminaries}, for
+more info.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Limitations and Known Bugs, Frequently Asked Questions, Performance Issues, Top
@comment node-name, next, previous, up
-@chapter Limitations and Known Bugs
+@chapter Limitations and Known Bugs
@cindex limitations
@cindex bugs
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@itemize @bullet
@item
-Re-indenting large regions or expressions can be slow.
+There is no way to apply auto newline settings (@pxref{Auto-newline
+Insertion}) on already typed lines. That's only a feature to ease
+interactive editing.
-@findex c-indent-exp
-@findex indent-exp (c-)
-@item
-@code{c-indent-exp} has not been fully optimized. It essentially
-equivalent to hitting @kbd{TAB} (@code{c-indent-command}) on every
-line. Some information is cached from line to line, but such caching
-invariable causes inaccuracies in analysis in some bizarre situations.
+To generalize this issue a bit: @ccmode{} is not intended to be used as
+a reformatter for old code in some more or less batch-like way. With
+the exception of some functions like @code{c-indent-region}, it's only
+geared to be used interactively to edit new code. There's currently no
+intention to change this goal.
+
+If you want to reformat old code, you're probably better off using some
+other tool instead, e.g. @ref{Top, , GNU indent, indent, The `indent'
+Manual}, which has more powerful reformatting capabilities than
+@ccmode{}.
-@vindex signal-error-on-buffer-boundary
@item
-XEmacs versions from 19.15 until (as of this writing 12-Mar-1998) 20.4
-contain a variable called @code{signal-error-on-buffer-boundary}. This
-was intended as a solution to user interface problems associated with
+@vindex signal-error-on-buffer-boundary
+XEmacs has a variable called @code{signal-error-on-buffer-boundary}.
+It's used as a solution to user interface problems associated with
buffer movement and the @code{zmacs-region} deactivation on errors.
-However, setting this variable to a non-default value had the
-deleterious side effect of breaking many built-in primitive functions.
-Most users will not be affected since they never change the value of
-this variable. @strong{Do not set this variable to @code{nil}}; you
-will cause serious problems in @ccmode{} and probably other XEmacs
-packages! As of at least XEmacs 20.4, the effects this variable tried
-to correct have been fixed in other, better ways.
-
+However, setting this variable to a non-default value in XEmacs 19 and
+20 had the deleterious side effect of breaking many built-in primitive
+functions. @strong{Do not set this variable to @code{nil} in XEmacs
+19 and 20}; you will cause serious problems in @ccmode{} and probably
+other XEmacs packages! In XEmacs 21 the effects of the variable is
+limited to some functions that are only used interactively, so it's
+not a problem there.
@end itemize
@@ -4330,104 +5409,82 @@ to correct have been fixed in other, better ways.
@node Frequently Asked Questions, Getting the Latest CC Mode Release, Limitations and Known Bugs, Top
@comment node-name, next, previous, up
@appendix Frequently Asked Questions
-@cindex frequently asked questions
-@cindex FAQ
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+@itemize @bullet
+@item
@kindex C-x h
@kindex C-M-\
-@kindex C-M-x
-@kindex C-M-q
-@kindex C-M-u
-@kindex RET
-@kindex C-j
-@quotation
-
-@strong{Q.} @emph{How do I re-indent the whole file?}
+@emph{How do I reindent the whole file?}
-@strong{A.} Visit the file and hit @kbd{C-x h} to mark the whole
-buffer. Then hit @kbd{C-M-\}.
+Visit the file and hit @kbd{C-x h} to mark the whole buffer. Then hit
+@kbd{C-M-\}.
-@sp 1
-@strong{Q.} @emph{How do I re-indent the entire function?
-@kbd{C-M-x} doesn't work.}
-
-@strong{A.} @kbd{C-M-x} is reserved for future Emacs use.
-To re-indent the entire function hit @kbd{C-c C-q}.
+@item
+@kindex C-M-q
+@kindex C-M-u
+@emph{How do I reindent the current block?}
-@sp 1
-@strong{Q.} @emph{How do I re-indent the current block?}
+First move to the brace which opens the block with @kbd{C-M-u}, then
+reindent that expression with @kbd{C-M-q}.
-@strong{A.} First move to the brace which opens the block with
-@kbd{C-M-u}, then re-indent that expression with
-@kbd{C-M-q}.
+@item
+@kindex RET
+@kindex C-j
+@emph{Why doesn't the @kbd{RET} key indent the new line?}
-@sp 1
-@strong{Q.} @emph{Why doesn't the @kbd{RET} key indent the new line?}
+Emacs' convention is that @kbd{RET} just adds a newline, and that
+@kbd{C-j} adds a newline and indents it. You can make @kbd{RET} do this
+too by adding this to your @code{c-mode-common-hook}:
-@strong{A.} Emacs' convention is that @kbd{RET} just adds a newline,
-and that @kbd{C-j} adds a newline and indents it. You can make
-@kbd{RET} do this too by adding this to your
-@code{c-mode-common-hook}:
@example
-
(define-key c-mode-base-map "\C-m" 'c-context-line-break)
-
@end example
This is a very common question. If you want this to be the default
behavior, don't lobby me, lobby RMS! @t{:-)}
-@sp 1
-@strong{Q.} @emph{I put @code{(c-set-offset 'substatement-open 0)}
-in my @file{.emacs} file but I get an error saying that
-@code{c-set-offset}'s function definition is void.}
-
-@strong{A.} This means that @ccmode{} wasn't loaded into your
-Emacs session by the time the @code{c-set-offset} call was reached,
-most likely because @ccmode{} is being autoloaded. Instead
-of putting the @code{c-set-offset} line in your top-level
-@file{.emacs} file, put it in your @code{c-mode-common-hook}, or
-simply modify @code{c-offsets-alist} directly:
-@example
+@item
+@emph{I put @code{(c-set-offset 'substatement-open 0)} in my
+@file{.emacs} file but I get an error saying that @code{c-set-offset}'s
+function definition is void. What's wrong?}
-(setq c-offsets-alist '((substatement-open . 0)))
+This means that @ccmode{} wasn't loaded into your Emacs session by the
+time the @code{c-set-offset} call was reached, most likely because
+@ccmode{} is being autoloaded. Instead of putting the
+@code{c-set-offset} line in your top-level @file{.emacs} file, put it in
+your @code{c-mode-common-hook}, or simply modify @code{c-offsets-alist}
+directly:
+@example
+(setq c-offsets-alist '((substatement-open . 0)))
@end example
-@sp 1
-@strong{Q.} @emph{How do I make strings, comments, keywords, and other
-constructs appear in different colors, or in bold face, etc.?}
-
-@strong{A.} ``Syntax Colorization'' is a standard Emacs feature,
-controlled by @code{font-lock-mode}. @ccmode{} does not contain
-font-lock definitions for any of its supported languages.
-
-@sp 1
-@strong{Q.} @emph{@kbd{M-a} and @kbd{M-e} used to move over entire
-balanced brace lists, but now they move into blocks. How do I get the
-old behavior back?}
-
-@strong{A.} Use @kbd{C-M-f} and @kbd{C-M-b} to move over balanced brace
-blocks. Use @kbd{M-a} and @kbd{M-e} to move by statements, which will
-also move into blocks.
-
-@sp 1
-@strong{Q.} @emph{Whenever I try to indent a line or type an
-``electric'' key such as @kbd{;}, @kbd{@{}, or @kbd{@}}, I get an error
-that look like this: @code{Invalid function: (macro . #[...}. What
-gives?}
-
-@strong{A.} This is a common error when @ccmode{} hasn't been compiled
-correctly, especially under Emacs 19.34@footnote{Technically, it's
-because some macros wasn't defined during the compilation, so the byte
-compiler put in function calls instead of the macro expansions. Later,
-when the interpreter tries to call the macros as functions, it shows
-this (somewhat cryptic) error message.}. If you are using the standalone
+@item
+@kindex M-a
+@kindex M-e
+@emph{@kbd{M-a} and @kbd{M-e} used to move over entire balanced brace
+lists, but now they move into blocks. How do I get the old behavior
+back?}
+
+Use @kbd{C-M-f} and @kbd{C-M-b} to move over balanced brace blocks. Use
+@kbd{M-a} and @kbd{M-e} to move by statements, which will also move into
+blocks.
+
+@item
+@emph{Whenever I try to indent a line or type an ``electric'' key such
+as @kbd{;}, @kbd{@{}, or @kbd{@}}, I get an error that look like this:
+@code{Invalid function: (macro . #[...}. What gives?}
+
+This is a common error when @ccmode{} hasn't been compiled correctly,
+especially under Emacs 19.34@footnote{Technically, it's because some
+macro wasn't defined during the compilation, so the byte compiler put
+in function calls instead of the macro expansions. Later, when the
+interpreter tries to call the macro as a function, it shows this
+(somewhat cryptic) error message.}. If you are using the standalone
@ccmode{} distribution, try recompiling it according to the instructions
in the @file{README} file.
-
-@end quotation
+@end itemize
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@@ -4436,48 +5493,37 @@ in the @file{README} file.
@appendix Getting the Latest CC Mode Release
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@ccmode{} is standard with all versions of Emacs since 19.34 and of
-XEmacs since 19.16.
+@ccmode{} has been standard with all versions of Emacs since 19.34 and
+of XEmacs since 19.16.
+@cindex web site
Due to release schedule skew, it is likely that all of these Emacsen
have old versions of @ccmode{} and so should be upgraded. Access to the
@ccmode{} source code, as well as more detailed information on Emacsen
-compatibility, etc. are all available via the Web at:
-
-@example
-@group
-
- @uref{http://cc-mode.sourceforge.net/}
+compatibility, etc. are all available on the web site:
-@end group
-@end example
-
-@emph{Old URLs, including the FTP URLs, should no longer be used.}
-
-There are many files under these directories; you can pick up the entire
-distribution (named @code{cc-mode.tar.gz}; a gzip'd tar file), or any of
-the individual files, including PostScript documentation.
+@quotation
+@uref{http://cc-mode.sourceforge.net/}
+@end quotation
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@node Mailing Lists and Submitting Bug Reports, Sample .emacs File, Getting the Latest CC Mode Release, Top
@comment node-name, next, previous, up
@appendix Mailing Lists and Submitting Bug Reports
-@cindex mailing lists
-@cindex reporting bugs
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@kindex C-c C-b
@findex c-submit-bug-report
@findex submit-bug-report (c-)
-To report bugs, use the @kbd{C-c C-b} (@code{c-submit-bug-report})
-command. This provides vital information we need to reproduce your
-problem. Make sure you include a concise, but complete code example.
-Please try to boil your example down to just the essential code needed
-to reproduce the problem, and include an exact recipe of steps needed to
-expose the bug. Be especially sure to include any code that appears
-@emph{before} your bug example, if you think it might affect our ability
-to reproduce it.
+To report bugs, use the @kbd{C-c C-b} (bound to
+@code{c-submit-bug-report}) command. This provides vital information
+we need to reproduce your problem. Make sure you include a concise,
+but complete code example. Please try to boil your example down to
+just the essential code needed to reproduce the problem, and include
+an exact recipe of steps needed to expose the bug. Be especially sure
+to include any code that appears @emph{before} your bug example, if
+you think it might affect our ability to reproduce it.
Please try to produce the problem in an Emacs instance without any
customizations loaded (i.e. start it with the @code{-q -no-site-file}
@@ -4487,30 +5533,30 @@ that case, we'd appreciate if you isolate the Emacs Lisp code that trigs
the bug and include it in your report.
@cindex bug report mailing list
-Bug reports are now sent to the following email addresses:
-@email{bug-cc-mode@@gnu.org} and @email{bug-gnu-emacs@@gnu.org}; the
-latter is mirrored on the Usenet newsgroup @code{gnu.emacs.bug}. You
-can send other questions and suggestions (kudos? @t{;-)} to
-@email{bug-cc-mode@@gnu.org}.
+Bug reports are sent to @email{bug-cc-mode@@gnu.org}. You can also send
+other questions and suggestions (kudos? @t{;-)} to that address. It's a
+mailing list which you can join or browse an archive of; see the web
+site at @uref{http://cc-mode.sourceforge.net/} for further details.
@cindex announcement mailing list
If you want to get announcements of new @ccmode{} releases, send the
word @emph{subscribe} in the body of a message to
-@email{cc-mode-announce-request@@lists.sourceforge.net}. Announcements
-will also be posted to the Usenet newsgroups @code{gnu.emacs.sources},
-@code{comp.emacs} and @code{comp.emacs.xemacs}.
+@email{cc-mode-announce-request@@lists.sourceforge.net}. It's possible
+to subscribe from the web site too. Announcements will also be posted
+to the Usenet newsgroups @code{gnu.emacs.sources}, @code{comp.emacs} and
+@code{comp.emacs.xemacs}.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Sample .emacs File, Concept Index, Mailing Lists and Submitting Bug Reports, Top
+@node Sample .emacs File, Command and Function Index, Mailing Lists and Submitting Bug Reports, Top
@comment node-name, next, previous, up
@appendix Sample .emacs file
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
@example
-;; Here's a sample .emacs file that might help you along the way. Just
-;; copy this region and paste it into your .emacs file. You may want to
-;; change some of the actual values.
+;; Here's a sample .emacs file that might help you along the way.
+;; Just copy this region and paste it into your .emacs file. You may
+;; want to change some of the actual values.
(defconst my-c-style
'((c-tab-always-indent . t)
@@ -4530,8 +5576,7 @@ will also be posted to the Usenet newsgroups @code{gnu.emacs.sources},
(case-label . 4)
(block-open . 0)
(knr-argdecl-intro . -)))
- (c-echo-syntactic-information-p . t)
- )
+ (c-echo-syntactic-information-p . t))
"My C Programming Style")
;; offset customizations not in my-c-style
@@ -4550,60 +5595,55 @@ will also be posted to the Usenet newsgroups @code{gnu.emacs.sources},
;; key bindings for all supported languages. We can put these in
;; c-mode-base-map because c-mode-map, c++-mode-map, objc-mode-map,
;; java-mode-map, idl-mode-map, and pike-mode-map inherit from it.
- (define-key c-mode-base-map "\C-m" 'c-context-line-break)
- )
+ (define-key c-mode-base-map "\C-m" 'c-context-line-break))
(add-hook 'c-mode-common-hook 'my-c-mode-common-hook)
@end example
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Concept Index, Command Index, Sample .emacs File, Top
+@node Command and Function Index, Variable Index, Sample .emacs File, Top
@comment node-name, next, previous, up
-@unnumbered Concept Index
+@unnumbered Command and Function Index
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@printindex cp
+Since most @ccmode{} commands are prepended with the string
+@samp{c-}, each appears under its @code{c-@var{thing}} name and its
+@code{@var{thing} (c-)} name.
+@iftex
+@sp 2
+@end iftex
+@printindex fn
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Command Index, Key Index, Concept Index, Top
+@node Variable Index, Concept Index, Command and Function Index, Top
@comment node-name, next, previous, up
-@unnumbered Command Index
+@unnumbered Variable Index
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-Since most @ccmode{} commands are prepended with the string
-@samp{c-}, each appears under its @code{c-@var{<thing>}} name and its
-@code{@var{<thing>} (c-)} name.
+Since most @ccmode{} variables are prepended with the string
+@samp{c-}, each appears under its @code{c-@var{thing}} name and its
+@code{@var{thing} (c-)} name.
@iftex
@sp 2
@end iftex
-@printindex fn
+@printindex vr
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Key Index, Variable Index, Command Index, Top
+@node Concept Index, , Variable Index, Top
@comment node-name, next, previous, up
-@unnumbered Key Index
+@unnumbered Concept Index
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@printindex ky
+@printindex cp
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@node Variable Index, , Key Index, Top
-@comment node-name, next, previous, up
-@unnumbered Variable Index
+@comment Epilogue.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-Since most @ccmode{} variables are prepended with the string
-@samp{c-}, each appears under its @code{c-@var{<thing>}} name and its
-@code{@var{<thing>} (c-)} name.
-@iftex
-@sp 2
-@end iftex
-@printindex vr
-
@iftex
@page
@summarycontents
@@ -4611,3 +5651,7 @@ Since most @ccmode{} variables are prepended with the string
@end iftex
@bye
+
+@ignore
+ arch-tag: c4cab162-5e57-4366-bdce-4a9db2fc97f0
+@end ignore
diff --git a/man/cl.texi b/man/cl.texi
index eebd3ae4b5f..bc4db1cb927 100644
--- a/man/cl.texi
+++ b/man/cl.texi
@@ -50,7 +50,7 @@ license to the document, as described in section 6 of the license.
@end titlepage
@node Top, Overview, (dir), (dir)
-@chapter Common Lisp Extensions
+@chapter Overview
@noindent
This document describes a set of Emacs Lisp facilities borrowed from
@@ -3127,7 +3127,7 @@ and declare it inline all at once.
(defsubst foo (...) ...) ; instead of defun
@end example
-@strong{Note:} This declaration remains in effect after the
+@strong{Please note:} this declaration remains in effect after the
containing source file is done. It is correct to use it to
request that a function you have defined should be inlined,
but it is impolite to use it to request inlining of an external
@@ -5361,3 +5361,7 @@ recursion.
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: b61e7200-3bfa-4a70-a9d3-095e152696f8
+@end ignore
diff --git a/man/cmdargs.texi b/man/cmdargs.texi
index 7545f9baf76..3daf96f0d00 100644
--- a/man/cmdargs.texi
+++ b/man/cmdargs.texi
@@ -1,5 +1,5 @@
@c This is part of the Emacs manual.
-@c Copyright (C) 1985,86,87,93,94,95,1997,2001, 2003 Free Software Foundation, Inc.
+@c Copyright (C) 1985,86,87,93,94,95,97,2001,03,2004 Free Software Foundation, Inc.
@c See file emacs.texi for copying conditions.
@node Command Arguments, X Resources, Service, Top
@appendix Command Line Arguments
@@ -46,27 +46,33 @@ and the tables below always show an equal sign.
@cindex initial options (command line)
@cindex action options (command line)
+@vindex command-line-args
Most options specify how to initialize Emacs, or set parameters for
the Emacs session. We call them @dfn{initial options}. A few options
specify things to do: for example, load libraries, call functions, or
terminate Emacs. These are called @dfn{action options}. These and file
names together are called @dfn{action arguments}. Emacs processes all
-the action arguments in the order they are written.
+the action arguments in the order they are written. The @file{.emacs} file
+can access the values of the action arguments as the elements of a list in
+the variable @code{command-line-args}.
+
+
@menu
-* Action Arguments:: Arguments to visit files, load libraries,
- and call functions.
+* Action Arguments:: Arguments to visit files, load libraries,
+ and call functions.
* Initial Options:: Arguments that take effect while starting Emacs.
* Command Example:: Examples of using command line arguments.
-* Resume Arguments:: Specifying arguments when you resume a running Emacs.
+* Resume Arguments:: Specifying arguments when you resume a running Emacs.
* Environment:: Environment variables that Emacs uses.
* Display X:: Changing the default display and using remote login.
-* Font X:: Choosing a font for text, under X.
-* Colors:: Choosing display colors.
+* Font X:: Choosing a font for text, under X.
+* Colors:: Choosing display colors.
* Window Size X:: Start-up window size, under X.
-* Borders X:: Internal and external borders, under X.
+* Borders X:: Internal and external borders, under X.
* Title X:: Specifying the initial frame's title.
* Icons X:: Choosing what sort of icon to use, under X.
+* Misc X:: Other display options.
@end menu
@node Action Arguments
@@ -76,10 +82,12 @@ the action arguments in the order they are written.
@table @samp
@item @var{file}
-@opindex --visit
-@itemx --visit=@var{file}
@opindex --file
@itemx --file=@var{file}
+@opindex --find-file
+@itemx --find-file=@var{file}
+@opindex --visit
+@itemx --visit=@var{file}
@cindex visiting files, command-line argument
@vindex inhibit-startup-buffer-menu
Visit @var{file} using @code{find-file}. @xref{Visiting}.
@@ -107,12 +115,21 @@ Load a Lisp library named @var{file} with the function @code{load}.
directory, or in the Emacs library search path as specified
with @env{EMACSLOADPATH} (@pxref{General Variables}).
+@item -L @var{dir}
+@opindex -L
+@itemx --directory=@var{dir}
+@opindex --directory
+Add directory @var{dir} to the variable @code{load-path}.
+
@item -f @var{function}
@opindex -f
@itemx --funcall=@var{function}
@opindex --funcall
@cindex call Lisp functions, command-line argument
-Call Lisp function @var{function} with no arguments.
+Call Lisp function @var{function}. If it is an interactive function
+(a command), it reads the arguments interactively just as if you had
+called the same function with a key sequence. Otherwise, it calls the
+function with no arguments.
@item --eval=@var{expression}
@opindex --eval
@@ -130,13 +147,16 @@ what @kbd{M-x insert-file} does. @xref{Misc File Ops}.
@item --kill
@opindex --kill
Exit from Emacs without asking for confirmation.
-@end table
-@vindex command-line-args
- The init file can access the values of the action arguments as the
-elements of a list in the variable @code{command-line-args}. The init
-file can override the normal processing of the action arguments, or
-define new ones, by reading and setting this variable.
+@item --help
+@opindex --help
+Print a usage message listing all available options, then exit
+successfully.
+
+@item --version
+@opindex --version
+Print Emacs version, then exit successfully.
+@end table
@node Initial Options
@appendixsec Initial Options
@@ -159,6 +179,7 @@ of these files or substitute other files for them.
@opindex --terminal
@cindex device for Emacs terminal I/O
Use @var{device} as the device for terminal input and output.
+@samp{--terminal} implies @samp{--no-window-system}.
@item -d @var{display}
@opindex -d
@@ -202,6 +223,7 @@ been explicitly requested.
@item --script @var{file}
@opindex --script
+@cindex script mode
Run Emacs in batch mode, like @samp{--batch}, and then read and
execute the Lisp code in @var{file}.
@@ -221,11 +243,12 @@ comment delimiter.
@opindex -q
@itemx --no-init-file
@opindex --no-init-file
-@cindex bypassing init and site-start file
+@cindex bypassing init and @file{default.el} file
@cindex init file, not loading
@cindex @file{default.el} file, not loading
Do not load your Emacs init file @file{~/.emacs}, or @file{default.el}
-either. When invoked like this, Emacs does not allow saving options
+either. Regardless of this switch, @file{site-start.el} is still loaded.
+When invoked like this, Emacs does not allow saving options
changed with the @kbd{M-x customize} command and its variants.
@xref{Easy Customization}.
@@ -233,7 +256,7 @@ changed with the @kbd{M-x customize} command and its variants.
@opindex --no-site-file
@cindex @file{site-start.el} file, not loading
Do not load @file{site-start.el}. The options @samp{-q}, @samp{-u}
-and @samp{-batch} have no effect on the loading of this file---this is
+and @samp{--batch} have no effect on the loading of this file---this is
the only option that blocks it.
@item --no-splash
@@ -242,6 +265,10 @@ the only option that blocks it.
Do not display a splash screen on startup; this is equivalent to
setting the variable @code{inhibit-startup-message} to non-@code{nil}.
+@item --no-desktop
+@opindex --no-desktop
+Do not reload any saved desktop. @xref{Saving Emacs Sessions}.
+
@item -u @var{user}
@opindex -u
@itemx --user=@var{user}
@@ -257,6 +284,8 @@ Enable the Emacs Lisp debugger for errors in the init file.
@item --unibyte
@opindex --unibyte
+@itemx --no-multibyte
+@opindex --no-multibyte
@cindex unibyte operation, command-line argument
Do almost everything with single-byte buffers and strings.
All buffers and strings are unibyte unless you (or a Lisp program)
@@ -267,6 +296,8 @@ variable @env{EMACS_UNIBYTE} has the same effect.
@item --multibyte
@opindex --multibyte
+@itemx --no-unibyte
+@opindex --no-unibyte
Inhibit the effect of @env{EMACS_UNIBYTE}, so that Emacs
uses multibyte characters by default, as usual.
@end table
@@ -287,7 +318,7 @@ emacs -batch foo.c -l hack-c -f save-buffer >& log
This says to visit @file{foo.c}, load @file{hack-c.el} (which makes
changes in the visited file), save @file{foo.c} (note that
@code{save-buffer} is the function that @kbd{C-x C-s} is bound to), and
-then exit back to the shell (because of @samp{-batch}). @samp{-batch}
+then exit back to the shell (because of @samp{--batch}). @samp{--batch}
also guarantees there will be no problem redirecting output to
@file{log}, because Emacs will not assume that it has a display terminal
to work with.
@@ -469,9 +500,6 @@ environment and coding system. @xref{Language Environments}.
The user's login name. See also @env{USER}.
@item MAIL
The name of the user's system mail inbox.
-@item MAILRC
-Name of file containing mail aliases. (The default is
-@file{~/.mailrc}.)
@item MH
Name of setup file for the mh system. (The default is @file{~/.mh_profile}.)
@item NAME
@@ -671,7 +699,7 @@ emacs --display=glasperle:0 &
@end smallexample
You can inhibit the direct use of the window system and GUI with the
-@samp{-nw} option. It tells Emacs to display using ordinary ASCII on
+@samp{-nw} option. It tells Emacs to display using ordinary @acronym{ASCII} on
its controlling terminal. This is also an initial option.
Sometimes, security arrangements prevent a program on a remote system
@@ -691,11 +719,10 @@ remote machine.
@appendixsec Font Specification Options
@cindex font name (X Window System)
- By default, Emacs displays text in the font named @samp{9x15}, which
-makes each character nine pixels wide and fifteen pixels high. You can
-specify a different font on your command line through the option
-@samp{-fn @var{name}} (or @samp{--font}, which is an alias for
-@samp{-fn}).
+ By default, Emacs displays text in a twelve point Courier font (when
+using X). You can specify a different font on your command line
+through the option @samp{-fn @var{name}} (or @samp{--font}, which is
+an alias for @samp{-fn}).
@table @samp
@item -fn @var{name}
@@ -706,12 +733,19 @@ specify a different font on your command line through the option
Use font @var{name} as the default font.
@end table
- Under X, each font has a long name which consists of eleven words or
-numbers, separated by dashes. Some fonts also have shorter
-nicknames---@samp{9x15} is such a nickname. You can use either kind of
-name. You can use wildcard patterns for the font name; then Emacs lets
-X choose one of the fonts that match the pattern. Here is an example,
-which happens to specify the font whose nickname is @samp{6x13}:
+ Under X, each font has a long name which consists of fourteen words
+or numbers, separated by dashes. Some fonts also have shorter
+nicknames. For instance, @samp{9x15} is such a nickname. This font
+makes each character nine pixels wide and fifteen pixels high. You
+can use either kind of name. Case is insignificant in both kinds.
+You can use wildcard patterns for the font name; then Emacs lets X
+choose one of the fonts that match the pattern. The wildcard
+character @samp{*} matches any sequence of characters (including none)
+and @samp{?} matches any single character. However, matching is
+implementation-dependent, and can be inaccurate when wildcards match
+dashes in a long name. For reliable results, supply all 14 dashes and
+use wildcards only within a field. Here is an example, which happens
+to specify the font whose nickname is @samp{6x13}:
@smallexample
emacs -fn \
@@ -725,11 +759,23 @@ You can also specify the font in your @file{.Xdefaults} file:
emacs.font: -misc-fixed-medium-r-semicondensed--13-*-*-*-c-60-iso8859-1
@end smallexample
+ Note that if you use a wildcard pattern on the command line, you
+need to enclose it in single or double quotes, to prevent the shell
+from accidentally expanding it into a list of file names. On the
+other hand, you should not quote the name in the @file{.Xdefaults}
+file.
+
+The default font used by Emacs (under X) is:
+
+@smallexample
+-adobe-courier-medium-r-*-*-*-120-*-*-*-*-iso8859-1
+@end smallexample
+
A long font name has the following form:
@smallexample
-@var{maker}-@var{family}-@var{weight}-@var{slant}-@var{widthtype}-@var{style}@dots{}
-@dots{}-@var{pixels}-@var{height}-@var{horiz}-@var{vert}-@var{spacing}-@var{width}-@var{charset}
+@dots{}-@var{pixels}-@var{height}-@var{horiz}-@var{vert}-@var{spacing}-@var{width}-@var{registry}-@var{encoding}
@end smallexample
@table @var
@@ -770,9 +816,14 @@ This is @samp{m} (monospace), @samp{p} (proportional) or @samp{c}
(character cell).
@item width
This is the average character width, in pixels, multiplied by ten.
-@item charset
-This is the character set that the font depicts.
-Normally you should use @samp{iso8859-1}.
+@item registry
+@itemx encoding
+These together make up the X font character set that the font depicts.
+(X font character sets are not the same as Emacs charsets, but they
+are solutions for the same problem.) You can use the
+@command{xfontsel} program to check which choices you have. However,
+normally you should use @samp{iso8859} for @var{registry} and @samp{1}
+for @var{encoding}.
@end table
@cindex listing system fonts
@@ -921,14 +972,13 @@ position of the initial Emacs frame:
@table @samp
@item -g @var{width}x@var{height}@r{[@{}+-@r{@}}@var{xoffset}@r{@{}+-@r{@}}@var{yoffset}@r{]]}
@opindex -g
+@itemx --geometry=@var{width}x@var{height}@r{[@{}+-@r{@}}@var{xoffset}@r{@{}+-@r{@}}@var{yoffset}@r{]]}
+@opindex --geometry
+@cindex geometry, command-line argument
Specify the size @var{width} and @var{height} (measured in character
columns and lines), and positions @var{xoffset} and @var{yoffset}
(measured in pixels). This applies to all frames.
-@item --geometry=@var{width}x@var{height}@r{[@{}+-@r{@}}@var{xoffset}@r{@{}+-@r{@}}@var{yoffset}@r{]]}
-@opindex --geometry
-This is another way of writing the same thing.
-
@item -fs
@opindex -fs
@itemx --fullscreen
@@ -1006,7 +1056,7 @@ specification assuming there is a tool bar, and then your
@file{~/.emacs} file disables the tool bar, you will end up with a
frame geometry different from what you asked for. To get the intended
size with no tool bar, use an X resource to specify ``no tool bar''
-(@pxref{Table of Resources});then Emacs will already know there's no
+(@pxref{Table of Resources}); then Emacs will already know there's no
tool bar when it processes the specified geometry.
When using one of @samp{--fullscreen}, @samp{--fullwidth} or
@@ -1034,13 +1084,15 @@ you can click on to move or iconify the window.
@opindex -ib
@itemx --internal-border=@var{width}
@opindex --internal-border
-@cindex border width, command-line argument
-Specify @var{width} as the width of the internal border, in pixels.
+@cindex internal border width, command-line argument
+Specify @var{width} as the width of the internal border (between the text
+and the main border), in pixels.
@item -bw @var{width}
@opindex -bw
@itemx --border-width=@var{width}
@opindex --border-width
+@cindex main border width, command-line argument
Specify @var{width} as the width of the main border, in pixels.
@end table
@@ -1068,11 +1120,10 @@ there is more than one frame).
line option:
@table @samp
-@item -title @var{title}
-@opindex --title
-@itemx --title=@var{title}
-@itemx -T @var{title}
+@item -T @var{title}
@opindex -T
+@itemx --title=@var{title}
+@opindex --title
@cindex frame title, command-line argument
Specify @var{title} as the title for the initial Emacs frame.
@end table
@@ -1114,3 +1165,36 @@ rectangle containing the frame's title.
rather than showing a frame right away. In this situation, the icon
is the only indication that Emacs has started; the text frame doesn't
appear until you deiconify it.
+
+@node Misc X
+@appendixsec Other Display Options
+
+@table @samp
+@item -hb
+@opindex -hb
+@itemx --horizontal-scroll-bars
+@opindex --horizontal-scroll-bars
+@cindex horizontal scroll bars, command-line argument
+Enable horizontal scroll bars.
+
+@item -vb
+@opindex -vb
+@itemx --vertical-scroll-bars
+@opindex --vertical-scroll-bars
+@cindex vertical scroll bars, command-line argument
+Enable vertical scroll bars.
+
+@item -lsp @var{pixels}
+@opindex -lsp
+@itemx --line-spacing=@var{pixels}
+@opindex --line-spacing
+@cindex line spacing, command-line argument
+Specify @var{pixels} as additional space to put between lines, in pixels.
+@end table
+
+ The @samp{--xrm} option (@pxref{Resources}) specifies additional
+X resource values.
+
+@ignore
+ arch-tag: fffecd9e-7329-4a51-a3cc-dd4a9889340e
+@end ignore
diff --git a/man/commands.texi b/man/commands.texi
index b0727cfa1e4..ea14e36128a 100644
--- a/man/commands.texi
+++ b/man/commands.texi
@@ -15,33 +15,33 @@ how Emacs interprets your keyboard and mouse input.
@cindex input with the keyboard
@cindex keyboard input
@cindex character set (keyboard)
-@cindex ASCII
+@cindex @acronym{ASCII}
@cindex C-
@cindex Control
@cindex control characters
- GNU Emacs uses an extension of the ASCII character set for keyboard
+ GNU Emacs uses an extension of the @acronym{ASCII} character set for keyboard
input; it also accepts non-character input events including function
keys and mouse button actions.
- ASCII consists of 128 character codes. Some of these codes are
+ @acronym{ASCII} consists of 128 character codes. Some of these codes are
assigned graphic symbols such as @samp{a} and @samp{=}; the rest are
control characters, such as @kbd{Control-a} (usually written @kbd{C-a}
for short). @kbd{C-a} gets its name from the fact that you type it by
holding down the @key{CTRL} key while pressing @kbd{a}.
- Some ASCII control characters have special names, and most terminals
+ Some @acronym{ASCII} control characters have special names, and most terminals
have special keys you can type them with: for example, @key{RET},
@key{TAB}, @key{DEL} and @key{ESC}. The space character is usually
referred to below as @key{SPC}, even though strictly speaking it is a
graphic character whose graphic happens to be blank. Some keyboards
have a key labeled ``linefeed'' which is an alias for @kbd{C-j}.
- Emacs extends the ASCII character set with thousands more printing
+ Emacs extends the @acronym{ASCII} character set with thousands more printing
characters (@pxref{International}), additional control characters, and a
few more modifiers that can be combined with any character.
- On ASCII terminals, there are only 32 possible control characters.
+ On @acronym{ASCII} terminals, there are only 32 possible control characters.
These are the control variants of letters and @samp{@@[]\^_}. In
addition, the shift key is meaningless with control characters:
@kbd{C-a} and @kbd{C-A} are the same character, and Emacs cannot
@@ -117,8 +117,8 @@ Reference Manual}, for more information. If you are not doing Lisp
programming, but simply want to redefine the meaning of some characters
or non-character events, see @ref{Customization}.
- ASCII terminals cannot really send anything to the computer except
-ASCII characters. These terminals use a sequence of characters to
+ @acronym{ASCII} terminals cannot really send anything to the computer except
+@acronym{ASCII} characters. These terminals use a sequence of characters to
represent each function key. But that is invisible to the Emacs user,
because the keyboard input routines recognize these special sequences
and convert them to function key events before any other part of Emacs
@@ -243,25 +243,29 @@ variables will make sense. @xref{Variables}.
@cindex characters (in text)
Text in Emacs buffers is a sequence of 8-bit bytes. Each byte can
-hold a single ASCII character. Both ASCII control characters (octal
-codes 000 through 037, and 0177) and ASCII printing characters (codes
-040 through 0176) are allowed; however, non-ASCII control characters
+hold a single @acronym{ASCII} character. Both @acronym{ASCII} control characters (octal
+codes 000 through 037, and 0177) and @acronym{ASCII} printing characters (codes
+040 through 0176) are allowed; however, non-@acronym{ASCII} control characters
cannot appear in a buffer. The other modifier flags used in keyboard
input, such as Meta, are not allowed in buffers either.
- Some ASCII control characters serve special purposes in text, and have
+ Some @acronym{ASCII} control characters serve special purposes in text, and have
special names. For example, the newline character (octal code 012) is
used in the buffer to end a line, and the tab character (octal code 011)
is used for indenting to the next tab stop column (normally every 8
columns). @xref{Text Display}.
- Non-ASCII printing characters can also appear in buffers. When
-multibyte characters are enabled, you can use any of the non-ASCII
+ Non-@acronym{ASCII} printing characters can also appear in buffers. When
+multibyte characters are enabled, you can use any of the non-@acronym{ASCII}
printing characters that Emacs supports. They have character codes
starting at 256, octal 0400, and each one is represented as a sequence
of two or more bytes. @xref{International}. Single-byte characters
with codes 128 through 255 can also appear in multibyte buffers.
If you disable multibyte characters, then you can use only one
-alphabet of non-ASCII characters, but they all fit in one byte. They
+alphabet of non-@acronym{ASCII} characters, but they all fit in one byte. They
use codes 0200 through 0377. @xref{Single-Byte Character Support}.
+
+@ignore
+ arch-tag: 9be43eef-d1f4-4d03-a916-c741ea713a45
+@end ignore
diff --git a/man/custom.texi b/man/custom.texi
index 4a89f8f086b..ab29bd83e09 100644
--- a/man/custom.texi
+++ b/man/custom.texi
@@ -19,15 +19,17 @@ between sessions unless you save the customization in a file such as
customizations for future sessions, this actually works by editing
@file{.emacs} for you.
+ Another means of customization is the keyboard macro, which is a
+sequence of keystrokes to be replayed with a single command.
+@xref{Keyboard Macros}, for full instruction how to record, manage, and
+replay sequences of keys.
+
@menu
* Minor Modes:: Each minor mode is one feature you can turn on
independently of any others.
* Variables:: Many Emacs commands examine Emacs variables
to decide what to do; by setting variables,
you can control their functioning.
-* Keyboard Macros:: A keyboard macro records a sequence of
- keystrokes to be replayed with a single
- command.
* Key Bindings:: The keymaps say what command each key runs.
By changing them, you can "redefine keys".
* Keyboard Translations::
@@ -1058,230 +1060,11 @@ value are @code{t}, @code{nil}, and anything else, just as for
neither @code{t} nor @code{nil}, so normally Emacs does ask for
confirmation about file settings for these variables.
-@node Keyboard Macros
-@section Keyboard Macros
-
-@cindex defining keyboard macros
-@cindex keyboard macro
- A @dfn{keyboard macro} is a command defined by the user to stand for
-another sequence of keys. For example, if you discover that you are
-about to type @kbd{C-n C-d} forty times, you can speed your work by
-defining a keyboard macro to do @kbd{C-n C-d} and calling it with a
-repeat count of forty.
-
-@table @kbd
-@item C-x (
-Start defining a keyboard macro (@code{start-kbd-macro}).
-@item C-x )
-End the definition of a keyboard macro (@code{end-kbd-macro}).
-@item C-x e
-Execute the most recent keyboard macro (@code{call-last-kbd-macro}).
-@item C-u C-x (
-Re-execute last keyboard macro, then add more keys to its definition.
-@item C-x q
-When this point is reached during macro execution, ask for confirmation
-(@code{kbd-macro-query}).
-@item M-x name-last-kbd-macro
-Give a command name (for the duration of the session) to the most
-recently defined keyboard macro.
-@item M-x insert-kbd-macro
-Insert in the buffer a keyboard macro's definition, as Lisp code.
-@item C-x C-k
-Edit a previously defined keyboard macro (@code{edit-kbd-macro}).
-@item M-x apply-macro-to-region-lines
-Run the last keyboard macro on each complete line in the region.
-@end table
-
- Keyboard macros differ from ordinary Emacs commands in that they are
-written in the Emacs command language rather than in Lisp. This makes it
-easier for the novice to write them, and makes them more convenient as
-temporary hacks. However, the Emacs command language is not powerful
-enough as a programming language to be useful for writing anything
-intelligent or general. For such things, Lisp must be used.
-
- You define a keyboard macro while executing the commands which are the
-definition. Put differently, as you define a keyboard macro, the
-definition is being executed for the first time. This way, you can see
-what the effects of your commands are, so that you don't have to figure
-them out in your head. When you are finished, the keyboard macro is
-defined and also has been, in effect, executed once. You can then do the
-whole thing over again by invoking the macro.
-
-@menu
-* Basic Kbd Macro:: Defining and running keyboard macros.
-* Save Kbd Macro:: Giving keyboard macros names; saving them in files.
-* Kbd Macro Query:: Making keyboard macros do different things each time.
-@end menu
-
-@node Basic Kbd Macro
-@subsection Basic Use
-
-@kindex C-x (
-@kindex C-x )
-@kindex C-x e
-@findex start-kbd-macro
-@findex end-kbd-macro
-@findex call-last-kbd-macro
- To start defining a keyboard macro, type the @kbd{C-x (} command
-(@code{start-kbd-macro}). From then on, your keys continue to be
-executed, but also become part of the definition of the macro. @samp{Def}
-appears in the mode line to remind you of what is going on. When you are
-finished, the @kbd{C-x )} command (@code{end-kbd-macro}) terminates the
-definition (without becoming part of it!). For example,
-
-@example
-C-x ( M-f foo C-x )
-@end example
-
-@noindent
-defines a macro to move forward a word and then insert @samp{foo}.
-
- The macro thus defined can be invoked again with the @kbd{C-x e}
-command (@code{call-last-kbd-macro}), which may be given a repeat count
-as a numeric argument to execute the macro many times. @kbd{C-x )} can
-also be given a repeat count as an argument, in which case it repeats
-the macro that many times right after defining it, but defining the
-macro counts as the first repetition (since it is executed as you define
-it). Therefore, giving @kbd{C-x )} an argument of 4 executes the macro
-immediately 3 additional times. An argument of zero to @kbd{C-x e} or
-@kbd{C-x )} means repeat the macro indefinitely (until it gets an error
-or you type @kbd{C-g} or, on MS-DOS, @kbd{C-@key{BREAK}}).
-
- If you wish to repeat an operation at regularly spaced places in the
-text, define a macro and include as part of the macro the commands to move
-to the next place you want to use it. For example, if you want to change
-each line, you should position point at the start of a line, and define a
-macro to change that line and leave point at the start of the next line.
-Then repeating the macro will operate on successive lines.
-
- When a command reads an argument with the minibuffer, your
-minibuffer input becomes part of the macro along with the command. So
-when you replay the macro, the command gets the same argument as
-when you entered the macro. For example,
-
-@example
-C-x ( C-a C-@key{SPC} C-n M-w C-x b f o o @key{RET} C-y C-x b @key{RET} C-x )
-@end example
-
-@noindent
-defines a macro that copies the current line into the buffer
-@samp{foo}, then returns to the original buffer.
-
- You can use function keys in a keyboard macro, just like keyboard
-keys. You can even use mouse events, but be careful about that: when
-the macro replays the mouse event, it uses the original mouse position
-of that event, the position that the mouse had while you were defining
-the macro. The effect of this may be hard to predict. (Using the
-current mouse position would be even less predictable.)
-
- One thing that doesn't always work well in a keyboard macro is the
-command @kbd{C-M-c} (@code{exit-recursive-edit}). When this command
-exits a recursive edit that started within the macro, it works as you'd
-expect. But if it exits a recursive edit that started before you
-invoked the keyboard macro, it also necessarily exits the keyboard macro
-as part of the process.
-
- After you have terminated the definition of a keyboard macro, you can add
-to the end of its definition by typing @kbd{C-u C-x (}. This is equivalent
-to plain @kbd{C-x (} followed by retyping the whole definition so far. As
-a consequence it re-executes the macro as previously defined.
-
-@findex edit-kbd-macro
-@kindex C-x C-k
- You can edit a keyboard macro already defined by typing @kbd{C-x C-k}
-(@code{edit-kbd-macro}). Follow that with the keyboard input that you
-would use to invoke the macro---@kbd{C-x e} or @kbd{M-x @var{name}} or
-some other key sequence. This formats the macro definition in a buffer
-and enters a specialized major mode for editing it. Type @kbd{C-h m}
-once in that buffer to display details of how to edit the macro. When
-you are finished editing, type @kbd{C-c C-c}.
-
-@findex apply-macro-to-region-lines
- The command @kbd{M-x apply-macro-to-region-lines} repeats the last
-defined keyboard macro on each complete line within the current region.
-It does this line by line, by moving point to the beginning of the line
-and then executing the macro.
-
-@node Save Kbd Macro
-@subsection Naming and Saving Keyboard Macros
-
-@cindex saving keyboard macros
-@findex name-last-kbd-macro
- If you wish to save a keyboard macro for longer than until you define the
-next one, you must give it a name using @kbd{M-x name-last-kbd-macro}.
-This reads a name as an argument using the minibuffer and defines that name
-to execute the macro. The macro name is a Lisp symbol, and defining it in
-this way makes it a valid command name for calling with @kbd{M-x} or for
-binding a key to with @code{global-set-key} (@pxref{Keymaps}). If you
-specify a name that has a prior definition other than another keyboard
-macro, an error message is shown and nothing is changed.
-
-@findex insert-kbd-macro
- Once a macro has a command name, you can save its definition in a file.
-Then it can be used in another editing session. First, visit the file
-you want to save the definition in. Then use this command:
-
-@example
-M-x insert-kbd-macro @key{RET} @var{macroname} @key{RET}
-@end example
-
-@noindent
-This inserts some Lisp code that, when executed later, will define the
-same macro with the same definition it has now. (You need not
-understand Lisp code to do this, because @code{insert-kbd-macro} writes
-the Lisp code for you.) Then save the file. You can load the file
-later with @code{load-file} (@pxref{Lisp Libraries}). If the file you
-save in is your init file @file{~/.emacs} (@pxref{Init File}) then the
-macro will be defined each time you run Emacs.
-
- If you give @code{insert-kbd-macro} a numeric argument, it makes
-additional Lisp code to record the keys (if any) that you have bound to the
-keyboard macro, so that the macro will be reassigned the same keys when you
-load the file.
-
-@node Kbd Macro Query
-@subsection Executing Macros with Variations
-
-@kindex C-x q
-@findex kbd-macro-query
- Using @kbd{C-x q} (@code{kbd-macro-query}), you can get an effect
-similar to that of @code{query-replace}, where the macro asks you each
-time around whether to make a change. While defining the macro,
-type @kbd{C-x q} at the point where you want the query to occur. During
-macro definition, the @kbd{C-x q} does nothing, but when you run the
-macro later, @kbd{C-x q} asks you interactively whether to continue.
-
- The valid responses when @kbd{C-x q} asks are @key{SPC} (or @kbd{y}),
-@key{DEL} (or @kbd{n}), @key{RET} (or @kbd{q}), @kbd{C-l} and @kbd{C-r}.
-The answers are the same as in @code{query-replace}, though not all of
-the @code{query-replace} options are meaningful.
-
- These responses include @key{SPC} to continue, and @key{DEL} to skip
-the remainder of this repetition of the macro and start right away with
-the next repetition. @key{RET} means to skip the remainder of this
-repetition and cancel further repetitions. @kbd{C-l} redraws the screen
-and asks you again for a character to say what to do.
-
- @kbd{C-r} enters a recursive editing level, in which you can perform
-editing which is not part of the macro. When you exit the recursive
-edit using @kbd{C-M-c}, you are asked again how to continue with the
-keyboard macro. If you type a @key{SPC} at this time, the rest of the
-macro definition is executed. It is up to you to leave point and the
-text in a state such that the rest of the macro will do what you
-want.@refill
-
- @kbd{C-u C-x q}, which is @kbd{C-x q} with a numeric argument,
-performs a completely different function. It enters a recursive edit
-reading input from the keyboard, both when you type it during the
-definition of the macro, and when it is executed from the macro. During
-definition, the editing you do inside the recursive edit does not become
-part of the macro. During macro execution, the recursive edit gives you
-a chance to do some particularized editing on each repetition.
-@xref{Recursive Edit}.
-
- Another way to vary the behavior of a keyboard macro is to use a
-register as a counter, incrementing it on each repetition of the macro.
-@xref{RegNumbers}.
+@findex safe-local-eval-forms
+ The @code{safe-local-eval-forms} is a customizable list of eval
+forms which are safe to eval, so Emacs should not ask for
+confirmation to evaluate these forms, even if
+@code{enable-local-variables} says to ask for confirmation in general.
@node Key Bindings
@section Customizing Key Bindings
@@ -1304,7 +1087,7 @@ name which usually consists of lower-case letters and hyphens.
* Init Rebinding:: Rebinding keys with your init file, @file{.emacs}.
* Function Keys:: Rebinding terminal function keys.
* Named ASCII Chars:: Distinguishing @key{TAB} from @kbd{C-i}, and so on.
-* Non-ASCII Rebinding:: Rebinding non-ASCII characters such as Latin-1.
+* Non-ASCII Rebinding:: Rebinding non-@acronym{ASCII} characters such as Latin-1.
* Mouse Buttons:: Rebinding mouse buttons in Emacs.
* Disabling:: Disabling a command means confirmation is required
before it can be executed. This is done to protect
@@ -1628,8 +1411,8 @@ command is less work to invoke when you really want to.
you can specify them in your @file{.emacs} file by using their Lisp
syntax. (@xref{Init File}.)
- The simplest method for doing this works for ASCII characters and
-Meta-modified ASCII characters only. This method uses a string to
+ The simplest method for doing this works for @acronym{ASCII} characters and
+Meta-modified @acronym{ASCII} characters only. This method uses a string to
represent the key sequence you want to rebind. For example, here's how
to bind @kbd{C-z} to @code{shell}:
@@ -1659,7 +1442,7 @@ string, you can use the Emacs Lisp escape sequences, @samp{\t},
(global-set-key "\C-x\t" 'indent-rigidly)
@end example
- These examples show how to write some other special ASCII characters
+ These examples show how to write some other special @acronym{ASCII} characters
in strings for key bindings:
@example
@@ -1669,7 +1452,7 @@ in strings for key bindings:
@end example
When the key sequence includes function keys or mouse button events,
-or non-ASCII characters such as @code{C-=} or @code{H-a}, you must use
+or non-@acronym{ASCII} characters such as @code{C-=} or @code{H-a}, you must use
the more general method of rebinding, which uses a vector to specify the
key sequence.
@@ -1681,8 +1464,8 @@ character, write it as a Lisp character constant: @samp{?} followed by
the character as it would appear in a string.
Here are examples of using vectors to rebind @kbd{C-=} (a control
-character not in ASCII), @kbd{C-M-=} (not in ASCII because @kbd{C-=}
-is not), @kbd{H-a} (a Hyper character; ASCII doesn't have Hyper at
+character not in @acronym{ASCII}), @kbd{C-M-=} (not in @acronym{ASCII} because @kbd{C-=}
+is not), @kbd{H-a} (a Hyper character; @acronym{ASCII} doesn't have Hyper at
all), @key{F7} (a function key), and @kbd{C-Mouse-1} (a
keyboard-modified mouse button):
@@ -1713,7 +1496,7 @@ by listing each of the characters within the square brackets that
delimit the vector.
Language and coding systems can cause problems with key bindings
-for non-ASCII characters. @xref{Non-ASCII Rebinding}.
+for non-@acronym{ASCII} characters. @xref{Non-ASCII Rebinding}.
@node Function Keys
@subsection Rebinding Function Keys
@@ -1758,7 +1541,7 @@ given function key on your terminal, type @kbd{C-h c} followed by that
key.
A key sequence which contains function key symbols (or anything but
-ASCII characters) must be a vector rather than a string. The vector
+@acronym{ASCII} characters) must be a vector rather than a string. The vector
syntax uses spaces between the elements, and square brackets around the
whole vector. Thus, to bind function key @samp{f1} to the command
@code{rmail}, write the following:
@@ -1806,10 +1589,10 @@ word:
@end example
@node Named ASCII Chars
-@subsection Named ASCII Control Characters
+@subsection Named @acronym{ASCII} Control Characters
@key{TAB}, @key{RET}, @key{BS}, @key{LFD}, @key{ESC} and @key{DEL}
-started out as names for certain ASCII control characters, used so often
+started out as names for certain @acronym{ASCII} control characters, used so often
that they have special keys of their own. Later, users found it
convenient to distinguish in Emacs between these keys and the ``same''
control characters typed with the @key{CTRL} key.
@@ -1818,25 +1601,25 @@ control characters typed with the @key{CTRL} key.
reports these keys to Emacs. It treats the ``special'' keys as function
keys named @code{tab}, @code{return}, @code{backspace}, @code{linefeed},
@code{escape}, and @code{delete}. These function keys translate
-automatically into the corresponding ASCII characters @emph{if} they
+automatically into the corresponding @acronym{ASCII} characters @emph{if} they
have no bindings of their own. As a result, neither users nor Lisp
programs need to pay attention to the distinction unless they care to.
If you do not want to distinguish between (for example) @key{TAB} and
-@kbd{C-i}, make just one binding, for the ASCII character @key{TAB}
+@kbd{C-i}, make just one binding, for the @acronym{ASCII} character @key{TAB}
(octal code 011). If you do want to distinguish, make one binding for
-this ASCII character, and another for the ``function key'' @code{tab}.
+this @acronym{ASCII} character, and another for the ``function key'' @code{tab}.
- With an ordinary ASCII terminal, there is no way to distinguish
+ With an ordinary @acronym{ASCII} terminal, there is no way to distinguish
between @key{TAB} and @kbd{C-i} (and likewise for other such pairs),
because the terminal sends the same character in both cases.
@node Non-ASCII Rebinding
-@subsection Non-ASCII Characters on the Keyboard
-@cindex rebinding non-ASCII keys
-@cindex non-ASCII keys, binding
+@subsection Non-@acronym{ASCII} Characters on the Keyboard
+@cindex rebinding non-@acronym{ASCII} keys
+@cindex non-@acronym{ASCII} keys, binding
-If your keyboard has keys that send non-ASCII characters, such as
+If your keyboard has keys that send non-@acronym{ASCII} characters, such as
accented letters, rebinding these keys is a bit tricky. There are two
solutions you can use. One is to specify a keyboard coding system,
using @code{set-keyboard-coding-system} (@pxref{Specify Coding}).
@@ -1852,7 +1635,7 @@ Events,,,elisp, The Emacs Lisp Reference Manual}.}, like this:
@noindent
Type @kbd{C-q} followed by the key you want to bind, to insert @var{char}.
-Since this puts a non-ASCII character in the @file{.emacs}, you should
+Since this puts a non-@acronym{ASCII} character in the @file{.emacs}, you should
specify the proper coding system for that file. @xref{Init Syntax}.
Specify the same coding system for the file that you use for your
keyboard.
@@ -2091,8 +1874,8 @@ input processing; the keys that are looked up in keymaps contain the
characters that result from keyboard translation.
On a window system, the keyboard key named @key{DELETE} is a function
-key and is distinct from the ASCII character named @key{DEL}.
-@xref{Named ASCII Chars}. Keyboard translations affect only ASCII
+key and is distinct from the @acronym{ASCII} character named @key{DEL}.
+@xref{Named ASCII Chars}. Keyboard translations affect only @acronym{ASCII}
character input, not function keys; thus, the above example used on a
window system does not affect the @key{DELETE} key. However, the
translation above isn't necessary on window systems, because Emacs can
@@ -2225,17 +2008,17 @@ Backslash and double-quote are the only characters for which backslash
sequences are mandatory.
@samp{\C-} can be used as a prefix for a control character, as in
-@samp{\C-s} for ASCII control-S, and @samp{\M-} can be used as a prefix for
+@samp{\C-s} for @acronym{ASCII} control-S, and @samp{\M-} can be used as a prefix for
a Meta character, as in @samp{\M-a} for @kbd{Meta-A} or @samp{\M-\C-a} for
@kbd{Control-Meta-A}.@refill
@cindex international characters in @file{.emacs}
-@cindex non-ASCII characters in @file{.emacs}
-If you want to include non-ASCII characters in strings in your init
+@cindex non-@acronym{ASCII} characters in @file{.emacs}
+If you want to include non-@acronym{ASCII} characters in strings in your init
file, you should consider putting a @w{@samp{-*-coding:
@var{coding-system}-*-}} tag on the first line which states the coding
system used to save your @file{.emacs}, as explained in @ref{Recognize
-Coding}. This is because the defaults for decoding non-ASCII text might
+Coding}. This is because the defaults for decoding non-@acronym{ASCII} text might
not yet be set up by the time Emacs reads those parts of your init file
which use such strings, possibly leading Emacs to decode those strings
incorrectly.
@@ -2248,7 +2031,7 @@ strings and characters are not interchangeable in Lisp; some contexts
require one and some contexts require the other.
@xref{Non-ASCII Rebinding}, for information about binding commands to
-keys which send non-ASCII characters.
+keys which send non-@acronym{ASCII} characters.
@item True:
@code{t} stands for `true'.
@@ -2510,3 +2293,7 @@ If that user name matches the real user-ID, then Emacs uses @env{HOME};
otherwise, it looks up the home directory corresponding to that user
name in the system's data base of users.
@c LocalWords: backtab
+
+@ignore
+ arch-tag: c68abddb-4410-4fb5-925f-63394e971d93
+@end ignore
diff --git a/man/dired-x.texi b/man/dired-x.texi
index a1172019544..ad7711d10ae 100644
--- a/man/dired-x.texi
+++ b/man/dired-x.texi
@@ -700,6 +700,9 @@ where each @var{command} can either be a string or a lisp expression
that evaluates to a string. If several commands are given, all of
them will temporarily be pushed onto the history.
+If @samp{*} in the shell command, that means to substitute the file
+name.
+
You can set this variable in your @file{~/.emacs}. For example,
to add rules for @samp{.foo} and @samp{.bar} file extensions, write
@@ -1105,11 +1108,6 @@ will toggle between those two.
@end table
@table @kbd
-@findex dired-goto-file
-@kindex M-g
-@item M-g
-(@code{dired-goto-file}) Go to the line of a file (or directory).
-
@findex dired-goto-subdir
@kindex M-G
@item M-G
@@ -1118,43 +1116,6 @@ This command reads its argument, with completion derived from the names of the
inserted subdirectories.
@end table
-@table @kbd
-@item w
-@cindex Adding to the kill ring in Dired.
-@kindex w
-@findex dired-copy-filename-as-kill
-(@code{dired-copy-filename-as-kill}) The @kbd{w} command puts the names
-of the marked (or next @var{N}) files into the kill ring, as if you had
-killed them with @kbd{C-w}. With a zero prefix argument @var{N}=0, use the
-complete pathname of each file. With a raw (just @kbd{C-u}) prefix argument,
-use the relative pathname of each marked file. As a special case, if no
-prefix argument is given and point is on a directory headerline, it
-gives you the name of that directory, without looking for marked files.
-
-@vindex dired-marked-files
-The list of names is also stored onto the variable @code{dired-marked-files}
-for use, e.g., in the @kbd{M-:} (@code{eval-expression}) command.
-
-As this command also displays what was pushed onto the kill ring, you can
-use it to display the list of currently marked files in the
-echo area (unless you happen to be on a subdirectory headerline).
-
-You can then feed the file name to other Emacs commands with @kbd{C-y}.
-For example, say you want to rename a file with a long name to a slightly
-different name. First type @kbd{w} to push the old name onto the kill
-ring. Then type @kbd{R} to rename it and use @kbd{C-y} inside @kbd{R}'s
-minibuffer prompt to insert the old name at a convenient place.
-
-@item T
-@kindex T
-@cindex Toggling marks.
-@findex dired-do-toggle
-(@code{dired-do-toggle}) Toggle marks. That is, currently marked
-files become unmarked and vice versa. Files marked with other flags
-(such as @samp{D}) are not affected. The special directories @file{.}
-and @file{..} are never toggled.
-@end table
-
@table @code
@item dired-smart-shell-command
@findex dired-smart-shell-command
@@ -1312,3 +1273,7 @@ Lawrence R. Dodd
@bye
@c dired-x.texi ends here.
+
+@ignore
+ arch-tag: 201727aa-9318-4c74-a0d7-4f51c550c4de
+@end ignore
diff --git a/man/dired.texi b/man/dired.texi
index 40882d7ad22..88e994ed027 100644
--- a/man/dired.texi
+++ b/man/dired.texi
@@ -39,6 +39,7 @@ files.
* Hiding Subdirectories:: Making subdirectories visible or invisible.
* Updating: Dired Updating. Discarding lines for files of no interest.
* Find: Dired and Find. Using `find' to choose the files for Dired.
+* Misc: Misc Dired Commands. Various other features.
@end menu
@node Dired Enter
@@ -85,6 +86,11 @@ to @kbd{C-n}. @kbd{p} is equivalent to @kbd{C-p}. (Moving by lines is
so common in Dired that it deserves to be easy to type.) @key{DEL}
(move up and unflag) is often useful simply for moving up.
+@findex dired-goto-file
+@kindex M-g
+ @kbd{M-g} (@code{dired-goto-file}) moves point to the line that
+describes a specified file or directory.
+
Some additional navigation commands are available when the Dired
buffer includes several directories. @xref{Subdirectory Motion}.
@@ -329,7 +335,7 @@ those files.
@item * @@
@kindex * @@ @r{(Dired)}
@findex dired-mark-symlinks
-@cindex marking symlinks (in Dired)
+@cindex marking symbolic links (in Dired)
Mark all symbolic links with @samp{*} (@code{dired-mark-symlinks}).
With a numeric argument, unmark all those files.
@@ -549,7 +555,7 @@ just one link) the name to give the link.
@findex dired-do-symlink
@kindex S @r{(Dired)}
-@cindex symlinks (in Dired)
+@cindex symbolic links (creation in Dired)
@item S @var{new} @key{RET}
Make symbolic links to the specified files (@code{dired-do-symlink}).
The argument @var{new} is the directory to make the links in, or (if
@@ -1086,3 +1092,33 @@ matching a given regular expression.
variable @code{find-ls-option}, whose default value specifies using
options @samp{-ld} for @code{ls}. If your listings are corrupted, you
may need to change the value of this variable.
+
+@node Misc Dired Commands
+@section Other Dired Commands
+
+@table @kbd
+@item w
+@cindex Adding to the kill ring in Dired.
+@kindex w
+@findex dired-copy-filename-as-kill
+The @kbd{w} command (@code{dired-copy-filename-as-kill}) puts the
+names of the marked (or next @var{n}) files into the kill ring, as if
+you had killed them with @kbd{C-w}. With a zero prefix argument
+@var{n}=0, use the absolute file name of each marked file. With just
+@kbd{C-u} as the prefix argument, use the relative file name of each
+marked file. As a special case, if no prefix argument is given and
+point is on a directory headerline, @kbd{w} gives you the name of that
+directory without looking for marked files.
+
+@vindex dired-marked-files
+The main purpose of the @kbd{w} command is so that you can yank the
+file names into arguments for other Emacs commands. It also displays
+what was pushed onto the kill ring, so you can use it to display the
+list of currently marked files in the echo area. It also stores the
+list of names in the variable @code{dired-marked-files}, for use in
+Lisp expressions.
+@end table
+
+@ignore
+ arch-tag: d105f9b9-fc1b-4c5f-a949-9b2cf3ca2fc1
+@end ignore
diff --git a/man/display.texi b/man/display.texi
index b8ea515acfa..2c530ec480a 100644
--- a/man/display.texi
+++ b/man/display.texi
@@ -756,13 +756,35 @@ hidden lines. This variable becomes local automatically when set.
@node Optional Mode Line
@section Optional Mode Line Features
+@cindex buffer size display
+@cindex display of buffer size
+@findex size-indication-mode
+ The buffer percentage @var{pos} indicates the percentage of the
+buffer above the top of the window. You can additionally display the
+size of the buffer by typing @kbd{M-x size-indication-mode} to turn on
+Size Indication mode. The size will be displayed immediately
+following the buffer percentage like this:
+
+@example
+@var{POS} of @var{SIZE}
+@end example
+
+@noindent
+Here @var{SIZE} is the human readable representation of the number of
+characters in the buffer, which means that @samp{k} for 10^3, @samp{M}
+for 10^6, @samp{G} for 10^9, etc., are used to abbreviate.
+
+@cindex narrowing, and buffer size display
+ If you have narrowed the buffer (@pxref{Narrowing}), the size of the
+accessible part of the buffer is shown.
+
@cindex line number display
@cindex display of line number
@findex line-number-mode
The current line number of point appears in the mode line when Line
Number mode is enabled. Use the command @kbd{M-x line-number-mode} to
turn this mode on and off; normally it is on. The line number appears
-before the buffer percentage @var{pos}, with the letter @samp{L} to
+after the buffer percentage @var{pos}, with the letter @samp{L} to
indicate what it is. @xref{Minor Modes}, for more information about
minor modes and about how to use this command.
@@ -866,20 +888,20 @@ lines are displayed in the @code{mode-line} face.
@section How Text Is Displayed
@cindex characters (in text)
- ASCII printing characters (octal codes 040 through 0176) in Emacs
+ @acronym{ASCII} printing characters (octal codes 040 through 0176) in Emacs
buffers are displayed with their graphics, as are non-ASCII multibyte
printing characters (octal codes above 0400).
- Some ASCII control characters are displayed in special ways. The
+ Some @acronym{ASCII} control characters are displayed in special ways. The
newline character (octal code 012) is displayed by starting a new line.
The tab character (octal code 011) is displayed by moving to the next
tab stop column (normally every 8 columns).
- Other ASCII control characters are normally displayed as a caret
+ Other @acronym{ASCII} control characters are normally displayed as a caret
(@samp{^}) followed by the non-control version of the character; thus,
control-A is displayed as @samp{^A}.
- Non-ASCII characters 0200 through 0237 (octal) are displayed with
+ Non-@acronym{ASCII} characters 0200 through 0237 (octal) are displayed with
octal escape sequences; thus, character code 0230 (octal) is displayed
as @samp{\230}. The display of character codes 0240 through 0377
(octal) may be either as escape sequences or as graphics. They do not
@@ -1037,3 +1059,7 @@ tab character. To enable this feature, set the variable
a minor mode that highlights the line containing point. Use @kbd{M-x
hl-line-mode} to enable or disable it in the current buffer. @kbd{M-x
global-hl-line-mode} enables or disables the same mode globally.
+
+@ignore
+ arch-tag: 2219f910-2ff0-4521-b059-1bd231a536c4
+@end ignore
diff --git a/man/doclicense.texi b/man/doclicense.texi
index 0369ea06bbb..23ec98c202f 100644
--- a/man/doclicense.texi
+++ b/man/doclicense.texi
@@ -366,3 +366,7 @@ If your document contains nontrivial examples of program code, we
recommend releasing these examples in parallel under your choice of
free software license, such as the GNU General Public License,
to permit their use in free software.
+
+@ignore
+ arch-tag: c1679162-1d8a-4f02-bc52-2e71765f0165
+@end ignore
diff --git a/man/ebrowse.texi b/man/ebrowse.texi
index 8a500a0feba..8e3510242cf 100644
--- a/man/ebrowse.texi
+++ b/man/ebrowse.texi
@@ -1451,3 +1451,7 @@ in on with the command @kbd{C-c b m}.
@contents
@bye
+
+@ignore
+ arch-tag: 52fe78ac-a1c4-48e7-815e-0a31acfad4bf
+@end ignore
diff --git a/man/ediff.texi b/man/ediff.texi
index 7499f6d7935..b1447386b0c 100644
--- a/man/ediff.texi
+++ b/man/ediff.texi
@@ -641,7 +641,7 @@ user can always forcefully refine specific difference regions by typing
@kindex h
Cycles between full highlighting, the mode where fine differences are not
highlighted (but computed), and the mode where highlighting is done with
-ASCII strings. The latter is not really recommended, unless on a dumb TTY.
+@acronym{ASCII} strings. The latter is not really recommended, unless on a dumb TTY.
@item r
@kindex r
@@ -1558,7 +1558,7 @@ white space and newlines. This feature can be toggled on/off interactively,
via the command @kbd{##}.
@end table
-@strong{Note:} In order for this feature to work, auto-refining of
+@strong{Please note:} in order for this feature to work, auto-refining of
difference regions must be on, since otherwise Ediff won't know if there
are fine differences between regions. On devices where Emacs can display
faces, auto-refining is a default, but it is not turned on by default on
@@ -1693,8 +1693,8 @@ faces, you can modify them when Ediff is being loaded using
ediff-current-diff-face-B)))
@end smallexample
-@strong{Note:} To set Ediff's faces, use only @code{copy-face} or
-@code{set/make-face-@dots{}} as shown above. Emacs' low-level
+@strong{Please note:} to set Ediff's faces, use only @code{copy-face}
+or @code{set/make-face-@dots{}} as shown above. Emacs' low-level
face-manipulation functions should be avoided.
@node Narrowing, Refinement of Difference Regions, Highlighting Difference Regions, Customization
@@ -2473,3 +2473,7 @@ Eli Zaretskii (eliz@@is.elta.co.il)
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: 165ecb88-d03c-44b1-a921-b93f50b05b46
+@end ignore
diff --git a/man/emacs-mime.texi b/man/emacs-mime.texi
index ab47e5a900a..bdeea1f4703 100644
--- a/man/emacs-mime.texi
+++ b/man/emacs-mime.texi
@@ -1380,3 +1380,7 @@ Content-Disposition Header Field
@bye
@c End:
+
+@ignore
+ arch-tag: c7ef2fd0-a91c-4e10-aa52-c1a2b11b1a8d
+@end ignore
diff --git a/man/emacs.texi b/man/emacs.texi
index ca5ddf039ba..3162cd1e167 100644
--- a/man/emacs.texi
+++ b/man/emacs.texi
@@ -166,13 +166,15 @@ Important Text-Changing Commands
* Display:: Controlling what text is displayed.
* Search:: Finding or replacing occurrences of a string.
* Fixit:: Commands especially useful for fixing typos.
+* Keyboard Macros:: A keyboard macro records a sequence of
+ keystrokes to be replayed with a single command.
Major Structures of Emacs
* Files:: All about handling files.
* Buffers:: Multiple buffers; editing several files at once.
* Windows:: Viewing two pieces of text at once.
* Frames:: Running the same Emacs session in multiple X windows.
-* International:: Using non-ASCII character sets (the MULE features).
+* International:: Using non-@acronym{ASCII} character sets (the MULE features).
Advanced Features
* Major Modes:: Text mode vs. Lisp mode vs. C mode ...
@@ -334,6 +336,16 @@ Commands for Fixing Typos
* Fixing Case:: Correcting case of last word entered.
* Spelling:: Apply spelling checker to a word or a whole buffer.
+Keyboard Macros
+
+* Basic Keyboard Macro:: Defining and running keyboard macros.
+* Keyboard Macro Ring:: Where previous keyboard macros are saved.
+* Keyboard Macro Counter:: Inserting incrementing numbers in macros.
+* Keyboard Macro Query:: Making keyboard macros do different things each time.
+* Save Keyboard Macro:: Giving keyboard macros names; saving them in files.
+* Edit Keyboard Macro:: Editing keyboard macros.
+* Keyboard Macro Step-Edit:: Interactively executing and editing a keyboard macro.
+
File Handling
* File Names:: How to type and edit file-name arguments.
@@ -699,7 +711,7 @@ The Diary
* Adding to Diary:: Commands to create diary entries.
* Special Diary Entries:: Anniversaries, blocks of dates, cyclic entries, etc.
-@sc{Gnus}
+Gnus
* Buffers of Gnus:: The group, summary, and article buffers.
* Gnus Startup:: What you should know about starting Gnus.
@@ -721,8 +733,6 @@ Customization
* Variables:: Many Emacs commands examine Emacs variables
to decide what to do; by setting variables,
you can control their functioning.
-* Keyboard Macros:: A keyboard macro records a sequence of
- keystrokes to be replayed with a single command.
* Key Bindings:: The keymaps say what command each key runs.
By changing them, you can "redefine keys".
* Keyboard Translations::
@@ -744,12 +754,6 @@ Variables
* Locals:: Per-buffer values of variables.
* File Variables:: How files can specify variable values.
-Keyboard Macros
-
-* Basic Kbd Macro:: Defining and running keyboard macros.
-* Save Kbd Macro:: Giving keyboard macros names; saving them in files.
-* Kbd Macro Query:: Making keyboard macros do different things each time.
-
Customizing Key Bindings
* Keymaps:: Generalities. The global keymap.
@@ -806,6 +810,7 @@ Command Line Options and Arguments
* Borders X:: Internal and external borders, under X.
* Title X:: Specifying the initial frame's title.
* Icons X:: Choosing what sort of icon to use, under X.
+* Misc X:: Other display options.
X Resources
@@ -924,9 +929,9 @@ redistribute the GNU Emacs received from them under the usual terms of the
General Public License. In other words, the program must be free for you
when you get it, not just free for the manufacturer.
-You can also order copies of GNU Emacs from the Free Software Foundation
-on CD-ROM@. This is a convenient and reliable way to get a copy; it is
-also a good way to help fund our work. (The Foundation has always
+You can also order copies of GNU Emacs from the Free Software
+Foundation. This is a convenient and reliable way to get a copy; it
+is also a good way to help fund our work. (The Foundation has always
received most of its funds in this way.) An order form is included in
the file @file{etc/ORDERS} in the Emacs distribution, and on our web
site in @url{http://www.gnu.org/order/order.html}. For further
@@ -951,7 +956,10 @@ company policy is unsympathetic to the idea of donating to charity, you
might instead suggest ordering a CD-ROM from the Foundation
occasionally, or subscribing to periodic updates.
-@iftex
+@ifnotinfo
+@node Acknowledgments, Copying, Distrib, Top
+@section Acknowledgments
+
Contributors to GNU Emacs include Per Abrahamsen, Jay K. Adams, Joe
Arceneaux, Boaz Ben-Zvi, Jim Blandy, Terrence Brannon, Frank Bresz,
Peter Breton, Kevin Broadey, Vincent Broman, David M. Brown, Bill
@@ -969,7 +977,7 @@ Heuer, Manabu Higashida, Anders Holst, Kurt Hornik, Tom Houlder, Lars
Ingebrigtsen, Andrew Innes, Michael K. Johnson, Kyle Jones, Tomoji
Kagatani, Brewster Kahle, David Kaufman, Henry Kautz, Howard Kaye,
Michael Kifer, Richard King, Larry K. Kolodney, Robert Krawitz,
-Sebastian Kremer, Geoff Kuenning, David K@aa gedal, Daniel LaLiberte,
+Sebastian Kremer, Geoff Kuenning, David K@aa{}gedal, Daniel LaLiberte,
Aaron Larson, James R. Larus, Frederic Lepied, Lars Lindberg, Eric
Ludlam, Neil M. Mager, Ken Manheimer, Bill Mann, Brian Marick, Simon
Marshall, Bengt Martensson, Charlie Martin, Thomas May, Roland McGrath,
@@ -993,7 +1001,7 @@ Warsaw, Morten Welinder, Joseph Brian Wells, Rodney Whitby, Ed
Wilkinson, Mike Williams, Steven A. Wood, Dale R. Worley, Felix
S. T. Wu, Tom Wurgler, Eli Zaretskii, Jamie Zawinski, Ian T. Zimmermann,
Reto Zimmermann, and Neal Ziring.
-@end iftex
+@end ifnotinfo
@node Copying, GNU Free Documentation License, Distrib, Top
@unnumbered GNU GENERAL PUBLIC LICENSE
@@ -1463,6 +1471,7 @@ edit files while running shell commands.
@include display.texi
@include search.texi
@include fixit.texi
+@include kmacro.texi
@include files.texi
@include buffers.texi
@include windows.texi
@@ -1542,3 +1551,6 @@ edit files while running shell commands.
@contents
@bye
+@ignore
+ arch-tag: ed48740a-410b-46ea-9387-c9a9252a3392
+@end ignore
diff --git a/man/entering.texi b/man/entering.texi
index 5b6c28472bf..9200082328a 100644
--- a/man/entering.texi
+++ b/man/entering.texi
@@ -149,3 +149,7 @@ inspired by the use of @kbd{C-z} and @kbd{C-c} on several operating
systems as the characters for stopping or killing a program, but that is
their only relationship with the operating system. You can customize
these keys to run any commands of your choice (@pxref{Keymaps}).
+
+@ignore
+ arch-tag: df798d8b-f253-4113-b585-f528f078a944
+@end ignore
diff --git a/man/eshell.texi b/man/eshell.texi
index 188ac520a16..c909b6ebb46 100644
--- a/man/eshell.texi
+++ b/man/eshell.texi
@@ -1,5 +1,4 @@
\input texinfo @c -*-texinfo-*-
-@c "@(#)$Name: $:$Id: eshell.texi,v 1.17 2002/12/10 13:16:31 pj Exp $"
@c %**start of header
@setfilename ../info/eshell
@settitle Eshell: The Emacs Shell
@@ -9,7 +8,7 @@
@copying
This manual is for Eshell, the Emacs shell.
-Copyright @copyright{} 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 1999, 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -671,6 +670,8 @@ Below is complete list of known problems with Eshell version 2.4.1,
which is the version included with Emacs 21.1.
@table @asis
+@item Documentation incomplete
+
@item Differentiate between aliases and functions
Allow for a bash-compatible syntax, such as:
@@ -1128,3 +1129,7 @@ Since it keeps the cursor up where the command was invoked.
@printindex ky
@bye
+
+@ignore
+ arch-tag: 776409ba-cb15-42b9-b2b6-d2bdc7ebad01
+@end ignore
diff --git a/man/eudc.texi b/man/eudc.texi
index 511069973df..aaf130eb489 100644
--- a/man/eudc.texi
+++ b/man/eudc.texi
@@ -973,3 +973,7 @@ in testing and proofreading the code and docs of @file{ph.el}.
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: 1b79460b-4ea1-441d-ab45-05ddd16ef241
+@end ignore
diff --git a/man/faq.texi b/man/faq.texi
index b25ef4bca6f..6894918079e 100644
--- a/man/faq.texi
+++ b/man/faq.texi
@@ -161,19 +161,19 @@ written inside quotes or on lines by themselves, like this:
Any real spaces in such a key sequence should be ignored; only @key{SPC}
really means press the space key.
-The ASCII code sent by @kbd{C-x} (except for @kbd{C-?}) is the value
+The @acronym{ASCII} code sent by @kbd{C-x} (except for @kbd{C-?}) is the value
that would be sent by pressing just @key{x} minus 96 (or 64 for
upper-case @key{X}) and will be from 0 to 31. On Unix and GNU/Linux
-terminals, the ASCII code sent by @kbd{M-x} is the sum of 128 and the
-ASCII code that would be sent by pressing just @key{x}. Essentially,
+terminals, the @acronym{ASCII} code sent by @kbd{M-x} is the sum of 128 and the
+@acronym{ASCII} code that would be sent by pressing just @key{x}. Essentially,
@key{Control} turns off bits 5 and 6 and @key{Meta} turns on bit
7@footnote{
DOS and Windows terminals don't set bit 7 when the @key{Meta} key is
pressed.}.
-@kbd{C-?} (aka @key{DEL}) is ASCII code 127. It is a misnomer to call
+@kbd{C-?} (aka @key{DEL}) is @acronym{ASCII} code 127. It is a misnomer to call
@kbd{C-?} a ``control'' key, since 127 has both bits 5 and 6 turned ON.
-Also, on very few keyboards does @kbd{C-?} generate ASCII code 127.
+Also, on very few keyboards does @kbd{C-?} generate @acronym{ASCII} code 127.
@inforef{Text Characters, Text Characters, emacs}, and @inforef{Keys,
Keys, emacs}, for more information. (@xref{On-line manual}, for more
@@ -613,7 +613,7 @@ command-apropos}).
@cindex Command description in the manual
@item
-The command @kbd{C-h C-f} (@code{Info-goto-emacs-command-node}) prompts
+The command @kbd{C-h F} (@code{Info-goto-emacs-command-node}) prompts
for the name of a command, and then attempts to find the section in the
Emacs manual where that command is described.
@@ -980,7 +980,7 @@ The Emacs FAQ is available in several ways:
@item
Inside of Emacs itself. You can get it from selecting the @samp{Emacs
FAQ} option from the @samp{Help} menu of the Emacs menu bar at the top
-of any Emacs frame, or by typing @kbd{C-h F} (@kbd{M-x view-emacs-FAQ}).
+of any Emacs frame, or by typing @kbd{C-h C-f} (@kbd{M-x view-emacs-FAQ}).
@item
Via USENET. If you can read news, the FAQ should be available in your
@@ -1110,7 +1110,7 @@ Emacs @value{VER} is the current version as of this writing.
@cindex Differences between Emacs 19 and Emacs 20
@cindex Emacs 20, new features in
-To find out what has changed in recent versions, type @kbd{C-h n}
+To find out what has changed in recent versions, type @kbd{C-h C-n}
(@kbd{M-x view-emacs-news}). The oldest changes are at the bottom of
the file, so you might want to read it starting there, rather than at
the top.
@@ -2687,7 +2687,7 @@ instructions how to do that.
The file @file{etc/PROBLEMS} in the Emacs distribution lists various
known problems with building and using Emacs on specific platforms;
-type @kbd{C-h P} to read it.
+type @kbd{C-h C-e} to read it.
@menu
* Problems with very large files::
@@ -4541,7 +4541,7 @@ actually behaves.
@cindex Help invoked by Backspace
@cindex DEL key does not delete
-The @key{Backspace} key (on most keyboards) generates ASCII code 8.
+The @key{Backspace} key (on most keyboards) generates @acronym{ASCII} code 8.
@kbd{C-h} sends the same code. In Emacs by default @kbd{C-h} invokes
help-command. This is intended to be easy to remember since the first
letter of @samp{help} is @samp{h}. The easiest solution to this problem
@@ -4739,7 +4739,7 @@ press @key{Meta} and @key{a} together, but with @key{ESC}, you press
@cindex Lacking an Escape key
@cindex Escape key, lacking
-Type @kbd{C-[} instead. This should send ASCII code 27 just like an
+Type @kbd{C-[} instead. This should send @acronym{ASCII} code 27 just like an
Escape key would. @kbd{C-3} may also work on some terminal (but not
under X). For many terminals (notably DEC terminals) @key{F11}
generates @key{ESC}. If not, the following form can be used to bind it:
@@ -4791,7 +4791,7 @@ is how to make @kbd{H-M-RIGHT} move forward a word:
@item
Not all modifiers are permitted in all situations. @key{Hyper},
@key{Super}, and @key{Alt} are not available on Unix character
-terminals. Non-ASCII keys and mouse events (e.g. @kbd{C-=} and
+terminals. Non-@acronym{ASCII} keys and mouse events (e.g. @kbd{C-=} and
@kbd{Mouse-1}) also fall under this category.
@end itemize
@@ -4821,7 +4821,7 @@ For X11: Make sure it really is a @key{Meta} key. Use @code{xev} to
find out what keysym your @key{Meta} key generates. It should be either
@code{Meta_L} or @code{Meta_R}. If it isn't, use @file{xmodmap} to fix
the situation. If @key{Meta} does generate @code{Meta_L} or
-@code{Meta_R}, but @kbd{M-x} produces a non-ASCII character, put this in
+@code{Meta_R}, but @kbd{M-x} produces a non-@acronym{ASCII} character, put this in
your @file{~/.Xdefaults} file:
@example
@@ -4914,7 +4914,7 @@ Support, emacs}. On a Unix, when Emacs runs on a text-only terminal
display or is invoked with @samp{emacs -nw}, you typically need to use
@code{set-terminal-coding-system} to tell Emacs what the terminal can
display, even after setting the language environment; otherwise
-non-ASCII characters will display as @samp{?}. On other operating
+non-@acronym{ASCII} characters will display as @samp{?}. On other operating
systems, such as MS-DOS and MS-Windows, Emacs queries the OS about the
character set supported by the display, and sets up the required
terminal coding system automatically.
@@ -5441,3 +5441,7 @@ part of the Gnus distribution.
@contents
@bye
+
+@ignore
+ arch-tag: fee0d62d-06cf-43d8-ac21-123408eaf10f
+@end ignore
diff --git a/man/files.texi b/man/files.texi
index 2c18092286c..f73d1370eba 100644
--- a/man/files.texi
+++ b/man/files.texi
@@ -2,7 +2,7 @@
@c Copyright (C) 1985,86,87,93,94,95,97,99, 2000, 2001
@c Free Software Foundation, Inc.
@c See file emacs.texi for copying conditions.
-@node Files, Buffers, Fixit, Top
+@node Files, Buffers, Keyboard Macros, Top
@chapter File Handling
@cindex files
@@ -139,7 +139,7 @@ literal @samp{~} should also be quoted with @samp{/:}.
@code{substitute-in-file-name}. The substitution is performed only on
file names read as such using the minibuffer.
- You can include non-ASCII characters in file names if you set the
+ You can include non-@acronym{ASCII} characters in file names if you set the
variable @code{file-name-coding-system} to a non-@code{nil} value.
@xref{Specify Coding}.
@@ -316,7 +316,7 @@ seek. This feature is available only when you are using a window
system. @xref{Frames}.
@findex find-file-literally
- If you wish to edit a file as a sequence of ASCII characters with no special
+ If you wish to edit a file as a sequence of @acronym{ASCII} characters with no special
encoding or conversion, use the @kbd{M-x find-file-literally} command.
It visits a file, like @kbd{C-x C-f}, but does not do format conversion
(@pxref{Formatted Text}), character code conversion (@pxref{Coding
@@ -855,11 +855,10 @@ of the file. To do this, use @kbd{M-x revert-buffer}, which operates on
the current buffer. Since reverting a buffer unintentionally could lose
a lot of work, you must confirm this command with @kbd{yes}.
- @code{revert-buffer} keeps point at the same distance (measured in
-characters) from the beginning of the file. If the file was edited only
-slightly, you will be at approximately the same piece of text after
-reverting as before. If you have made drastic changes, the same value of
-point in the old file may address a totally different piece of text.
+ @code{revert-buffer} tries to position point in such a way that, if
+the file was edited only slightly, you will be at approximately the
+same piece of text after reverting as before. However, if you have made
+drastic changes, point may wind up in a totally different piece of text.
Reverting marks the buffer as ``not modified'' until another change is
made.
@@ -1070,6 +1069,8 @@ file, sessions are not recorded for recovery.
@node File Aliases
@section File Name Aliases
+@cindex symbolic links (visiting)
+@cindex hard links (visiting)
Symbolic links and hard links both make it possible for several file
names to refer to the same file. Hard links are alternate names that
@@ -1122,6 +1123,10 @@ from the Free Software Foundation. We also have free software to
replace SCCS, known as CSSC; if you are using SCCS and don't want to
make the incompatible change to RCS or CVS, you can switch to CSSC.
+ VC is enabled by default in Emacs. To disable it, set the
+customizable variable @code{vc-handled-backends} to @code{nil}
+(@pxref{Customizing VC}).
+
@menu
* Introduction to VC:: How version control works in general.
* VC Mode Line:: How the mode line shows version control status.
@@ -1530,6 +1535,46 @@ range from red to blue spans the past 36 days instead of 360 days. A
stretch factor greater than 1 means the color range spans more than a
year.
+From the annotate buffer, you can use the following keys to browse the
+annotations of past revisions, view diffs, or view log entries:
+
+@itemize @bullet
+
+@item
+Pressing @kbd{P} annotates the previous revision. It also takes a
+numeric prefix argument, so for example @kbd{C-u 10 P} would take you
+back 10 revisions.
+
+@item
+Pressing @kbd{N} annotates the next revision. It also takes a numeric
+prefix argument, so for example @kbd{C-u 10 N} would take you forward
+10 revisions.
+
+@item
+Pressing @kbd{J} annotates the revision at line (as denoted by the
+version number on the same line).
+
+@item
+Pressing @kbd{A} annotates the revision previous to line (as denoted
+by the version number on the same line). This is useful to see the
+state the file was in before the change on the current line was made.
+
+@item
+Pressing @kbd{D} shows the diff of the revision at line with its
+previous revision. This is useful to see what actually changed when
+the revision denoted on the current line was committed.
+
+@item
+Pressing @kbd{L} shows the log of the revision at line. This is
+useful to see the author's description of the changes that occured
+when the revision denoted on the current line was committed.
+
+@item
+Pressing @kbd{W} annotates the workfile (most up to date) version. If
+you used @kbd{P} and @kbd{N} to browse to other revisions, use this
+key to return to the latest version.
+@end itemize
+
@node Secondary VC Commands
@subsection The Secondary Commands of VC
@@ -2492,7 +2537,8 @@ The variable @code{vc-handled-backends} determines which version
control systems VC should handle. The default value is @code{(RCS CVS
SCCS)}, so it contains all three version systems that are currently
supported. If you want VC to ignore one or more of these systems,
-exclude its name from the list.
+exclude its name from the list. To disable VC entirely, set this
+variable to @code{nil}.
The order of systems in the list is significant: when you visit a file
registered in more than one system (@pxref{Local Version Control}),
@@ -2859,6 +2905,7 @@ file system. On MS-DOS, it works by copying the file.
the old contents of the file @var{new}.
@findex make-symbolic-link
+@cindex symbolic links (creation)
@kbd{M-x make-symbolic-link} reads two file names @var{target} and
@var{linkname}, then creates a symbolic link named @var{linkname}, which
points at @var{target}. The effect is that future attempts to open file
@@ -3186,3 +3233,7 @@ powerful heuristic defaults (@pxref{FFAP}), often based on the text at
point. Partial Completion mode offers other features extending
@code{find-file}, which can be used with @code{ffap}.
@xref{Completion Options}.
+
+@ignore
+ arch-tag: 768d32cb-e15a-4cc1-b7bf-62c00ee12250
+@end ignore
diff --git a/man/fixit.texi b/man/fixit.texi
index 21f613a93ad..75dde658680 100644
--- a/man/fixit.texi
+++ b/man/fixit.texi
@@ -1,7 +1,7 @@
@c This is part of the Emacs manual.
@c Copyright (C) 1985, 86, 87, 93, 94, 95, 1997 Free Software Foundation, Inc.
@c See file emacs.texi for copying conditions.
-@node Fixit, Files, Search, Top
+@node Fixit, Keyboard Macros, Search, Top
@chapter Commands for Fixing Typos
@cindex typos, fixing
@cindex mistakes, correcting
@@ -342,3 +342,7 @@ dictionary. The completion dictionary must be different because it
cannot use employ root and affix information. For some languages
there is a spell checking dictionary but no word completion
dictionary.
+
+@ignore
+ arch-tag: 3359a443-96ed-448f-9f05-c8111ba8eac0
+@end ignore
diff --git a/man/forms.texi b/man/forms.texi
index 91a1f456f24..74876760ccc 100644
--- a/man/forms.texi
+++ b/man/forms.texi
@@ -973,3 +973,7 @@ Software Foundation. Thanks, Richard!
@contents
@bye
+
+@ignore
+ arch-tag: 2ac9810b-aa49-4ea6-8030-d7f1ecd467ed
+@end ignore
diff --git a/man/frames.texi b/man/frames.texi
index 57798a374d9..7896adc41f6 100644
--- a/man/frames.texi
+++ b/man/frames.texi
@@ -48,6 +48,7 @@ under X.
* Frame Parameters:: Changing the colors and other modes of frames.
* Scroll Bars:: How to enable and disable scroll bars; how to use them.
* Wheeled Mice:: Using mouse wheels for scrolling.
+* Drag and drop:: Using drag and drop to open files and insert text.
* Menu Bars:: Enabling and disabling the menu bar.
* Tool Bars:: Enabling and disabling the tool bar.
* Dialog Boxes:: Controlling use of dialog boxes.
@@ -69,7 +70,7 @@ commands for copying between Emacs and other X client programs.
If you select a region with any of these mouse commands, and then
immediately afterward type the @key{DELETE} function key, it deletes the
region that you selected. The @key{BACKSPACE} function key and the
-ASCII character @key{DEL} do not do this; if you type any other key
+@acronym{ASCII} character @key{DEL} do not do this; if you type any other key
in between the mouse command and @key{DELETE}, it does not do this.
@findex mouse-set-region
@@ -795,6 +796,40 @@ generating appropriate events for Emacs.
@code{mouse-wheel-scroll-amount} determine where and by how much
buffers are scrolled.
+@node Drag and drop
+@section Drag and drop in Emacs.
+
+@cindex drag and drop
+ Emacs supports drag and drop so that dropping of files and text is handeled.
+Currently supported drag and drop protocols are XDND, Motif and the old
+KDE 1.x protocol. There is no drag support yet.
+When text is dropped on Emacs, Emacs inserts the text where it is dropped.
+When a file is dragged from a file manager to Emacs, Emacs opens that file.
+As a special case, if a file is dropped on a dired buffer the file is
+copied or moved (depends on exactly how it is dragged and the application
+it was dragged from) to the directory the dired buffer is displaying.
+
+@vindex x-dnd-open-file-other-window
+ A file is normally opened in the window it is dropped on, but if you
+prefer the file to be opened in a new window you can customize the variable
+@code{x-dnd-open-file-other-window}.
+
+@vindex x-dnd-types-alist
+ If you want to change the way Emacs handles drop of different types
+or add a new type, you shall customize @code{x-dnd-types-alist}. This
+requires detailed knowledge of what types other applications use
+for drag and drop.
+
+@vindex x-dnd-protocol-alist
+ When an URL is dropped on Emacs it may be a file, but it may also be
+another URL type (ftp, http, etc.). Emacs first checks
+@code{x-dnd-protocol-alist} to determine what to do with the URL. If there
+is no match there and if @code{browse-url-browser-function} is an alist,
+Emacs looks for a match there. If no match is found the text for the URL
+is inserted. If you want to alter Emacs behaviour you can customize these
+variables.
+
+
@node Menu Bars
@section Menu Bars
@cindex Menu Bar mode
@@ -855,6 +890,16 @@ invoke the command to begin with.
use of dialog boxes. This also controls whether to use file selection
windows (but those are not supported on all platforms).
+@vindex use-file-dialog
+ A file selection window is a special kind of dialog box for asking for
+file names.
+
+ You can customize the option @code{use-file-dialog} to suppress the
+use of file selection windows even if you still want other kinds
+of dialogs. This option has no effect if you have supressed all dialog
+boxes with the option @code{use-dialog-box}.
+
+
@node Tooltips
@section Tooltips (or ``Balloon Help'')
@@ -954,3 +999,7 @@ functionality is still available by holding down the @kbd{SHIFT} key
when you press the mouse button. The Linux console supports this
mode if it has support for the mouse enabled, e.g.@: using the
@command{gpm} daemon.
+
+@ignore
+ arch-tag: 7dcf3a31-a43b-45d4-a900-445b10d77e49
+@end ignore
diff --git a/man/glossary.texi b/man/glossary.texi
index c347eb3f982..017630801a6 100644
--- a/man/glossary.texi
+++ b/man/glossary.texi
@@ -27,16 +27,16 @@ Input, Alt}.
@item Argument
See `numeric argument.'
-@item ASCII character
-An ASCII character is either an ASCII control character or an ASCII
+@item @acronym{ASCII} character
+An @acronym{ASCII} character is either an @acronym{ASCII} control character or an @acronym{ASCII}
printing character. @xref{User Input}.
-@item ASCII control character
-An ASCII control character is the Control version of an upper-case
+@item @acronym{ASCII} control character
+An @acronym{ASCII} control character is the Control version of an upper-case
letter, or the Control version of one of the characters @samp{@@[\]^_?}.
-@item ASCII printing character
-ASCII printing characters include letters, digits, space, and these
+@item @acronym{ASCII} printing character
+@acronym{ASCII} printing characters include letters, digits, space, and these
punctuation characters: @samp{!@@#$%^& *()_-+=|\~` @{@}[]:;"' <>,.?/}.
@item Auto Fill Mode
@@ -234,8 +234,8 @@ is typed. @xref{Completion}.@refill
When a line of text is longer than the width of the window, it
takes up more than one screen line when displayed. We say that the
text line is continued, and all screen lines used for it after the
-first are called continuation lines. @xref{Basic,Continuation,Basic
-Editing}. A related Emacs feature is `filling' (q.v.@:).
+first are called continuation lines. @xref{Continuation Lines}.
+A related Emacs feature is `filling' (q.v.@:).
@item Control Character
A control character is a character that you type by holding down the
@@ -280,7 +280,7 @@ The cursor is the rectangle on the screen which indicates the position
called point (q.v.@:) at which insertion and deletion takes place.
The cursor is on or under the character that follows point. Often
people speak of `the cursor' when, strictly speaking, they mean
-`point.' @xref{Basic,Cursor,Basic Editing}.
+`point.' @xref{Point,Cursor}.
@item Customization
Customization is making minor changes in the way Emacs works. It is
@@ -317,7 +317,7 @@ A defun is a major definition at the top level in a program. The name
@key{DEL} is a character that runs the command to delete one character
of text before the cursor. It is typically either the @key{DELETE}
key or the @key{BACKSPACE} key, whichever one is easy to type.
-@xref{Basic,DEL,Basic Editing}.
+@xref{Erasing,DEL}.
@item Deletion
Deletion means erasing text without copying it into the kill ring
@@ -547,7 +547,7 @@ just names. All the non-Meta (q.v.@:) characters except for the
Control (q.v.@:) characters are graphic characters. These include
letters, digits, punctuation, and spaces; they do not include
@key{RET} or @key{ESC}. In Emacs, typing a graphic character inserts
-that character (in ordinary editing modes). @xref{Basic,,Basic Editing}.
+that character (in ordinary editing modes). @xref{Inserting Text}.
@item Highlighting
Highlighting text means displaying it with a different foreground and/or
@@ -621,8 +621,8 @@ keys, pressing or releasing mouse buttons, and switching between Emacs
frames. @xref{User Input}.
@item Input Method
-An input method is a system for entering non-ASCII text characters by
-typing sequences of ASCII characters (q.v.@:). @xref{Input Methods}.
+An input method is a system for entering non-@acronym{ASCII} text characters by
+typing sequences of @acronym{ASCII} characters (q.v.@:). @xref{Input Methods}.
@item Insertion
Insertion means copying text into the buffer, either from the keyboard
@@ -639,7 +639,7 @@ See `incremental search.'
@item Justification
Justification means adding extra spaces within lines of text to make
them extend exactly to a specified width.
-@xref{Filling,Justification}.
+@xref{Format Justification}.
@item Keyboard Macro
Keyboard macros are a way of defining new Emacs commands from
@@ -688,7 +688,7 @@ to exist. Any data within it, if not saved in a file, is lost.
@item Language Environment
Your choice of language environment specifies defaults for the input
method (q.v.@:) and coding system (q.v.@:). @xref{Language
-Environments}. These defaults are relevant if you edit non-ASCII text
+Environments}. These defaults are relevant if you edit non-@acronym{ASCII} text
(@pxref{International}).
@item Line Wrapping
@@ -730,7 +730,7 @@ A local value of a variable (q.v.@:) applies to only one buffer.
@item @kbd{M-}
@kbd{M-} in the name of a character is an abbreviation for @key{META},
one of the modifier keys that can accompany any character.
-@xref{User Input}.
+@xref{User Input,M-}.
@item @kbd{M-C-}
@kbd{M-C-} in the name of a character is an abbreviation for
@@ -833,13 +833,13 @@ another. The usual way to move text by killing (q.v.@:) and then
yanking (q.v.@:). @xref{Killing}.
@item MULE
-MULE refers to the Emacs features for editing multilingual non-ASCII text
+MULE refers to the Emacs features for editing multilingual non-@acronym{ASCII} text
using multibyte characters (q.v.@:). @xref{International}.
@item Multibyte Character
A multibyte character is a character that takes up several bytes in a
-buffer. Emacs uses multibyte characters to represent non-ASCII text,
-since the number of non-ASCII characters is much more than 256.
+buffer. Emacs uses multibyte characters to represent non-@acronym{ASCII} text,
+since the number of non-@acronym{ASCII} characters is much more than 256.
@xref{International Chars, International Characters}.
@item Named Mark
@@ -875,7 +875,7 @@ characters replace the existing text after point rather than pushing
it to the right. @xref{Minor Modes}.
@item Page
-A page is a unit of text, delimited by formfeed characters (ASCII
+A page is a unit of text, delimited by formfeed characters (@acronym{ASCII}
control-L, code 014) coming at the beginning of a line. Some Emacs
commands are provided for moving over and operating on pages.
@xref{Pages}.
@@ -894,7 +894,7 @@ end of a word or expression. @xref{Syntax}.
Point is the place in the buffer at which insertion and deletion
occur. Point is considered to be between two characters, not at one
character. The terminal's cursor (q.v.@:) indicates the location of
-point. @xref{Basic,Point,Basic Editing}.
+point. @xref{Point}.
@item Prefix Argument
See `numeric argument.'
@@ -942,7 +942,7 @@ convention. For example, an ``ordinary'' character as an Emacs command
inserts itself; so in this context, a special character is any character
that does not normally insert itself (such as @key{DEL}, for example),
and quoting it makes it insert itself as if it were not special. Not
-all contexts allow quoting. @xref{Basic,Quoting,Basic Editing}.
+all contexts allow quoting. @xref{Inserting Text,Quoting}.
@item Quoting File Names
Quoting a file name turns off the special significance of constructs
@@ -1035,7 +1035,7 @@ systems. @xref{Scroll Bars}.
@item Scrolling
Scrolling means shifting the text in the Emacs window so as to see a
-different part of the buffer. @xref{Display,Scrolling}.
+different part of the buffer. @xref{Scrolling}.
@item Searching
Searching means moving point to the next occurrence of a specified
@@ -1055,7 +1055,7 @@ using the secondary selection. @xref{Secondary Selection}.
@item Selecting
Selecting a buffer means making it the current (q.v.@:) buffer.
-@xref{Buffers,Selecting}.
+@xref{Select Buffer}.
@item Selection
Windowing systems allow an application program to specify
@@ -1212,7 +1212,7 @@ two adjacent characters, words, balanced expressions (q.v.@:) or lines
Truncating text lines in the display means leaving out any text on a
line that does not fit within the right margin of the window
displaying it. See also `continuation line.'
-@xref{Basic,Truncation,Basic Editing}.
+@xref{Continuation Lines,Truncation}.
@item TTY
See `text-only terminal.'
@@ -1279,3 +1279,6 @@ undo a mistaken kill, or for copying or moving text. Some other
systems call this ``pasting.'' @xref{Yanking}.
@end table
+@ignore
+ arch-tag: 0dd53ce1-5f09-4ac2-b13b-cf22b0f28d23
+@end ignore
diff --git a/man/gnu.texi b/man/gnu.texi
index e8b3bc482d4..4185f8f9114 100644
--- a/man/gnu.texi
+++ b/man/gnu.texi
@@ -542,3 +542,7 @@ this are bureaucracy and isometric struggles against competition. Free
software will greatly reduce these drains in the area of software
production. We must do this, in order for technical gains in productivity
to translate into less work for us.
+
+@ignore
+ arch-tag: 21eb38f8-6fa0-480a-91cd-f3dab7148542
+@end ignore
diff --git a/man/gnus-faq.texi b/man/gnus-faq.texi
index acdb0edd5e4..804da4cafcf 100644
--- a/man/gnus-faq.texi
+++ b/man/gnus-faq.texi
@@ -671,3 +671,6 @@ Use an nnbabyl:all.SCORE (or nnmh, or nnml, or whatever) file containing:
@end itemize
+@ignore
+ arch-tag: 64dc5692-edb4-4848-a965-7aa0181acbb8
+@end ignore
diff --git a/man/gnus.texi b/man/gnus.texi
index b9e6dfc84a2..9fa1285b915 100644
--- a/man/gnus.texi
+++ b/man/gnus.texi
@@ -22229,3 +22229,7 @@ former). The manual is unambiguous, but it can be confusing.
@end iftex
@c End:
+
+@ignore
+ arch-tag: c9fa47e7-78ca-4681-bda9-9fef45d1c819
+@end ignore
diff --git a/man/help.texi b/man/help.texi
index b6431c5ede4..56fb9f542d4 100644
--- a/man/help.texi
+++ b/man/help.texi
@@ -71,7 +71,7 @@ Similar, but searches for @var{topic} (which can be a regular
expression) in the @emph{text} of the manual rather than in its
indices.
-@item C-h F
+@item C-h C-f
This brings up the Emacs FAQ, where you can use the usual search
commands (@pxref{Search}) to find the information.
@@ -343,38 +343,40 @@ use:
@multitable {emulations} {aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa}
@item abbrev@tab abbreviation handling, typing shortcuts, macros.
-@item bib@tab support for the bibliography processor @code{bib}.
-@item c@tab C and C++ language support.
+@item bib@tab code related to the @code{bib} bibliography processor.
+@item c@tab support for the C language and related languages.
@item calendar@tab calendar and time management support.
@item comm@tab communications, networking, remote access to files.
+@item convenience@tab convenience features for faster editing.
@item data@tab support for editing files of data.
@item docs@tab support for Emacs documentation.
@item emulations@tab emulations of other editors.
@item extensions@tab Emacs Lisp language extensions.
-@item faces@tab support for using faces (fonts and colors; @pxref{Faces}).
+@item faces@tab support for multiple fonts.
+@item files@tab support for editing and manipulating files.
@item frames@tab support for Emacs frames and window systems.
@item games@tab games, jokes and amusements.
@item hardware@tab support for interfacing with exotic hardware.
@item help@tab support for on-line help systems.
-@item hypermedia@tab support for links within text, or other media types.
+@item hypermedia@tab support for links between text or other media types.
@item i18n@tab internationalization and alternate character-set support.
@item internal@tab code for Emacs internals, build process, defaults.
@item languages@tab specialized modes for editing programming languages.
-@item lisp@tab support for using Lisp (including Emacs Lisp).
-@item local@tab libraries local to your site.
+@item lisp@tab Lisp support, including Emacs Lisp.
+@item local@tab code local to your site.
@item maint@tab maintenance aids for the Emacs development group.
@item mail@tab modes for electronic-mail handling.
-@item matching@tab searching and matching.
+@item matching@tab various sorts of searching and matching.
+@item mouse@tab mouse support.
+@item multimedia@tab images and sound support.
@item news@tab support for netnews reading and posting.
-@item non-text@tab support for editing files that are not ordinary text.
@item oop@tab support for object-oriented programming.
-@item outlines@tab hierarchical outlining.
+@item outlines@tab support for hierarchical outlining.
@item processes@tab process, subshell, compilation, and job control support.
@item terminals@tab support for terminal types.
-@item tex@tab support for the @TeX{} formatter.
+@item tex@tab supporting code for the @TeX{} formatter.
@item tools@tab programming tools.
-@item unix@tab front-ends/assistants for, or emulators of, system features.
-@item vms@tab support code for VMS.
+@item unix@tab front-ends/assistants for, or emulators of, UNIX-like features.
@item wp@tab word processing.
@end multitable
@@ -587,3 +589,7 @@ Areas of the mode line are examples. This help will normally be
shown in the echo area when you move point into the active text. In
a window system you can display the help text as a ``tooltip''
(sometimes known as ``balloon help''). @xref{Tooltips}.
+
+@ignore
+ arch-tag: 6f33ab62-bc75-4367-8057-fd67cc15c3a1
+@end ignore
diff --git a/man/idlwave.texi b/man/idlwave.texi
index 6cd3cb0f1b9..fde5cd389d6 100644
--- a/man/idlwave.texi
+++ b/man/idlwave.texi
@@ -3529,3 +3529,7 @@ instead.
@printindex cp
@bye
+
+@ignore
+ arch-tag: f1d73958-1423-4127-b8aa-f7b953d64492
+@end ignore
diff --git a/man/indent.texi b/man/indent.texi
index a940bc77a95..d2134103240 100644
--- a/man/indent.texi
+++ b/man/indent.texi
@@ -245,3 +245,7 @@ preserving the columns of all nonblank text. @kbd{M-x tabify} scans the
region for sequences of spaces, and converts sequences of at least three
spaces to tabs if that can be done without changing indentation. @kbd{M-x
untabify} changes all tabs in the region to appropriate numbers of spaces.
+
+@ignore
+ arch-tag: acc07de7-ae11-4ee8-a159-cb59c473f0fb
+@end ignore
diff --git a/man/info.texi b/man/info.texi
index 26f23ac7264..1d62c530bd0 100644
--- a/man/info.texi
+++ b/man/info.texi
@@ -1,4 +1,7 @@
-\input texinfo @c -*-texinfo-*-
+\input texinfo.tex @c -*-texinfo-*-
+@c We must \input texinfo.tex instead of texinfo, otherwise make
+@c distcheck in the Texinfo distribution fails, because the texinfo Info
+@c file is made first, and texi2dvi must include . first in the path.
@comment %**start of header
@setfilename info.info
@settitle Info
@@ -6,13 +9,12 @@
@syncodeindex vr cp
@syncodeindex ky cp
@comment %**end of header
-@comment $Id: info.texi,v 1.33 2003/07/16 22:17:40 karl Exp $
@copying
This file describes how to use Info, the on-line, menu-driven GNU
documentation system.
-Copyright (C) 1989, 1992, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
+Copyright (C) 1989, 1992, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
@quotation
@@ -459,7 +461,7 @@ Now type @kbd{]}, to learn about the @kbd{]} and @kbd{[} commands.
@end menu
@node Help-], , , Help-Inv
-@subsection The @kbd{]} and @kbd{[} commands.
+@subsection The @kbd{]} and @kbd{[} commands
If you type @kbd{n} now, you get an error message saying that this
node has no next node. Similarly, if you type @kbd{p}, the error
@@ -829,12 +831,16 @@ between local and remote links.
The introductory course is almost over; please continue
a little longer to learn some intermediate-level commands.
- Most Info files have an index, which is actually a large node that
-contains nothing but a menu. The menu has one menu item for each
-topic listed in the index. You can find the index node from the main
-menu of the file, with the @kbd{m} command; then you can use the
-@kbd{m} command again in the index node to go to the node that
-describes the topic.
+ Most Info files have an index, which is actually a large node
+containing little but a menu. The menu has one menu item for each
+topic listed in the index. (As a special feature, menus for indices
+may also include the line number within the node of the index entry.
+This allows Info readers to go to the exact line of an entry, not just
+the start of the containing node.)
+
+ You can get to the index from the main menu of the file with the
+@kbd{m} command; then you can use the @kbd{m} command again in the
+index node to go to the node that describes the topic you want.
There is also a short-cut Info command, @kbd{i}, which does all of
that for you. It searches the index for a given topic (a string) and
@@ -933,7 +939,7 @@ Documentation Format}.
Here are some more Info commands that make it easier to move around.
-@unnumberedsubsec @kbd{g} goes to a node by name
+@subheading @kbd{g} goes to a node by name
@kindex g @r{(Info mode)}
@findex Info-goto-node
@@ -959,7 +965,7 @@ the node @samp{Top} in the Info file @file{dir}. Likewise,
all of the current file by typing @kbd{g*@key{RET}} or all of any
other file with @kbd{g(@var{filename})@key{RET}}.
-@unnumberedsubsec @kbd{1} -- @kbd{9} choose a menu subtopic by its number
+@subheading @kbd{1} -- @kbd{9} choose a menu subtopic by its number
@kindex 1 @r{through} 9 @r{(Info mode)}
@findex Info-nth-menu-item
@@ -973,17 +979,18 @@ In the stand-alone reader, @kbd{0} goes through the last menu item;
this is so you need not count how many entries are there. In Emacs,
the digit keys run the command @code{Info-nth-menu-item}.
- If your display supports multiple fonts, and you are using Emacs'
-Info mode to read Info files, the @samp{*} for the fifth menu item
-stands out, either in color or in some other attribute, such as
-underline, and so is the @samp{*} for the ninth item; this makes it
-easy to see at a glance which number to use for an item.
+ If your display supports multiple fonts, colors or underlining, and
+you are using Emacs' Info mode to read Info files, the third, sixth
+and ninth menu items have a @samp{*} that stands out, either in color
+or in some other attribute, such as underline; this makes it easy to
+see at a glance which number to use for an item.
- Some terminals don't support colors or underlining. If you need to
-actually count items, it is better to use @kbd{m} instead, and specify
-the name, or use @key{TAB} to quickly move between menu items.
+ Some terminals don't support either multiple fonts, colors or
+underlining. If you need to actually count items, it is better to use
+@kbd{m} instead, and specify the name, or use @key{TAB} to quickly
+move between menu items.
-@unnumberedsubsec @kbd{e} makes Info document editable
+@subheading @kbd{e} makes Info document editable
@kindex e @r{(Info mode)}
@findex Info-edit
@@ -998,6 +1005,23 @@ only if the variable @code{Info-enable-edit} is non-@code{nil}.
edit the Info file, so typing @kbd{e} there goes to the end of the
current node.
+@subheading @kbd{M-n} creates a new independent Info buffer in Emacs
+
+@kindex M-n @r{(Info mode)}
+@findex clone-buffer
+@cindex multiple Info buffers
+ If you are reading Info in Emacs, you can select a new independent
+Info buffer in another window by typing @kbd{M-n}. The new buffer
+starts out as an exact copy of the old one, but you will be able to
+move independently between nodes in the two buffers. (In Info mode,
+@kbd{M-n} runs the Emacs command @code{clone-buffer}.)
+
+ In Emacs Info, you can also produce new Info buffers by giving a
+numeric prefix argument to the @kbd{m} and @kbd{g} commands. @kbd{C-u
+m} and @kbd{C-u g} go to a new node in exactly the same way that
+@kbd{m} and @kbd{g} do, but they do so in a new Info buffer which they
+select in another window.
+
@node Info Search, Add, Advanced, Expert Info
@comment node-name, next, previous, up
@section How to search Info documents for specific subjects
@@ -1031,7 +1055,7 @@ you typed @emph{as a substring}. For each match, Info shows in the
echo area the full index entry it found. Often, the text of the full
index entry already gives you enough information to decide whether it
is relevant to what you are looking for, so we recommend that you read
-what Emacs shows in the echo are before looking at the node it
+what Emacs shows in the echo area before looking at the node it
displays.
Since @kbd{i} looks for a substring, you can search for subjects even
@@ -1046,12 +1070,18 @@ options, and key sequences that the program provides. If you are
looking for a description of a command, an option, or a key, just type
their names when @kbd{i} prompts you for a topic. For example, if you
want to read the description of what the @kbd{C-f} key does, type
-@kbd{iC-f@key{RET}}. Here @kbd{C-f} are 3 literal characters
+@kbd{i C - f @key{RET}}. Here @kbd{C-f} are 3 literal characters
@samp{C}, @samp{-}, and @samp{f}, not the ``Control-f'' command key
you type inside Emacs to run the command bound to @kbd{C-f}.
In Emacs, @kbd{i} runs the command @code{Info-index}.
+@findex info-apropos
+If you don't know what manual documents something, try the @kbd{M-x
+info-apropos} command. It prompts for a string and then looks up that
+string in all the indices of all the Info documents installed on your
+system.
+
@kindex s @r{(Info mode)}
@findex Info-search
The @kbd{s} command allows you to search a whole file for a string.
@@ -1456,3 +1486,7 @@ topics discussed in this document.
@printindex cp
@bye
+
+@ignore
+ arch-tag: 965c1638-01d6-4156-9227-b10418b9d8e8
+@end ignore
diff --git a/man/killing.texi b/man/killing.texi
index 4118a4c56f5..60b5129389d 100644
--- a/man/killing.texi
+++ b/man/killing.texi
@@ -152,8 +152,8 @@ what they ought to do, you need to tell Emacs which key to use for
@findex normal-erase-is-backspace-mode
On most text-only terminals, Emacs cannot tell which keys the
keyboard really has, so it follows a uniform plan which may or may not
-fit your keyboard. The uniform plan is that the ASCII @key{DEL}
-character deletes, and the ASCII @key{BS} (backspace) character asks
+fit your keyboard. The uniform plan is that the @acronym{ASCII} @key{DEL}
+character deletes, and the @acronym{ASCII} @key{BS} (backspace) character asks
for help (it is the same as @kbd{C-h}). If this is not right for your
keyboard, such as if you find that the key which ought to delete backwards
enters Help instead, see @ref{DEL Does Not Delete}.
@@ -644,3 +644,7 @@ rectangle shifts right.
The command @kbd{M-x string-insert-rectangle} is similar to
@code{string-rectangle}, but inserts the string on each line,
shifting the original text to the right.
+
+@ignore
+ arch-tag: d8da8f96-0928-449a-816e-ff2d3497866c
+@end ignore
diff --git a/man/m-x.texi b/man/m-x.texi
index fca7d101a97..8881850d323 100644
--- a/man/m-x.texi
+++ b/man/m-x.texi
@@ -73,3 +73,7 @@ together with following arguments.
@kbd{M-x} works by running the command
@code{execute-extended-command}, which is responsible for reading the
name of another command and invoking it.
+
+@ignore
+ arch-tag: b67bff53-9628-4666-b94e-eda972a7ba56
+@end ignore
diff --git a/man/macos.texi b/man/macos.texi
index 7a266697781..93045eb1044 100644
--- a/man/macos.texi
+++ b/man/macos.texi
@@ -51,7 +51,7 @@ uses the @key{option} key as the @key{META} key.
Most people should want to use the @key{command} key as the @key{META} key,
so that dead-key processing with the @key{option} key will still work. This is
-useful for entering non-ASCII Latin characters directly from the Mac
+useful for entering non-@acronym{ASCII} Latin characters directly from the Mac
keyboard, for example.
Emacs recognizes the setting in the Keyboard control panel and
@@ -244,3 +244,7 @@ returns the GNU or Unix equivalent. The function
@code{posix-file-name-to-mac} performs the opposite conversion. They
are useful for constructing AppleScript commands to be passed to
@code{do-applescript}.
+
+@ignore
+ arch-tag: a822c2ab-4273-4997-927e-c153bb71dcf6
+@end ignore
diff --git a/man/maintaining.texi b/man/maintaining.texi
index 9683ffa62d8..b5f13d5fb9f 100644
--- a/man/maintaining.texi
+++ b/man/maintaining.texi
@@ -1273,3 +1273,7 @@ commands.
@vindex emerge-startup-hook
After setting up the merge, Emerge runs the hook
@code{emerge-startup-hook} (@pxref{Hooks}).
+
+@ignore
+ arch-tag: b9d83dfb-82ea-4ff6-bab5-05a3617091fb
+@end ignore
diff --git a/man/major.texi b/man/major.texi
index 16887fe788a..4c933b13db0 100644
--- a/man/major.texi
+++ b/man/major.texi
@@ -169,3 +169,7 @@ However, this does not happen if the buffer contents specify a major
mode, and certain ``special'' major modes do not allow the mode to
change. You can turn off this mode-changing feature by setting
@code{change-major-mode-with-file-name} to @code{nil}.
+
+@ignore
+ arch-tag: f2558800-cf32-4839-8acb-7d3b4df2a155
+@end ignore
diff --git a/man/makefile.w32-in b/man/makefile.w32-in
new file mode 100644
index 00000000000..c0f1a82abc1
--- /dev/null
+++ b/man/makefile.w32-in
@@ -0,0 +1,329 @@
+#### Makefile for the Emacs Manual and other documentation.
+
+# Copyright (C) 2003
+# Free Software Foundation, Inc.
+
+# This file is part of GNU Emacs.
+
+# GNU Emacs is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# GNU Emacs is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with GNU Emacs; see the file COPYING. If not, write to
+# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+
+# Where to find the source code. The source code for Emacs's C kernel is
+# expected to be in $(srcdir)/src, and the source code for Emacs's
+# utility programs is expected to be in $(srcdir)/lib-src. This is
+# set by the configure script's `--srcdir' option.
+srcdir=.
+
+infodir = $(srcdir)/../info
+
+# The makeinfo program is part of the Texinfo distribution.
+MAKEINFO = makeinfo
+MULTI_INSTALL_INFO = $(srcdir)\..\nt\multi-install-info.bat
+INFO_TARGETS = $(infodir)/emacs $(infodir)/ccmode \
+ $(infodir)/cl $(infodir)/dired-x \
+ $(infodir)/ediff $(infodir)/forms \
+ $(infodir)/gnus $(infodir)/info \
+ $(infodir)/message $(infodir)/mh-e \
+ $(infodir)/reftex $(infodir)/sc \
+ $(infodir)/vip $(infodir)/viper \
+ $(infodir)/widget $(infodir)/efaq \
+ $(infodir)/ada-mode $(infodir)/autotype \
+ $(infodir)/calc $(infodir)/idlwave \
+ $(infodir)/eudc $(infodir)/ebrowse \
+ $(infodir)/pcl-cvs $(infodir)/woman \
+ $(infodir)/emacs-mime $(infodir)/eshell \
+ $(infodir)/speedbar $(infodir)/tramp \
+ $(infodir)/ses $(infodir)/smtpmail
+DVI_TARGETS = emacs.dvi calc.dvi cc-mode.dvi cl.dvi dired-x.dvi \
+ ediff.dvi forms.dvi gnus.dvi message.dvi mh-e.dvi \
+ reftex.dvi sc.dvi vip.dvi viper.dvi widget.dvi faq.dvi \
+ ada-mode.dvi autotype.dvi idlwave.dvi eudc.dvi ebrowse.dvi \
+ pcl-cvs.dvi woman.dvi emacs-mime.dvi eshell.dvi \
+ speedbar.dvi tramp.dvi ses.dvi smtpmail.dvi
+INFOSOURCES = info.texi
+
+# The following rule does not work with all versions of `make'.
+.SUFFIXES: .texi .dvi
+.texi.dvi:
+ texi2dvi $<
+
+TEXI2DVI = texi2dvi
+ENVADD = $(srcdir)\..\nt\envadd.bat "TEXINPUTS=$(srcdir);$(TEXINPUTS)" \
+ "MAKEINFO=$(MAKEINFO) -I$(srcdir)" /C
+
+EMACSSOURCES= \
+ $(srcdir)/emacs.texi \
+ $(srcdir)/doclicense.texi \
+ $(srcdir)/screen.texi \
+ $(srcdir)/commands.texi \
+ $(srcdir)/entering.texi \
+ $(srcdir)/basic.texi \
+ $(srcdir)/mini.texi \
+ $(srcdir)/m-x.texi \
+ $(srcdir)/help.texi \
+ $(srcdir)/mark.texi \
+ $(srcdir)/killing.texi \
+ $(srcdir)/regs.texi \
+ $(srcdir)/display.texi \
+ $(srcdir)/search.texi \
+ $(srcdir)/fixit.texi \
+ $(srcdir)/files.texi \
+ $(srcdir)/buffers.texi \
+ $(srcdir)/windows.texi \
+ $(srcdir)/frames.texi \
+ $(srcdir)/mule.texi \
+ $(srcdir)/major.texi \
+ $(srcdir)/indent.texi \
+ $(srcdir)/text.texi \
+ $(srcdir)/programs.texi \
+ $(srcdir)/building.texi \
+ $(srcdir)/maintaining.texi \
+ $(srcdir)/abbrevs.texi \
+ $(srcdir)/picture.texi \
+ $(srcdir)/sending.texi \
+ $(srcdir)/rmail.texi \
+ $(srcdir)/dired.texi \
+ $(srcdir)/calendar.texi \
+ $(srcdir)/misc.texi \
+ $(srcdir)/custom.texi \
+ $(srcdir)/trouble.texi \
+ $(srcdir)/cmdargs.texi \
+ $(srcdir)/xresources.texi \
+ $(srcdir)/anti.texi \
+ $(srcdir)/macos.texi \
+ $(srcdir)/msdog.texi \
+ $(srcdir)/gnu.texi \
+ $(srcdir)/glossary.texi \
+ $(srcdir)/ack.texi \
+ $(srcdir)/kmacro.texi
+
+info: $(INFO_TARGETS)
+ $(MULTI_INSTALL_INFO) --info-dir=$(infodir) $(INFO_TARGETS)
+
+dvi: $(DVI_TARGETS)
+
+# Note that all the Info targets build the Info files
+# in srcdir. There is no provision for Info files
+# to exist in the build directory.
+# In a distribution of Emacs, the Info files should be up to date.
+
+# The following target uses an explicit -o switch to work around
+# the @setfilename directive in info.texi, which is required for
+# the Texinfo distribution.
+
+$(infodir)/info: $(INFOSOURCES)
+ $(MAKEINFO) --no-split info.texi -o $@
+
+info.dvi: $(INFOSOURCES)
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/info.texi
+
+$(infodir)/emacs: $(EMACSSOURCES)
+ $(MAKEINFO) emacs.texi
+
+emacs.dvi: $(EMACSSOURCES)
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/emacs.texi
+
+# This target is here so you could easily get the list of the *.texi
+# files which belong to the Emacs manual (as opposed to the separate
+# manuals for CL, CC Mode, Ebrowse, etc.). With this target, you can
+# say things like "grep foo `make emacsman`".
+emacsman:
+ @echo $(EMACSSOURCES)
+
+$(infodir)/ccmode: cc-mode.texi
+ $(MAKEINFO) cc-mode.texi
+cc-mode.dvi: cc-mode.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/cc-mode.texi
+
+$(infodir)/ada-mode: ada-mode.texi
+ $(MAKEINFO) ada-mode.texi
+ada-mode.dvi: ada-mode.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/ada-mode.texi
+
+$(infodir)/pcl-cvs: pcl-cvs.texi
+ $(MAKEINFO) pcl-cvs.texi
+pcl-cvs.dvi: pcl-cvs.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/pcl-cvs.texi
+
+$(infodir)/eshell: eshell.texi
+ $(MAKEINFO) eshell.texi
+eshell.dvi: eshell.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/eshell.texi
+
+$(infodir)/cl: cl.texi
+ $(MAKEINFO) cl.texi
+cl.dvi: cl.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/cl.texi
+
+$(infodir)/dired-x: dired-x.texi
+ $(MAKEINFO) dired-x.texi
+dired-x.dvi: dired-x.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/dired-x.texi
+
+$(infodir)/ediff: ediff.texi
+ $(MAKEINFO) ediff.texi
+ediff.dvi: ediff.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/ediff.texi
+
+$(infodir)/forms: forms.texi
+ $(MAKEINFO) forms.texi
+forms.dvi: forms.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/forms.texi
+
+$(infodir)/gnus: gnus.texi
+ $(MAKEINFO) gnus.texi
+gnus.dvi: gnus.texi
+ sed -e '/@iflatex/,/@end iflatex/d' $(srcdir)/gnus.texi > gnustmp.texi
+ $(ENVADD) $(TEXI2DVI) gnustmp.texi
+ cp gnustmp.dvi $*.dvi
+ rm gnustmp.*
+
+$(infodir)/message: message.texi
+ $(MAKEINFO) message.texi
+message.dvi: message.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/message.texi
+
+$(infodir)/mh-e: mh-e.texi
+ $(MAKEINFO) mh-e.texi
+mh-e.dvi: mh-e.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/mh-e.texi
+
+$(infodir)/reftex: reftex.texi
+ $(MAKEINFO) reftex.texi
+reftex.dvi: reftex.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/reftex.texi
+
+$(infodir)/sc: sc.texi
+ $(MAKEINFO) sc.texi
+sc.dvi: sc.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/sc.texi
+
+$(infodir)/vip: vip.texi
+ $(MAKEINFO) vip.texi
+vip.dvi: vip.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/vip.texi
+
+$(infodir)/viper: viper.texi
+ $(MAKEINFO) viper.texi
+viper.dvi: viper.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/viper.texi
+
+$(infodir)/widget: widget.texi
+ $(MAKEINFO) widget.texi
+widget.dvi: widget.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/widget.texi
+
+$(infodir)/efaq: faq.texi
+ $(MAKEINFO) faq.texi
+faq.dvi: faq.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/faq.texi
+
+../etc/GNU: gnu1.texi gnu.texi
+ $(MAKEINFO) --no-headers -o ../etc/GNU gnu1.texi
+
+$(infodir)/autotype: autotype.texi
+ $(MAKEINFO) autotype.texi
+autotype.dvi: autotype.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/autotype.texi
+
+$(infodir)/calc: calc.texi
+ $(MAKEINFO) calc.texi
+
+calc.dvi: calc.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/calc.texi
+
+# This is produced with --no-split to avoid making files whose
+# names clash on DOS 8+3 filesystems
+$(infodir)/idlwave: idlwave.texi
+ $(MAKEINFO) --no-split idlwave.texi
+idlwave.dvi: idlwave.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/idlwave.texi
+
+$(infodir)/eudc: eudc.texi
+ $(MAKEINFO) eudc.texi
+eudc.dvi: eudc.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/eudc.texi
+
+$(infodir)/ebrowse: ebrowse.texi
+ $(MAKEINFO) ebrowse.texi
+ebrowse.dvi: ebrowse.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/ebrowse.texi
+
+$(infodir)/woman: woman.texi
+ $(MAKEINFO) woman.texi
+woman.dvi: woman.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/woman.texi
+
+$(infodir)/speedbar: speedbar.texi
+ $(MAKEINFO) speedbar.texi
+speedbar.dvi: speedbar.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/speedbar.texi
+
+$(infodir)/emacs-mime: emacs-mime.texi
+ $(MAKEINFO) emacs-mime.texi
+emacs-mime.dvi: emacs-mime.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/emacs-mime.texi
+
+$(infodir)/tramp: tramp.texi
+ $(MAKEINFO) tramp.texi
+tramp.dvi: tramp.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/tramp.texi
+
+$(infodir)/ses: ses.texi
+ $(MAKEINFO) ses.texi
+ses.dvi: ses.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/ses.texi
+
+$(infodir)/smtpmail: smtpmail.texi
+ $(MAKEINFO) smtpmail.texi
+smtpmail.dvi: smtpmail.texi
+ $(ENVADD) $(TEXI2DVI) $(srcdir)/smtpmail.texi
+
+mostlyclean:
+ - $(DEL) *.log *.cp *.fn *.ky *.pg *.vr core *.tp *.core gnustmp.*
+
+clean: mostlyclean
+ - $(DEL) *.dvi
+ - $(DEL) $(infodir)/emacs* $(infodir)/ccmode* \
+ $(infodir)/cl* $(infodir)/dired-x* \
+ $(infodir)/ediff* $(infodir)/forms* \
+ $(infodir)/gnus* $(infodir)/info* \
+ $(infodir)/message* $(infodir)/mh-e* \
+ $(infodir)/reftex* $(infodir)/sc* \
+ $(infodir)/vip* $(infodir)/viper* \
+ $(infodir)/widget* $(infodir)/efaq* \
+ $(infodir)/ada-mode* $(infodir)/autotype* \
+ $(infodir)/calc* $(infodir)/idlwave* \
+ $(infodir)/eudc* $(infodir)/ebrowse* \
+ $(infodir)/pcl-cvs* $(infodir)/woman* \
+ $(infodir)/emacs-mime* $(infodir)/eshell* \
+ $(infodir)/speedbar* $(infodir)/tramp* \
+ $(infodir)/ses* $(infodir)/smtpmail*
+
+distclean: clean
+
+maintainer-clean: distclean
+ - $(DEL) *.aux *.cps *.fns *.kys *.pgs *.vrs *.toc
+# Don't delete these, because they are outside the current directory.
+# for file in $(INFO_TARGETS); do rm -f $${file}*; done
+
+
+# Formerly this directory had texindex.c and getopt.c in it
+# and this makefile built them to make texindex.
+# That caused trouble because this is run entirely in the source directory.
+# Since we expect to get texi2dvi from elsewhere,
+# it is ok to expect texindex from elsewhere also.
+
+# arch-tag: 6e99da59-ad27-4816-82a0-cde9a101efae
diff --git a/man/mark.texi b/man/mark.texi
index ec91e66fb21..414fa470348 100644
--- a/man/mark.texi
+++ b/man/mark.texi
@@ -113,7 +113,7 @@ the new position with point back at its original position.
@ref{Mark Ring}.
@kindex C-@@
- There is no such character as @kbd{C-@key{SPC}} in ASCII; when you
+ There is no such character as @kbd{C-@key{SPC}} in @acronym{ASCII}; when you
type @key{SPC} while holding down @key{CTRL}, what you get on most
ordinary terminals is the character @kbd{C-@@}. This key is actually
bound to @code{set-mark-command}. But unless you are unlucky enough to
@@ -425,3 +425,6 @@ the buffer and position of the latest entry in the global ring. It also
rotates the ring, so that successive uses of @kbd{C-x C-@key{SPC}} take
you to earlier and earlier buffers.
+@ignore
+ arch-tag: f35e4d82-911b-4cfc-a3d7-3c87b2abba20
+@end ignore
diff --git a/man/message.texi b/man/message.texi
index d26ae9a5e33..41c563ca383 100644
--- a/man/message.texi
+++ b/man/message.texi
@@ -1410,3 +1410,7 @@ basis of the new @code{Cc} header, except if this header is
@bye
@c End:
+
+@ignore
+ arch-tag: 16ab76af-a281-4e34-aed6-5624569f7601
+@end ignore
diff --git a/man/mh-e.texi b/man/mh-e.texi
index 406506d36a0..77fcbbc7254 100644
--- a/man/mh-e.texi
+++ b/man/mh-e.texi
@@ -1,5 +1,4 @@
\input texinfo @c -*-texinfo-*-
-@c $Id: mh-e.texi,v 1.13 2002/10/02 23:24:31 karl Exp $
@c %**start of header
@setfilename ../info/mh-e
@settitle mh-e
@@ -16,7 +15,7 @@ This is Edition @value{EDITION}, last updated @value{UPDATED}, of
@cite{mh-e, The Emacs Interface to MH}, for mh-e, Version
@value{VERSION}.
-Copyright 1995, 2001, 2002 Free Software Foundation, Inc.
+Copyright 1995, 2001, 2002, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -3952,3 +3951,7 @@ Public License instead of this License.
@c XXX In the sections on customizing mh-e, you can add cross-references
@c to the Emacs manual and the Emacs Lisp manual wherever they are
@c useful. @pxref{node, , section, emacs, The GNU Emacs Manual}
+
+@ignore
+ arch-tag: b778477d-1a10-4a99-84de-f877a2ea6bef
+@end ignore
diff --git a/man/mini.texi b/man/mini.texi
index 88aac3bdc74..040306ba041 100644
--- a/man/mini.texi
+++ b/man/mini.texi
@@ -206,10 +206,10 @@ Completion does ignore case distinctions for certain arguments in which
case does not matter.
@menu
-* Example: Completion Example.
-* Commands: Completion Commands.
-* Strict Completion::
-* Options: Completion Options.
+* Example: Completion Example. Examples of using completion.
+* Commands: Completion Commands. A list of completion commands.
+* Strict Completion:: Different types of completion.
+* Options: Completion Options. Options for completion.
@end menu
@node Completion Example
@@ -571,3 +571,7 @@ list in the variable @code{command-history}. Each element is a Lisp
expression which describes one command and its arguments. Lisp programs
can re-execute a command by calling @code{eval} with the
@code{command-history} element.
+
+@ignore
+ arch-tag: ba913cfd-b70e-400f-b663-22b2c309227f
+@end ignore
diff --git a/man/misc.texi b/man/misc.texi
index 520bcb66869..83c86a1867a 100644
--- a/man/misc.texi
+++ b/man/misc.texi
@@ -526,9 +526,9 @@ before point in the shell buffer
@item C-d
@kindex C-d @r{(Shell mode)}
@findex comint-delchar-or-maybe-eof
-Either delete a character or send @sc{eof}
+Either delete a character or send @acronym{EOF}
(@code{comint-delchar-or-maybe-eof}). Typed at the end of the shell
-buffer, @kbd{C-d} sends @sc{eof} to the subshell. Typed at any other
+buffer, @kbd{C-d} sends @acronym{EOF} to the subshell. Typed at any other
position in the buffer, @kbd{C-d} deletes a character as usual.
@item C-c C-a
@@ -1502,13 +1502,13 @@ printable using the fonts built into your printer. You can augment
the fonts supplied with the printer with those from the GNU Intlfonts
package, or you can instruct Emacs to use Intlfonts exclusively. The
variable @code{ps-multibyte-buffer} controls this: the default value,
-@code{nil}, is appropriate for printing ASCII and Latin-1
+@code{nil}, is appropriate for printing @acronym{ASCII} and Latin-1
characters; a value of @code{non-latin-printer} is for printers which
-have the fonts for ASCII, Latin-1, Japanese, and Korean
+have the fonts for @acronym{ASCII}, Latin-1, Japanese, and Korean
characters built into them. A value of @code{bdf-font} arranges for
the BDF fonts from the Intlfonts package to be used for @emph{all}
characters. Finally, a value of @code{bdf-font-except-latin}
-instructs the printer to use built-in fonts for ASCII and Latin-1
+instructs the printer to use built-in fonts for @acronym{ASCII} and Latin-1
characters, and Intlfonts BDF fonts for the rest.
@vindex bdf-directory-list
@@ -1531,7 +1531,7 @@ identify a @dfn{sort key} for each record, and then reorder the records
into the order determined by the sort keys. The records are ordered so
that their keys are in alphabetical order, or, for numeric sorting, in
numeric order. In alphabetic sorting, all upper-case letters `A' through
-`Z' come before lower-case `a', in accord with the ASCII character
+`Z' come before lower-case `a', in accord with the @acronym{ASCII} character
sequence.
The various sort commands differ in how they divide the text into sort
@@ -1875,55 +1875,44 @@ hexl-@key{RET}} for details.
@cindex reload files
@cindex desktop
- You can use the Desktop library to save the state of Emacs from one
-session to another. Saving the state means that Emacs starts up with
-the same set of buffers, major modes, buffer positions, and so on that
-the previous Emacs session had.
+ Use the desktop library to save the state of Emacs from one session
+to another. Once you save the Emacs @dfn{desktop}---the buffers,
+their file names, major modes, buffer positions, and so on---then
+subsequent Emacs sessions reload the saved desktop.
-@vindex desktop-enable
- To use Desktop, you should use the Customization buffer (@pxref{Easy
-Customization}) to set @code{desktop-enable} to a non-@code{nil} value,
-or add these lines at the end of your @file{.emacs} file:
+@findex desktop-save
+@vindex desktop-save-mode
+ You can save the desktop manually with the command @kbd{M-x
+desktop-save}. You can also enable automatical desktop saving when
+you exit Emacs: use the Customization buffer (@pxref{Easy
+Customization}) to set @code{desktop-save-mode} to @code{t} for future
+sessions, or add this line in your @file{~/.emacs} file:
@example
-(desktop-load-default)
-(desktop-read)
+(desktop-save-mode 1)
@end example
-@noindent
-@findex desktop-save
-The first time you save the state of the Emacs session, you must do it
-manually, with the command @kbd{M-x desktop-save}. Once you have done
-that, exiting Emacs will save the state again---not only the present
-Emacs session, but also subsequent sessions. You can also save the
-state at any time, without exiting Emacs, by typing @kbd{M-x
-desktop-save} again.
-
- In order for Emacs to recover the state from a previous session, you
-must start it with the same current directory as you used when you
-started the previous session. This is because @code{desktop-read} looks
-in the current directory for the file to read. This means that you can
-have separate saved sessions in different directories; the directory in
-which you start Emacs will control which saved session to use.
-
-@vindex desktop-files-not-to-save
- The variable @code{desktop-files-not-to-save} controls which files are
-excluded from state saving. Its value is a regular expression that
-matches the files to exclude. By default, remote (ftp-accessed) files
-are excluded; this is because visiting them again in the subsequent
-session would be slow. If you want to include these files in state
-saving, set @code{desktop-files-not-to-save} to @code{"^$"}.
-@xref{Remote Files}.
-
-@vindex save-place
-@cindex Saveplace
-@findex toggle-save-place
- The Saveplace library provides a simpler feature that records your
-position in each file when you kill its buffer (or kill Emacs), and
-jumps to the same position when you visit the file again (even in
-another Emacs session). Use @kbd{M-x toggle-save-place} to turn on
-place-saving in a given file. Customize the option @code{save-place}
-to turn it on for all files in each session.
+@findex desktop-change-dir
+@findex desktop-revert
+ When Emacs starts, it looks for a saved desktop in the current
+directory. Thus, you can have separate saved desktops in different
+directories, and the starting directory determines which one Emacs
+reloads. You can save the current desktop and reload one saved in
+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.
+
+@findex desktop-clear
+@vindex desktop-globals-to-clear
+@vindex desktop-clear-preserve-buffers-regexp
+ Type @kbd{M-x desktop-clear} to empty the Emacs desktop. This kills
+all buffers except for internal ones, and clears the global variables
+listed in @code{desktop-globals-to-clear}. If you want this to
+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.
@node Recursive Edit, Emulation, Saving Emacs Sessions, Top
@section Recursive Editing Levels
@@ -2183,9 +2172,10 @@ which you might like to bind to keys, such as
@code{browse-url-browser-function}. You can invoke actions dependent
on the type of URL by defining @code{browse-url-browser-function} as
an association list. The package's commentary available via @kbd{C-h
-p} provides more information. Packages with facilities for following
-URLs should always go through Browse-URL, so that the customization
-options for Browse-URL will affect all browsing in Emacs.
+p} under the @samp{hypermedia} keyword provides more information.
+Packages with facilities for following URLs should always go through
+Browse-URL, so that the customization options for Browse-URL will
+affect all browsing in Emacs.
@node Goto-address
@subsection Activating URLs
@@ -2232,14 +2222,14 @@ view it.
This feature is useful for following references in mail or news
buffers, @file{README} files, @file{MANIFEST} files, and so on. The
-@samp{ffap} package's commentary available via @kbd{C-h p} and the
-@code{ffap} Custom group provide details.
+@samp{ffap} package's commentary available via @kbd{C-h p} under the
+@samp{files} keyword and the @code{ffap} Custom group provide details.
@cindex FFAP minor mode
@findex ffap-mode
- You can turn on FFAP minor mode to make the following key bindings
-and to install hooks for using @code{ffap} in Rmail, Gnus and VM
-article buffers.
+ You can turn on FFAP minor mode by calling @code{ffap-bindings} to
+make the following key bindings and to install hooks for using
+@code{ffap} in Rmail, Gnus and VM article buffers.
@table @kbd
@item C-x C-f @var{filename} @key{RET}
@@ -2450,3 +2440,7 @@ Likewise, @kbd{M-x snake} provides an implementation of Snake.
@findex zone
The command @kbd{M-x zone} plays games with the display when Emacs is
idle.
+
+@ignore
+ arch-tag: 8f094220-c0d5-4e9e-af7d-3e0da8187474
+@end ignore
diff --git a/man/msdog.texi b/man/msdog.texi
index 6be4f703f79..e701ba9fc75 100644
--- a/man/msdog.texi
+++ b/man/msdog.texi
@@ -141,7 +141,7 @@ the clipboard, and displays in the echo area a message to that effect.
@vindex dos-display-scancodes
The variable @code{dos-display-scancodes}, when non-@code{nil},
-directs Emacs to display the ASCII value and the keyboard scan code of
+directs Emacs to display the @acronym{ASCII} value and the keyboard scan code of
each keystroke; this feature serves as a complement to the
@code{view-lossage} command, for debugging.
@@ -466,7 +466,7 @@ Windows to capture a specific printer port such as @code{"LPT2"}, and
redirect it to a networked printer via the @w{@code{Control
Panel->Printers}} applet instead of @samp{net use}.
- Some printers expect DOS codepage encoding of non-ASCII text, even
+ Some printers expect DOS codepage encoding of non-@acronym{ASCII} text, even
though they are connected to a Windows machine which uses a different
encoding for the same locale. For example, in the Latin-1 locale, DOS
uses codepage 850 whereas Windows uses codepage 1252. @xref{MS-DOS and
@@ -594,7 +594,7 @@ Create a coding system for a certain DOS codepage.
MS-DOS is designed to support one character set of 256 characters at
any given time, but gives you a variety of character sets to choose
from. The alternative character sets are known as @dfn{DOS codepages}.
-Each codepage includes all 128 ASCII characters, but the other 128
+Each codepage includes all 128 @acronym{ASCII} characters, but the other 128
characters (codes 128 through 255) vary from one codepage to another.
Each DOS codepage is identified by a 3-digit number, such as 850, 862,
etc.
@@ -614,7 +614,7 @@ executables on other systems such as MS-Windows.
@cindex unibyte operation @r{(MS-DOS)}
If you invoke Emacs on MS-DOS with the @samp{--unibyte} option
(@pxref{Initial Options}), Emacs does not perform any conversion of
-non-ASCII characters. Instead, it reads and writes any non-ASCII
+non-@acronym{ASCII} characters. Instead, it reads and writes any non-@acronym{ASCII}
characters verbatim, and sends their 8-bit codes to the display
verbatim. Thus, unibyte Emacs on MS-DOS supports the current codepage,
whatever it may be, but cannot even represent any other characters.
@@ -668,7 +668,7 @@ language environment for that script (@pxref{Language Environments}).
If a buffer contains a character belonging to some other ISO 8859
character set, not the one that the chosen DOS codepage supports, Emacs
-displays it using a sequence of ASCII characters. For example, if the
+displays it using a sequence of @acronym{ASCII} characters. For example, if the
current codepage doesn't have a glyph for the letter @samp{@`o} (small
@samp{o} with a grave accent), it is displayed as @samp{@{`o@}}, where
the braces serve as a visual indication that this is a single character.
@@ -843,3 +843,6 @@ subsequent commands. Many users find this frustrating.
You can reenable Windows's default handling of tapping the @key{ALT} key
by setting @code{w32-pass-alt-to-system} to a non-@code{nil} value.
+@ignore
+ arch-tag: f39d2590-5dcc-4318-88d9-0eb73ca10fa2
+@end ignore
diff --git a/man/mule.texi b/man/mule.texi
index ccba75e9327..86349c0b40e 100644
--- a/man/mule.texi
+++ b/man/mule.texi
@@ -49,8 +49,8 @@ all the related activities:
@itemize @bullet
@item
-You can visit files with non-ASCII characters, save non-ASCII text, and
-pass non-ASCII text between Emacs and programs it invokes (such as
+You can visit files with non-@acronym{ASCII} characters, save non-@acronym{ASCII} text, and
+pass non-@acronym{ASCII} text between Emacs and programs it invokes (such as
compilers, spell-checkers, and mailers). Setting your language
environment (@pxref{Language Environments}) takes care of setting up the
coding systems and other options for a specific language or culture.
@@ -58,7 +58,7 @@ Alternatively, you can specify how Emacs should encode or decode text
for each command; see @ref{Specify Coding}.
@item
-You can display non-ASCII characters encoded by the various scripts.
+You can display non-@acronym{ASCII} characters encoded by the various scripts.
This works by using appropriate fonts on X and similar graphics
displays (@pxref{Defining Fontsets}), and by sending special codes to
text-only displays (@pxref{Specify Coding}). If some characters are
@@ -66,12 +66,12 @@ displayed incorrectly, refer to @ref{Undisplayable Characters}, which
describes possible problems and explains how to solve them.
@item
-You can insert non-ASCII characters or search for them. To do that,
+You can insert non-@acronym{ASCII} characters or search for them. To do that,
you can specify an input method (@pxref{Select Input Method}) suitable
for your language, or use the default input method set up when you set
your language environment. (Emacs input methods are part of the Leim
package, which must be installed for you to be able to use them.) If
-your keyboard can produce non-ASCII characters, you can select an
+your keyboard can produce non-@acronym{ASCII} characters, you can select an
appropriate keyboard coding system (@pxref{Specify Coding}), and Emacs
will accept those characters. Latin-1 characters can also be input by
using the @kbd{C-x 8} prefix, see @ref{Single-Byte Character Support,
@@ -110,7 +110,7 @@ correctly; see @ref{Language Environments, locales}.
many more-or-less standard coding systems for storing files. Emacs
internally uses a single multibyte character encoding, so that it can
intermix characters from all these scripts in a single buffer or string.
-This encoding represents each non-ASCII character as a sequence of bytes
+This encoding represents each non-@acronym{ASCII} character as a sequence of bytes
in the range 0200 through 0377. Emacs translates between the multibyte
character encoding and various other coding systems when reading and
writing files, when exchanging data with subprocesses, and (in some
@@ -187,11 +187,11 @@ in that buffer.
@cindex Lisp files, and multibyte operation
@cindex multibyte operation, and Lisp files
@cindex unibyte operation, and Lisp files
-@cindex init file, and non-ASCII characters
-@cindex environment variables, and non-ASCII characters
+@cindex init file, and non-@acronym{ASCII} characters
+@cindex environment variables, and non-@acronym{ASCII} characters
With @samp{--unibyte}, multibyte strings are not created during
initialization from the values of environment variables,
-@file{/etc/passwd} entries etc.@: that contain non-ASCII 8-bit
+@file{/etc/passwd} entries etc.@: that contain non-@acronym{ASCII} 8-bit
characters.
Emacs normally loads Lisp files as multibyte, regardless of whether
@@ -282,7 +282,7 @@ and selects the corresponding language environment if a match is found.
(The former variable overrides the latter.) It also adjusts the display
table and terminal coding system, the locale coding system, the
preferred coding system as needed for the locale, and---last but not
-least---the way Emacs decodes non-ASCII characters sent by your keyboard.
+least---the way Emacs decodes non-@acronym{ASCII} characters sent by your keyboard.
If you modify the @env{LC_ALL}, @env{LC_CTYPE}, or @env{LANG}
environment variables while running Emacs, you may want to invoke the
@@ -346,14 +346,14 @@ has its own input method; sometimes several languages which use the same
characters can share one input method. A few languages support several
input methods.
- The simplest kind of input method works by mapping ASCII letters
+ The simplest kind of input method works by mapping @acronym{ASCII} letters
into another alphabet; this allows you to use one other alphabet
-instead of ASCII. The Greek and Russian input methods
+instead of @acronym{ASCII}. The Greek and Russian input methods
work this way.
A more powerful technique is composition: converting sequences of
characters into one letter. Many European input methods use composition
-to produce a single non-ASCII letter from a sequence that consists of a
+to produce a single non-@acronym{ASCII} letter from a sequence that consists of a
letter followed by accent characters (or vice versa). For example, some
methods convert the sequence @kbd{a'} into a single accented letter.
These input methods have no special commands of their own; all they do
@@ -480,8 +480,8 @@ language environment that it is meant to be used with. The variable
@findex toggle-input-method
@kindex C-\
- Input methods use various sequences of ASCII characters to stand for
-non-ASCII characters. Sometimes it is useful to turn off the input
+ Input methods use various sequences of @acronym{ASCII} characters to stand for
+non-@acronym{ASCII} characters. Sometimes it is useful to turn off the input
method temporarily. To do this, type @kbd{C-\}
(@code{toggle-input-method}). To reenable the input method, type
@kbd{C-\} again.
@@ -534,11 +534,11 @@ list-input-methods}. The list gives information about each input
method, including the string that stands for it in the mode line.
@node Multibyte Conversion
-@section Unibyte and Multibyte Non-ASCII characters
+@section Unibyte and Multibyte Non-@acronym{ASCII} characters
When multibyte characters are enabled, character codes 0240 (octal)
through 0377 (octal) are not really legitimate in the buffer. The valid
-non-ASCII printing characters have codes that start from 0400.
+non-@acronym{ASCII} printing characters have codes that start from 0400.
If you type a self-inserting character in the range 0240 through
0377, or if you use @kbd{C-q} to insert one, Emacs assumes you
@@ -590,7 +590,7 @@ other coding system. For example, to visit a file encoded in codepage
850, type @kbd{C-x @key{RET} c cp850 @key{RET} C-x C-f @var{filename}
@key{RET}}.
- In addition to converting various representations of non-ASCII
+ In addition to converting various representations of non-@acronym{ASCII}
characters, a coding system can perform end-of-line conversion. Emacs
handles three different conventions for how to separate lines in a file:
newline, carriage-return linefeed, and just carriage-return.
@@ -661,8 +661,8 @@ variants @code{iso-latin-1-unix}, @code{iso-latin-1-dos} and
@code{iso-latin-1-mac}.
The coding system @code{raw-text} is good for a file which is mainly
-ASCII text, but may contain byte values above 127 which are not meant to
-encode non-ASCII characters. With @code{raw-text}, Emacs copies those
+@acronym{ASCII} text, but may contain byte values above 127 which are not meant to
+encode non-@acronym{ASCII} characters. With @code{raw-text}, Emacs copies those
byte values unchanged, and sets @code{enable-multibyte-characters} to
@code{nil} in the current buffer so that they will be interpreted
properly. @code{raw-text} handles end-of-line conversion in the usual
@@ -670,7 +670,7 @@ way, based on the data encountered, and has the usual three variants to
specify the kind of end-of-line conversion to use.
In contrast, the coding system @code{no-conversion} specifies no
-character code conversion at all---none for non-ASCII byte values and
+character code conversion at all---none for non-@acronym{ASCII} byte values and
none for end of line. This is useful for reading or writing binary
files, tar files, and other files that must be examined verbatim. It,
too, sets @code{enable-multibyte-characters} to @code{nil}.
@@ -681,7 +681,7 @@ the @kbd{M-x find-file-literally} command. This uses
might convert the file contents before you see them. @xref{Visiting}.
The coding system @code{emacs-mule} means that the file contains
-non-ASCII characters stored with the internal Emacs encoding. It
+non-@acronym{ASCII} characters stored with the internal Emacs encoding. It
handles end-of-line conversion based on the data encountered, and has
the usual three variants to specify the kind of end-of-line conversion.
@@ -774,7 +774,7 @@ the buffer.
The default value of @code{inhibit-iso-escape-detection} is
@code{nil}. We recommend that you not change it permanently, only for
one specific operation. That's because many Emacs Lisp source files
-in the Emacs distribution contain non-ASCII characters encoded in the
+in the Emacs distribution contain non-@acronym{ASCII} characters encoded in the
coding system @code{iso-2022-7bit}, and they won't be
decoded correctly when you visit those files if you suppress the
escape sequence detection.
@@ -817,7 +817,7 @@ of the mode line (@pxref{Mode Line}), or type @kbd{C-h C @key{RET}}.
@findex unify-8859-on-decoding-mode
The command @code{unify-8859-on-decoding-mode} enables a mode that
``unifies'' the Latin alphabets when decoding text. This works by
-converting all non-ASCII Latin-@var{n} characters to either Latin-1 or
+converting all non-@acronym{ASCII} Latin-@var{n} characters to either Latin-1 or
Unicode characters. This way it is easier to use various
Latin-@var{n} alphabets together. In a future Emacs version we hope
to move towards full Unicode support and complete unification of
@@ -837,7 +837,7 @@ Coding}).
most coding systems can only handle some of the possible characters.
This means that it is possible for you to insert characters that
cannot be encoded with the coding system that will be used to save the
-buffer. For example, you could start with an ASCII file and insert a
+buffer. For example, you could start with an @acronym{ASCII} file and insert a
few Latin-1 characters into it, or you could edit a text file in
Polish encoded in @code{iso-8859-2} and add some Russian words to it.
When you save the buffer, Emacs cannot use the current value of
@@ -917,6 +917,12 @@ subprocess input and output in the current buffer.
Use coding system @var{coding} for transferring selections to and from
other programs through the window system.
+@item C-x @key{RET} F @var{coding} @key{RET}
+Use coding system @var{coding} for encoding and decoding file
+@emph{names}. This affects the use of non-ASCII characters in file
+names. It has no effect on reading and writing the @emph{contents} of
+files.
+
@item C-x @key{RET} X @var{coding} @key{RET}
Use coding system @var{coding} for transferring @emph{one}
selection---the next one---to or from the window system.
@@ -993,13 +999,13 @@ your locale specification (@pxref{Language Environments}).
or the Custom option @code{keyboard-coding-system}
specifies the coding system for keyboard input. Character-code
translation of keyboard input is useful for terminals with keys that
-send non-ASCII graphic characters---for example, some terminals designed
+send non-@acronym{ASCII} graphic characters---for example, some terminals designed
for ISO Latin-1 or subsets of it.
By default, keyboard input is translated based on your system locale
setting. If your terminal does not really support the encoding
implied by your locale (for example, if you find it inserts a
-non-ASCII character if you type @kbd{M-i}), you will need to set
+non-@acronym{ASCII} character if you type @kbd{M-i}), you will need to set
@code{keyboard-coding-system} to @code{nil} to turn off encoding.
You can do this by putting
@@ -1014,7 +1020,7 @@ in your @file{~/.emacs} file.
keyboard input, and using an input method: both define sequences of
keyboard input that translate into single characters. However, input
methods are designed to be convenient for interactive use by humans, and
-the sequences that are translated are typically sequences of ASCII
+the sequences that are translated are typically sequences of @acronym{ASCII}
printing characters. Coding systems typically translate sequences of
non-graphic characters.
@@ -1043,17 +1049,21 @@ corresponding buffer.
current language environment.
@vindex file-name-coding-system
-@cindex file names with non-ASCII characters
- The variable @code{file-name-coding-system} specifies a coding system
-to use for encoding file names. If you set the variable to a coding
-system name (as a Lisp symbol or a string), Emacs encodes file names
-using that coding system for all file operations. This makes it
-possible to use non-ASCII characters in file names---or, at least, those
-non-ASCII characters which the specified coding system can encode.
+@cindex file names with non-@acronym{ASCII} characters
+@findex set-file-name-coding-system
+@kindex C-x @key{RET} F
+ The variable @code{file-name-coding-system} specifies a coding
+system to use for encoding file names. If you set the variable to a
+coding system name (as a Lisp symbol or a string), Emacs encodes file
+names using that coding system for all file operations. This makes it
+possible to use non-@acronym{ASCII} characters in file names---or, at
+least, those non-@acronym{ASCII} characters which the specified coding
+system can encode. Use @kbd{C-x @key{RET} F}
+(@code{set-file-name-coding-system}) to specify this interactively.
If @code{file-name-coding-system} is @code{nil}, Emacs uses a default
coding system determined by the selected language environment. In the
-default language environment, any non-ASCII characters in file names are
+default language environment, any non-@acronym{ASCII} characters in file names are
not encoded specially; they appear in the file system using the internal
Emacs representation.
@@ -1067,11 +1077,11 @@ name, or it may get an error. If such a problem happens, use @kbd{C-x
C-w} to specify a new file name for that buffer.
@vindex locale-coding-system
-@cindex decoding non-ASCII keyboard input on X
+@cindex decoding non-@acronym{ASCII} keyboard input on X
The variable @code{locale-coding-system} specifies a coding system
to use when encoding and decoding system strings such as system error
messages and @code{format-time-string} formats and time stamps. That
-coding system is also used for decoding non-ASCII keyboard input on X
+coding system is also used for decoding non-@acronym{ASCII} keyboard input on X
Window systems. You should choose a coding system that is compatible
with the underlying system's text representation, which is normally
specified by one of the environment variables @env{LC_ALL},
@@ -1101,7 +1111,7 @@ additional font support.}
Emacs creates two fontsets automatically: the @dfn{standard fontset}
and the @dfn{startup fontset}. The standard fontset is most likely to
-have fonts for a wide variety of non-ASCII characters; however, this is
+have fonts for a wide variety of non-@acronym{ASCII} characters; however, this is
not the default for Emacs to use. (By default, Emacs tries to find a
font that has bold and italic variants.) You can specify use of the
standard fontset with the @samp{-fn} option, or with the @samp{Font} X
@@ -1137,7 +1147,7 @@ created automatically. Their names have @samp{bold} instead of
@samp{medium}, or @samp{i} instead of @samp{r}, or both.
@cindex startup fontset
- If you specify a default ASCII font with the @samp{Font} resource or
+ If you specify a default @acronym{ASCII} font with the @samp{Font} resource or
the @samp{-fn} argument, Emacs generates a fontset from it
automatically. This is the @dfn{startup fontset} and its name is
@code{fontset-startup}. It does this by replacing the @var{foundry},
@@ -1191,7 +1201,7 @@ number of times in defining one fontset.
For the other character sets, Emacs chooses a font based on
@var{fontpattern}. It replaces @samp{fontset-@var{alias}} with values
-that describe the character set. For the ASCII character font,
+that describe the character set. For the @acronym{ASCII} character font,
@samp{fontset-@var{alias}} is replaced with @samp{ISO8859-1}.
In addition, when several consecutive fields are wildcards, Emacs
@@ -1208,7 +1218,7 @@ does.
@end example
@noindent
-the font specification for ASCII characters would be this:
+the font specification for @acronym{ASCII} characters would be this:
@example
-*-fixed-medium-r-normal-*-24-*-ISO8859-1
@@ -1247,7 +1257,7 @@ call this function explicitly to create a fontset.
@node Undisplayable Characters
@section Undisplayable Characters
- There may be a some non-ASCII characters that your terminal cannot
+ There may be a some non-@acronym{ASCII} characters that your terminal cannot
display. Most non-windowing terminals support just a single character
set (use the variable @code{default-terminal-coding-system}
(@pxref{Specify Coding}) to tell Emacs which one); characters which
@@ -1259,15 +1269,15 @@ you may not have fonts installed for all of them; characters that have
no font appear as a hollow box.
If you use Latin-1 characters but your terminal can't display
-Latin-1, you can arrange to display mnemonic ASCII sequences
+Latin-1, you can arrange to display mnemonic @acronym{ASCII} sequences
instead, e.g.@: @samp{"o} for o-umlaut. Load the library
@file{iso-ascii} to do this.
@vindex latin1-display
If your terminal can display Latin-1, you can display characters
from other European character sets using a mixture of equivalent
-Latin-1 characters and ASCII mnemonics. Use the Custom option
-@code{latin1-display} to enable this. The mnemonic ASCII
+Latin-1 characters and @acronym{ASCII} mnemonics. Use the Custom option
+@code{latin1-display} to enable this. The mnemonic @acronym{ASCII}
sequences mostly correspond to those of the prefix input methods.
@node Single-Byte Character Support
@@ -1288,7 +1298,7 @@ such as @samp{Latin-@var{n}}.
For more information about unibyte operation, see @ref{Enabling
Multibyte}. Note particularly that you probably want to ensure that
-your initialization files are read as unibyte if they contain non-ASCII
+your initialization files are read as unibyte if they contain non-@acronym{ASCII}
characters.
@vindex unibyte-display-via-language-environment
@@ -1302,7 +1312,7 @@ to a non-@code{nil} value.
@cindex @code{iso-ascii} library
If your terminal does not support display of the Latin-1 character
-set, Emacs can display these characters as ASCII sequences which at
+set, Emacs can display these characters as @acronym{ASCII} sequences which at
least give you a clear idea of what the characters are. To do this,
load the library @code{iso-ascii}. Similar libraries for other
Latin-@var{n} character sets could be implemented, but we don't have
@@ -1315,14 +1325,14 @@ inclusive) are displayed as octal escapes. You can change this for
non-standard ``extended'' versions of ISO-8859 character sets by using the
function @code{standard-display-8bit} in the @code{disp-table} library.
- There are several ways you can input single-byte non-ASCII
+ There are several ways you can input single-byte non-@acronym{ASCII}
characters:
@itemize @bullet
@cindex 8-bit input
@item
If your keyboard can generate character codes 128 (decimal) and up,
-representing non-ASCII characters, you can type those character codes
+representing non-@acronym{ASCII} characters, you can type those character codes
directly.
On a windowing terminal, you should not need to do anything special to
@@ -1339,7 +1349,7 @@ arrange for Meta to be converted to @kbd{ESC} and still be able type
@item
You can use an input method for the selected language environment.
@xref{Input Methods}. When you use an input method in a unibyte buffer,
-the non-ASCII character you specify with it is converted to unibyte.
+the non-@acronym{ASCII} character you specify with it is converted to unibyte.
@kindex C-x 8
@cindex @code{iso-transl} library
@@ -1348,7 +1358,7 @@ the non-ASCII character you specify with it is converted to unibyte.
@item
For Latin-1 only, you can use the
key @kbd{C-x 8} as a ``compose character'' prefix for entry of
-non-ASCII Latin-1 printing characters. @kbd{C-x 8} is good for
+non-@acronym{ASCII} Latin-1 printing characters. @kbd{C-x 8} is good for
insertion (in the minibuffer as well as other buffers), for searching,
and in any other context where a key sequence is allowed.
@@ -1380,7 +1390,7 @@ mode is buffer-local. It can be customized for various languages with
Emacs groups all supported characters into disjoint @dfn{charsets}.
Each character code belongs to one and only one charset. For
historical reasons, Emacs typically divides an 8-bit character code
-for an extended version of ASCII into two charsets: ASCII, which
+for an extended version of @acronym{ASCII} into two charsets: @acronym{ASCII}, which
covers the codes 0 through 127, plus another charset which covers the
``right-hand part'' (the codes 128 and up). For instance, the
characters of Latin-1 include the Emacs charset @code{ascii} plus the
@@ -1404,3 +1414,7 @@ its internal representation within Emacs.
To find out which charset a character in the buffer belongs to,
put point before it and type @kbd{C-u C-x =}.
+
+@ignore
+ arch-tag: 310ba60d-31ef-4ce7-91f1-f282dd57b6b3
+@end ignore
diff --git a/man/pcl-cvs.texi b/man/pcl-cvs.texi
index 04952efd3cb..427707fe4b5 100644
--- a/man/pcl-cvs.texi
+++ b/man/pcl-cvs.texi
@@ -1,5 +1,4 @@
\input texinfo @c -*-texinfo-*-
-@c "@(#)$Name: $:$Id: pcl-cvs.texi,v 1.18 2002/12/07 13:38:26 pj Exp $"
@c %**start of header
@setfilename ../info/pcl-cvs
@settitle PCL-CVS --- Emacs Front-End to CVS
@@ -8,7 +7,7 @@
@copying
Copyright @copyright{} 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-1999, 2000, 2002 Free Software Foundation, Inc.
+1999, 2000, 2002, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -477,7 +476,7 @@ although it has not been @samp{cvs remove}d.
Many of the commands work on the current set of @dfn{selected} files
which can be either the set of marked files (if any file is marked and
-marks are no ignored) or whichever file or directory the cursor is on.
+marks are not ignored) or whichever file or directory the cursor is on.
If a directory is selected but the command cannot be applied to a
directory, then it will be applied to the set of files under this
@@ -1088,7 +1087,7 @@ revision.
This command use @code{ediff} (or @code{emerge}, see above) to allow you
to do an interactive 3-way merge.
-@strong{Note:} When the file status is @samp{Conflict},
+@strong{Please note:} when the file status is @samp{Conflict},
CVS has already performed a merge. The resulting file is not used in
any way if you use this command. If you use the @kbd{q} command inside
@samp{ediff} (to successfully terminate a merge) the file that CVS
@@ -1193,7 +1192,7 @@ kill the contents of the buffer with @kbd{C-w}.
If you work by writing entries in the @file{ChangeLog}
(@pxref{(emacs)Change Log}) and then commit the change under revision
control, you can generate the Log Edit text from the ChangeLog using
-@kbd{C-a C-a} (@kbd{log-edit-insert-changelog}). This looks for
+@kbd{C-c C-a} (@kbd{log-edit-insert-changelog}). This looks for
entries for the file(s) concerned in the top entry in the ChangeLog
and uses those paragraphs as the log text. This text is only inserted
if the top entry was made under your user name on the current date.
@@ -1443,3 +1442,7 @@ this manual.
@summarycontents
@contents
@bye
+
+@ignore
+ arch-tag: 5c7178ce-56fa-40b0-abd7-f4a09758b235
+@end ignore
diff --git a/man/picture.texi b/man/picture.texi
index e792878ae46..e62962b0ff7 100644
--- a/man/picture.texi
+++ b/man/picture.texi
@@ -261,3 +261,7 @@ other modes. @kbd{C-c C-y} (@code{picture-yank-rectangle}) inserts
(by overwriting) the rectangle that was most recently killed, while
@kbd{C-c C-x} (@code{picture-yank-rectangle-from-register}) does
likewise for the rectangle found in a specified register.
+
+@ignore
+ arch-tag: b7589747-683c-4f40-aed8-1b10403cb666
+@end ignore
diff --git a/man/programs.texi b/man/programs.texi
index a6fa49b2ec7..84f3e6f14f8 100644
--- a/man/programs.texi
+++ b/man/programs.texi
@@ -486,49 +486,10 @@ expression.
@cindex @code{lisp-indent-function} property
You can override the standard pattern in various ways for individual
-functions, according to the @code{lisp-indent-function} property of the
-function name. There are four possibilities for this property:
-
-@table @asis
-@item @code{nil}
-This is the same as no property---use the standard indentation pattern.
-@item @code{defun}
-Handle this function like a @samp{def} construct: treat the second
-line as the start of a @dfn{body}.
-@item a number, @var{number}
-The first @var{number} arguments of the function are
-@dfn{distinguished} arguments; the rest are considered the body
-of the expression. A line in the expression is indented according to
-whether the first argument on it is distinguished or not. If the
-argument is part of the body, the line is indented @code{lisp-body-indent}
-more columns than the open-parenthesis starting the containing
-expression. If the argument is distinguished and is either the first
-or second argument, it is indented @emph{twice} that many extra columns.
-If the argument is distinguished and not the first or second argument,
-the line uses the standard pattern.
-@item a symbol, @var{symbol}
-@var{symbol} should be a function name; that function is called to
-calculate the indentation of a line within this expression. The
-function receives two arguments:
-@table @asis
-@item @var{state}
-The value returned by @code{parse-partial-sexp} (a Lisp primitive for
-indentation and nesting computation) when it parses up to the
-beginning of this line.
-@item @var{pos}
-The position at which the line being indented begins.
-@end table
-@noindent
-It should return either a number, which is the number of columns of
-indentation for that line, or a list whose car is such a number. The
-difference between returning a number and returning a list is that a
-number says that all following lines at the same nesting level should
-be indented just like this one; a list says that following lines might
-call for different indentations. This makes a difference when the
-indentation is being computed by @kbd{C-M-q}; if the value is a
-number, @kbd{C-M-q} need not recalculate indentation for the following
-lines until the end of the list.
-@end table
+functions, according to the @code{lisp-indent-function} property of
+the function name. Normally you would use this for macro definitions
+and specify it using the @code{declare} construct (@pxref{Defining
+Macros,,, elisp, the Emacs Lisp Reference Manual}).
@node C Indent
@subsection Commands for C Indentation
@@ -680,6 +641,7 @@ Kill balanced expression forward (@code{kill-sexp}).
@item C-M-t
Transpose expressions (@code{transpose-sexps}).
@item C-M-@@
+@itemx C-M-@key{SPC}
Put mark after following expression (@code{mark-sexp}).
@end table
@@ -740,12 +702,14 @@ rather than doing nothing, transposes the balanced expressions ending
at or after point and the mark.
@kindex C-M-@@
+@kindex C-M-@key{SPC}
@findex mark-sexp
To set the region around the next balanced expression in the buffer,
use @kbd{C-M-@@} (@code{mark-sexp}), which sets mark at the same place
that @kbd{C-M-f} would move to. @kbd{C-M-@@} takes arguments like
@kbd{C-M-f}. In particular, a negative argument is useful for putting
the mark at the beginning of the previous balanced expression.
+The alias @kbd{C-M-@key{SPC}} is equivalent to @kbd{C-M-@@}.
In languages that use infix operators, such as C, it is not possible
to recognize all balanced expressions as such because there can be
@@ -1437,8 +1401,8 @@ Mode}). The Foldout package provides folding-editor features
This section gives a brief description of the special features
available in C, C++, Objective-C, Java, CORBA IDL, and Pike modes.
-(These are called ``C mode and related modes.'') @xref{Top, CC Mode,
-ccmode, , CC Mode}, for a more extensive description of these modes
+(These are called ``C mode and related modes.'') @xref{Top, , CC Mode,
+ccmode, CC Mode}, for a more extensive description of these modes
and their special features.
@menu
@@ -2322,3 +2286,7 @@ Insert or align a comment.
The variable @code{asm-comment-char} specifies which character
starts comments in assembler syntax.
+
+@ignore
+ arch-tag: c7ee7409-40a4-45c7-bfb7-ae7f2c74d0c0
+@end ignore
diff --git a/man/reftex.texi b/man/reftex.texi
index 449efce9ce5..b1c4ae561ba 100644
--- a/man/reftex.texi
+++ b/man/reftex.texi
@@ -5591,3 +5591,6 @@ part does not reset the chapter counter. See new option
@contents
@bye
+@ignore
+ arch-tag: 1e055774-0576-4b1b-b47f-550d0961fd43
+@end ignore
diff --git a/man/regs.texi b/man/regs.texi
index 1ec319e5282..ab1ef42e2f1 100644
--- a/man/regs.texi
+++ b/man/regs.texi
@@ -319,3 +319,7 @@ points to.
Insert in the buffer the @emph{contents} of the file that bookmark
@var{bookmark} points to.
@end table
+
+@ignore
+ arch-tag: b00af991-ebc3-4b3a-8e82-a3ac81ff2e64
+@end ignore
diff --git a/man/rmail.texi b/man/rmail.texi
index 9e6db0b9df5..23eef5abec8 100644
--- a/man/rmail.texi
+++ b/man/rmail.texi
@@ -1007,7 +1007,7 @@ clicking on them with @kbd{Mouse-2} or by moving to one and typing
@section Rmail and Coding Systems
@cindex decoding mail messages (Rmail)
- Rmail automatically decodes messages which contain non-ASCII
+ Rmail automatically decodes messages which contain non-@acronym{ASCII}
characters, just as Emacs does with files you visit and with subprocess
output. Rmail uses the standard @samp{charset=@var{charset}} header in
the message, if any, to determine how the message was encoded by the
@@ -1230,3 +1230,7 @@ this, and you would rather read your mail in the order in which it was
received, you can tell @code{movemail} to reverse the order of
downloaded messages by adding the @samp{-r} flag to
@code{rmail-movemail-flags}.
+
+@ignore
+ arch-tag: 034965f6-38df-47a2-a9f1-b8bc8ab37e23
+@end ignore
diff --git a/man/sc.texi b/man/sc.texi
index c9f03d8f906..5e911e2df72 100644
--- a/man/sc.texi
+++ b/man/sc.texi
@@ -2521,3 +2521,7 @@ its @var{variable} name.
@summarycontents
@contents
@bye
+
+@ignore
+ arch-tag: 0521847a-4680-44b6-ae6e-13ce20e18436
+@end ignore
diff --git a/man/screen.texi b/man/screen.texi
index 2f5b66936be..b2632fefd5d 100644
--- a/man/screen.texi
+++ b/man/screen.texi
@@ -189,7 +189,7 @@ other windows; see @ref{Optional Mode Line}, for more about this.
Normally, the mode line looks like this:
@example
--@var{cs}:@var{ch} @var{buf} @var{line} @var{pos} (@var{major} @var{minor})------
+-@var{cs}:@var{ch} @var{buf} @var{pos} @var{line} (@var{major} @var{minor})------
@end example
@noindent
@@ -211,19 +211,20 @@ cursor is in) is also Emacs's current buffer, the one that editing
takes place in. When we speak of what some command does to ``the
buffer,'' we are talking about the current buffer.
- @var{line} is @samp{L} followed by the current line number of point.
-This is present when Line Number mode is enabled (which it normally is).
-You can optionally display the current column number too, by turning on
-Column Number mode (which is not enabled by default because it is
-somewhat slower). @xref{Optional Mode Line}.
-
@var{pos} tells you whether there is additional text above the top of
the window, or below the bottom. If your buffer is small and it is all
visible in the window, @var{pos} is @samp{All}. Otherwise, it is
@samp{Top} if you are looking at the beginning of the buffer, @samp{Bot}
if you are looking at the end of the buffer, or @samp{@var{nn}%}, where
-@var{nn} is the percentage of the buffer above the top of the
-window.@refill
+@var{nn} is the percentage of the buffer above the top of the window.
+With Size Indication mode, you can display the size of the buffer as
+well. @xref{Optional Mode Line}.
+
+ @var{line} is @samp{L} followed by the current line number of point.
+This is present when Line Number mode is enabled (which it normally is).
+You can optionally display the current column number too, by turning on
+Column Number mode (which is not enabled by default because it is
+somewhat slower). @xref{Optional Mode Line}.
@var{major} is the name of the @dfn{major mode} in effect in the
buffer. At any time, each buffer is in one and only one of the possible
@@ -303,8 +304,9 @@ formats by setting each of the variables @code{eol-mnemonic-unix},
@xref{Variables}, for an explanation of how to set variables.
@xref{Optional Mode Line}, for features that add other handy
-information to the mode line, such as the current column number of
-point, the current time, and whether new mail for you has arrived.
+information to the mode line, such as the size of the buffer, the
+current column number of point, the current time, and whether new mail
+for you has arrived.
The mode line is mouse-sensitive; when you move the mouse across
various parts of it, Emacs displays help text to say what a click in
@@ -347,3 +349,7 @@ can type the item's letter or digit to select the item.
Some of the commands in the menu bar have ordinary key bindings as
well; if so, the menu lists one equivalent key binding in parentheses
after the item itself.
+
+@ignore
+ arch-tag: 104ba40e-d972-4866-a542-a98be94bdf2f
+@end ignore
diff --git a/man/search.texi b/man/search.texi
index ea08626a6ab..303074dcf0d 100644
--- a/man/search.texi
+++ b/man/search.texi
@@ -19,14 +19,15 @@ more flexible replacement command called @code{query-replace}, which
asks interactively which occurrences to replace.
@menu
-* Incremental Search:: Search happens as you type the string.
-* Nonincremental Search:: Specify entire string and then search.
-* Word Search:: Search for sequence of words.
-* Regexp Search:: Search for match for a regexp.
-* Regexps:: Syntax of regular expressions.
-* Search Case:: To ignore case while searching, or not.
-* Replace:: Search, and replace some or all matches.
-* Other Repeating Search:: Operating on all matches for some regexp.
+* Incremental Search:: Search happens as you type the string.
+* Nonincremental Search:: Specify entire string and then search.
+* Word Search:: Search for sequence of words.
+* Regexp Search:: Search for match for a regexp.
+* Regexps:: Syntax of regular expressions.
+* Search Case:: To ignore case while searching, or not.
+* Configuring Scrolling:: Scrolling within incremental search.
+* Replace:: Search, and replace some or all matches.
+* Other Repeating Search:: Operating on all matches for some regexp.
@end menu
@node Incremental Search, Nonincremental Search, Search, Search
@@ -122,9 +123,9 @@ following character to be treated the way any ``ordinary'' character is
treated in the same context. You can also specify a character by its
octal code: enter @kbd{C-q} followed by a sequence of octal digits.
-@cindex searching for non-ASCII characters
+@cindex searching for non-@acronym{ASCII} characters
@cindex input method, during incremental search
- To search for non-ASCII characters, you must use an input method
+ To search for non-@acronym{ASCII} characters, you must use an input method
(@pxref{Input Methods}). If an input method is enabled in the
current buffer when you start the search, you can use it while you
type the search string also. Emacs indicates that by including the
@@ -226,6 +227,34 @@ alter their bindings in the keymap @code{isearch-mode-map}. For a list
of bindings, look at the documentation of @code{isearch-mode} with
@kbd{C-h f isearch-mode @key{RET}}.
+@subsection Scrolling During Incremental Search
+
+ Vertical scrolling during incremental search can be enabled by
+setting the customizable variable @code{isearch-allow-scroll} to a
+non-nil value.
+
+ You can then use the vertical scroll-bar or certain keyboard
+commands such as @kbd{@key{PRIOR}} (@code{scroll-down}),
+@kbd{@key{NEXT}} (@code{scroll-up}) and @kbd{C-l} (@code{recenter})
+within the search, thus letting you see more of the text near the
+current match. You must run these commands via their key sequences to
+stay in the search - typing M-x @var{comand-name} will always
+terminate a search.
+
+ You can give prefix arguments to these commands in the usual way.
+The current match cannot be scrolled out of the window - this is
+intentional.
+
+ Several other commands, such as @kbd{C-x 2}
+(@code{split-window-vertically}) and @kbd{C-x ^}
+(@code{enlarge-window}) which don't scroll the window, are
+nevertheless made available under this rubric, since they are likewise
+handy during a search.
+
+ For a list of commands which are configured as scrolling commands by
+default and instructions on how thus to configure other commands, see
+@ref{Configuring Scrolling}.
+
@subsection Slow Terminal Incremental Search
Incremental search on a slow terminal uses a modified style of display
@@ -505,9 +534,9 @@ matches @samp{cr}, @samp{car}, @samp{cdr}, @samp{caddaar}, etc.
You can also include character ranges in a character set, by writing the
starting and ending characters with a @samp{-} between them. Thus,
-@samp{[a-z]} matches any lower-case ASCII letter. Ranges may be
+@samp{[a-z]} matches any lower-case @acronym{ASCII} letter. Ranges may be
intermixed freely with individual characters, as in @samp{[a-z$%.]},
-which matches any lower-case ASCII letter or @samp{$}, @samp{%} or
+which matches any lower-case @acronym{ASCII} letter or @samp{$}, @samp{%} or
period.
Note that the usual regexp special characters are not special inside a
@@ -531,7 +560,7 @@ is somewhat ill-defined, and it may change in future Emacs versions.
@item @kbd{[^ @dots{} ]}
@samp{[^} begins a @dfn{complemented character set}, which matches any
character except the ones specified. Thus, @samp{[^a-z0-9A-Z]} matches
-all characters @emph{except} ASCII letters and digits.
+all characters @emph{except} @acronym{ASCII} letters and digits.
@samp{^} is not special in a character set unless it is the first
character. The character following the @samp{^} is treated as if it
@@ -547,10 +576,18 @@ beginning of a line in the text being matched. Otherwise it fails to
match anything. Thus, @samp{^foo} matches a @samp{foo} that occurs at
the beginning of a line.
+For historical compatibility reasons, @samp{^} can be used with this
+meaning only at the beginning of the regular expression, or after
+@samp{\(} or @samp{\|}.
+
@item @kbd{$}
is similar to @samp{^} but matches only at the end of a line. Thus,
@samp{x+$} matches a string of one @samp{x} or more at the end of a line.
+For historical compatibility reasons, @samp{$} can be used with this
+meaning only at the end of the regular expression, or before @samp{\)}
+or @samp{\|}.
+
@item @kbd{\}
has two functions: it quotes the special characters (including
@samp{\}), and it introduces additional special constructs.
@@ -762,7 +799,7 @@ colors, Emacs blinks the cursor around the matched text, as it does
for matching parens.)
@end ignore
-@node Search Case, Replace, Regexps, Search
+@node Search Case, Configuring Scrolling, Regexps, Search
@section Searching and Case
Incremental searches in Emacs normally ignore the case of the text
@@ -792,7 +829,82 @@ This variable applies to nonincremental searches also, including those
performed by the replace commands (@pxref{Replace}) and the minibuffer
history matching commands (@pxref{Minibuffer History}).
-@node Replace, Other Repeating Search, Search Case, Search
+@node Configuring Scrolling, Replace, Search Case, Search
+@section Configuring Scrolling
+@cindex scrolling in incremental search
+@vindex isearch-allow-scroll
+
+Scrolling, etc., during incremental search is enabled by setting the
+customizable variable @code{isearch-allow-scroll} to a non-nil value.
+
+@c See Subject: Info file: How do I get an itemized list without blank lines?
+@c Date: Sat, 12 Apr 2003 09:45:31 +0000 in gnu.emacs.help
+@subsection Standard scrolling commands
+Here is the list of commands which are configured by default to be
+``scrolling'' commands in an incremental search, together with their
+usual bindings:
+@subsubsection Commands which scroll the window:
+@table @asis
+@item @code{scroll-bar-toolkit-scroll} (@kbd{@key{vertical-scroll-bar}@key{mouse-1}} in X-Windows)
+@itemx @code{mac-handle-scroll-bar-event} (@kbd{@key{vertical-scroll-bar}@key{mouse-1}} on a Mac)
+@itemx @code{w32-handle-scroll-bar-event} (@kbd{@key{vertical-scroll-bar}@key{mouse-1}} in MS-Windows)
+@item @code{recenter} (@kbd{C-l}) @xref{Scrolling}.
+@itemx @code{reposition-window} (@kbd{C-M-l}) @xref{Scrolling}.
+@itemx @code{scroll-up} (@kbd{@key{NEXT}}) @xref{Scrolling}.
+@itemx @code{scroll-down} (@kbd{@key{PRIOR}}) @xref{Scrolling}.
+@end table
+
+@subsubsection Commands which act on the other window:
+@table @asis
+@item @code{list-buffers} (@kbd{C-x C-b}) @xref{List Buffers}.
+@itemx @code{scroll-other-window} (@kbd{C-M-v}) @xref{Other Window}.
+@itemx @code{scroll-other-window-down} (@kbd{C-M-S-v}) @xref{Other Window}.
+@itemx @code{beginning-of-buffer-other-window} (@kbd{M-@key{home}})
+@itemx @code{end-of-buffer-other-window} (@kbd{M-@key{end}})
+@end table
+
+@subsubsection Commands which change the window layout:
+@table @asis
+@item @code{delete-other-windows} (@kbd{C-x 1}) @xref{Change Window}.
+@itemx @code{balance-windows} (@kbd{C-x +}) @xref{Change Window}.
+@itemx @code{split-window-vertically} (@kbd{C-x 2}) @xref{Split Window}.
+@itemx @code{enlarge-window} (@kbd{C-x ^}) @xref{Change Window}.
+@end table
+
+@subsection Configuring other commands as scrolling commands
+To do this, set a command's isearch-scroll property to the value t.
+For example:
+
+@example
+@code{(put 'my-command 'isearch-scroll t)}
+@end example
+
+You should only thus configure commands which are ``safe'': i.e., they
+won't leave emacs in an inconsistent state when executed within a
+search - that is to say, the following things may be changed by a
+command only temporarily, and must be restored before the command
+finishes:
+
+@enumerate
+@item
+Point.
+@item
+The buffer contents.
+@item
+The selected window and selected frame.
+@item
+The current match-data @xref{Match Data,,,elisp}.
+@end enumerate
+
+Additionally, the command must not delete the current window and must
+not itself attempt an incremental search. It may, however, change the
+window's size, or create or delete other windows and frames.
+
+Note that an attempt by a command to scroll the text
+@emph{horizontally} won't work, although it will do no harm - any such
+scrolling will be overriden and nullified by the display code.
+
+@node Replace, Other Repeating Search, Configuring Scrolling, Search
@section Replacement Commands
@cindex replacement
@cindex search-and-replace commands
@@ -814,10 +926,10 @@ parallel using the command @code{expand-region-abbrevs}
(@pxref{Expanding Abbrevs}).
@menu
-* Unconditional Replace:: Replacing all matches for a string.
-* Regexp Replace:: Replacing all matches for a regexp.
-* Replacement and Case:: How replacements preserve case of letters.
-* Query Replace:: How to use querying.
+* Unconditional Replace:: Replacing all matches for a string.
+* Regexp Replace:: Replacing all matches for a regexp.
+* Replacement and Case:: How replacements preserve case of letters.
+* Query Replace:: How to use querying.
@end menu
@node Unconditional Replace, Regexp Replace, Replace, Replace
@@ -1121,3 +1233,7 @@ instead.
(@pxref{Tags Search}) or through Dired @kbd{A} command
(@pxref{Operating on Files}), or ask the @code{grep} program to do it
(@pxref{Grep Searching}).
+
+@ignore
+ arch-tag: fd9d8e77-66af-491c-b212-d80999613e3e
+@end ignore
diff --git a/man/sending.texi b/man/sending.texi
index 502663a3520..5bc54294cf9 100644
--- a/man/sending.texi
+++ b/man/sending.texi
@@ -427,7 +427,7 @@ twice.
@c This is indexed in mule.texi, node "Recognize Coding".
@c @vindex sendmail-coding-system
- When you send a message that contains non-ASCII characters, they need
+ When you send a message that contains non-@acronym{ASCII} characters, they need
to be encoded with a coding system (@pxref{Coding Systems}). Usually
the coding system is specified automatically by your chosen language
environment (@pxref{Language Environments}). You can explicitly specify
@@ -687,7 +687,7 @@ message into outgoing mail. To do this, add
and sending mail---Mail mode. Emacs has alternative facilities for
editing and sending mail, including
MH-E and Message mode, not documented in this manual.
-@xref{Top,,MH-E,mh-e, The Emacs Interface to MH}. @xref{Top,,,message,
+@xref{Top,,MH-E,mh-e, The Emacs Interface to MH}. @xref{Top,,Message,message,
Message Manual}. You can choose any of them as your preferred method.
The commands @code{C-x m}, @code{C-x 4 m} and @code{C-x 5 m} use
whichever agent you have specified, as do various other Emacs commands
@@ -703,3 +703,7 @@ and facilities that send mail.
in this chapter about the @samp{*mail*} buffer and Mail mode does not
apply; the other methods use a different format of text in a different
buffer, and their commands are different as well.
+
+@ignore
+ arch-tag: d8a3dfc3-5d87-45c5-a7f2-69871b8e4fd6
+@end ignore
diff --git a/man/ses.texi b/man/ses.texi
index d280b14cc28..e5f8059fd2a 100644
--- a/man/ses.texi
+++ b/man/ses.texi
@@ -385,11 +385,11 @@ list.
@code{ses-mode-hook} is a normal mode hook (list of functions to
execute when starting SES mode for a buffer).
-The variable @code{safe-functions} is a a list of possibly-unsafe
+The variable @code{safe-functions} is a list of possibly-unsafe
functions to be treated as safe when analysing formulas and printers.
@xref{Virus protection}. Before customizing @code{safe-functions},
think about how much you trust the person who's suggesting this
-change. The value t turns off all anti-virus protection. A
+change. The value @code{t} turns off all anti-virus protection. A
list-of-functions value might enable a ``gee whiz'' spreadsheet, but it
also creates trapdoors in your anti-virus armor. In order for virus
protection to work, you must always press @kbd{n} when presented with
@@ -406,11 +406,15 @@ safety belts!
@table @kbd
@item C-c M-C-h
-(@code{ses-read-header-row}). The header line at the top of the SES
+(@code{ses-set-header-row}). The header line at the top of the SES
window normally shows the column letter for each column. You can set
it to show a copy of some row, such as a row of column titles, so that
-row will always be visible. Set the header line to row 0 to show
-column letters again.
+row will always be visible. Default is to set the current row as the
+header; use C-u to prompt for header row. Set the header to row 0 to
+show column letters again.
+@item [header-line mouse-3]
+Pops up a menu to set the current row as the header, or revert to
+column letters.
@end table
@menu
@@ -816,6 +820,13 @@ cell.
@node Acknowledgements, , For Gurus, Top
@chapter Acknowledgements
+Coding by:
+@quotation
+Jonathan Yavner @email{jyavner@@member.fsf.org}@*
+Stefan Monnier @email{monnier@@gnu.org}
+@end quotation
+
+Ideas from:
@quotation
Christoph Conrad @email{christoph.conrad@@gmx.de}@*
CyberBob @email{cyberbob@@redneck.gacracker.org}@*
@@ -824,7 +835,7 @@ Ami Fischman @email{fischman@@zion.bpnetworks.com}@*
Thomas Gehrlein @email{Thomas.Gehrlein@@t-online.de}@*
Chris F.A. Johnson @email{c.f.a.johnson@@rogers.com}@*
Yusong Li @email{lyusong@@hotmail.com}@*
-Yuri Linkov @email{link0ff@@yahoo.com}@*
+Juri Linkov @email{juri@@jurta.org}@*
Harald Maier @email{maierh@@myself.com}@*
Alan Nash @email{anash@@san.rr.com}@*
François Pinard @email{pinard@@iro.umontreal.ca}@*
@@ -832,6 +843,7 @@ Pedro Pinto @email{ppinto@@cs.cmu.edu}@*
Stefan Reichör @email{xsteve@@riic.at}@*
Oliver Scholz @email{epameinondas@@gmx.de}@*
Richard M. Stallman @email{rms@@gnu.org}@*
+Luc Teirlinck @email{teirllm@@dms.auburn.edu}@*
J. Otto Tennant @email{jotto@@pobox.com}@*
Jean-Philippe Theberge @email{jphil@@acs.pagesjaunes.fr}
@end quotation
@@ -839,3 +851,7 @@ Jean-Philippe Theberge @email{jphil@@acs.pagesjaunes.fr}
@c ===================================================================
@bye
+
+@ignore
+ arch-tag: 10a4ee1c-7ef4-4c06-8b7a-f975e39f0dec
+@end ignore
diff --git a/man/smtpmail.texi b/man/smtpmail.texi
index f1074dd1000..08ce87ac995 100644
--- a/man/smtpmail.texi
+++ b/man/smtpmail.texi
@@ -3,7 +3,7 @@
@settitle Emacs SMTP Library
@syncodeindex vr fn
@copying
-Copyright @copyright{} 2003 Free Software Foundation, Inc.
+Copyright @copyright{} 2003, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -207,7 +207,6 @@ The following example illustrates what you could put in
@cindex SASL
@cindex CRAM-MD5
-@cindex PLAIN
@cindex LOGIN
@cindex STARTTLS
Many environments require SMTP clients to authenticate themselves
@@ -215,15 +214,14 @@ before they are allowed to route mail via a server. The two following
variables contains the authentication information needed for this.
The first variable, @code{smtpmail-auth-credentials}, instructs the
SMTP library to use a SASL authentication step, currently only the
-CRAM-MD5, PLAIN and LOGIN-MD5 mechanisms are supported and will be
-selected in that order if the server supports them. The second
-variable, @code{smtpmail-starttls-credentials}, instructs the SMTP
-library to connect to the server using STARTTLS. This means the
-protocol exchange can be integrity protected and confidential by using
-TLS, and optionally also authentication of the client. It is common
-to use both these mechanisms, e.g., to use STARTTLS to achieve
-integrity and confidentiality and then use SASL for client
-authentication.
+CRAM-MD5 and LOGIN mechanisms are supported and will be selected in
+that order if the server supports them. The second variable,
+@code{smtpmail-starttls-credentials}, instructs the SMTP library to
+connect to the server using STARTTLS. This means the protocol
+exchange can be integrity protected and confidential by using TLS, and
+optionally also authentication of the client. It is common to use
+both these mechanisms, e.g., to use STARTTLS to achieve integrity and
+confidentiality and then use SASL for client authentication.
@table @code
@item smtpmail-auth-credentials
@@ -385,3 +383,7 @@ cannot accept mail.
@contents
@bye
+
+@ignore
+ arch-tag: 6316abdf-b366-4562-87a2-f37e8f894b6f
+@end ignore
diff --git a/man/speedbar.texi b/man/speedbar.texi
index 3b5e827fdcb..246aa1b7caf 100644
--- a/man/speedbar.texi
+++ b/man/speedbar.texi
@@ -1,12 +1,11 @@
\input texinfo @c -*-texinfo-*-
-@c $Id: speedbar.texi,v 1.10 2002/03/16 19:33:21 eliz Exp $
@setfilename ../info/speedbar
@settitle Speedbar: File/Tag summarizing utility
@syncodeindex fn cp
@copying
-Copyright @copyright{} 1999, 2000, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 1999, 2000, 2002, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -648,10 +647,6 @@ You can click on any stack element and gdb will move to that stack
level. You can then check variables local to that level at the GDB
prompt.
-This mode has the unfortunate side-effect of breaking GDB's repeat
-feature when you hit @kbd{RET} since your previous command is overridden
-with a stack fetching command.
-
@node Customizing, Extending, Minor Modes, Top
@comment node-name, next, previous, up
@chapter Customizing
@@ -1247,3 +1242,7 @@ Two good values are @code{nil} and @code{'statictag}.
@bye
@c LocalWords: speedbar's xref slowbar kbd subsubsection
@c LocalWords: keybindings
+
+@ignore
+ arch-tag: e1fc85f0-1eeb-489f-a8d4-a2bfe711fa02
+@end ignore
diff --git a/man/texinfo.tex b/man/texinfo.tex
index 35b3020e628..27f804eb55f 100644
--- a/man/texinfo.tex
+++ b/man/texinfo.tex
@@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
-\def\texinfoversion{2002-06-04.06}
+\def\texinfoversion{2003-10-06.16}
%
% Copyright (C) 1985, 86, 88, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99,
% 2000, 01, 02 Free Software Foundation, Inc.
@@ -6339,3 +6339,7 @@ should work if nowhere else does.}
@c time-stamp-format: "%:y-%02m-%02d.%02H"
@c time-stamp-end: "}"
@c End:
+
+@ignore
+ arch-tag: e1b36e32-c96e-4135-a41a-0b2efa2ea115
+@end ignore
diff --git a/man/text.texi b/man/text.texi
index bf68558d869..45c7e504d8a 100644
--- a/man/text.texi
+++ b/man/text.texi
@@ -312,7 +312,7 @@ pages.
@cindex pages
@cindex formfeed
Files are often thought of as divided into @dfn{pages} by the
-@dfn{formfeed} character (ASCII control-L, octal code 014). When you
+@dfn{formfeed} character (@acronym{ASCII} control-L, octal code 014). When you
print hardcopy for a file, this character forces a page break; thus,
each page of the file goes on a separate page on paper. Most Emacs
commands treat the page-separator character just like any other
@@ -2198,7 +2198,7 @@ Make the region right-filled (@code{set-justification-right}).
@kindex M-j f @r{(Enriched mode)}
@findex set-justification-full
@item M-j f
-Make the region fully-justified (@code{set-justification-full}).
+Make the region fully justified (@code{set-justification-full}).
@kindex M-j c @r{(Enriched mode)}
@kindex M-S @r{(Enriched mode)}
@findex set-justification-center
@@ -2277,3 +2277,6 @@ uncompression (@pxref{Compressed Files}). To disable format conversion
but allow character code conversion and/or automatic uncompression if
appropriate, use @code{format-find-file} with suitable arguments.
+@ignore
+ arch-tag: 8db54ed8-2036-49ca-b0df-23811d03dc70
+@end ignore
diff --git a/man/tramp.texi b/man/tramp.texi
index 07cffe26137..7e21b9c691f 100644
--- a/man/tramp.texi
+++ b/man/tramp.texi
@@ -30,10 +30,10 @@
@end macro
@copying
-Copyright @copyright{} 1999, 2000, 2001, 2002, 2003 Free Software
+Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004 Free Software
Foundation, Inc.
-@quotation
+@quotation
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1 or
any later version published by the Free Software Foundation; with no
@@ -54,10 +54,10 @@ license to the document, as described in section 6 of the license.
@end copying
@c Entries for @command{install-info} to use
-@dircategory Emacs
+@dircategory @value{emacs-name}
@direntry
* TRAMP: (tramp). Transparent Remote Access, Multiple Protocol
- Emacs remote file access via rsh and rcp.
+ @value{emacs-name} remote file access via rsh and rcp.
@end direntry
@tex
@@ -102,22 +102,33 @@ You can find the latest version of this document on the web at
@end ifset
@ifhtml
-This manual is also available as a @uref{tramp_ja.html, Japanese
-translation}.
+@ifset jamanual
+This manual is also available as a @uref{@value{japanese-manual},
+Japanese translation}.
+@end ifset
The latest release of @tramp{} is available for
-@uref{http://savannah.gnu.org/download/tramp/,
+@uref{http://savannah.nongnu.org/download/tramp/,
download}, or you may see @ref{Obtaining @tramp{}} for more details,
including the CVS server details.
-@tramp{} also has a @uref{https://savannah.gnu.org/projects/tramp/,
+@tramp{} also has a @uref{http://savannah.nongnu.org/projects/tramp/,
Savannah Project Page}.
@end ifhtml
There is a mailing list for @tramp{}, available at
@email{tramp-devel@@mail.freesoftware.fsf.org}, and archived at
-@uref{http://www.mail-archive.com/emacs-rcp@@ls6.cs.uni-dortmund.de/} as
-well as the usual Savannah archives.
+@uref{http://savannah.nongnu.org/mail/?group=tramp, Savannah Mail
+Archive}.
+@ifhtml
+Older archives are located at
+@uref{http://sourceforge.net/mailarchive/forum.php?forum=tramp-devel,
+SourceForge Mail Archive} and
+@uref{http://www.mail-archive.com/emacs-rcp@@ls6.cs.uni-dortmund.de/,
+The Mail Archive}.
+@c in HTML output, there's no new paragraph.
+@*@*
+@end ifhtml
@insertcopying
@@ -137,7 +148,7 @@ For the end user:
* Usage:: An overview of the operation of @tramp{}.
* Bug Reports:: Reporting Bugs and Problems.
* Frequently Asked Questions:: Questions and answers from the mailing list.
-* Concept Index:: An item for each concept
+* Concept Index:: An item for each concept.
For the developer:
@@ -153,6 +164,7 @@ Installing @tramp{} with your @value{emacs-name}
* Installation parameters:: Parameters in order to control installation.
* Load paths:: How to plug-in @tramp{} into your environment.
+* Japanese manual:: Japanese manual.
@end ifset
@@ -165,12 +177,13 @@ Configuring @tramp{} for use
* Default Method:: Selecting a default method.
* Customizing Methods:: Using Non-Standard Methods.
* Customizing Completion:: Selecting config files for user/host name completion.
+* Password caching:: Reusing passwords for several connections.
* Remote Programs:: How @tramp{} finds and uses programs on the remote machine.
* Remote shell setup:: Remote shell setup hints.
* Windows setup hints:: Issues with Cygwin ssh.
* Auto-save and Backup:: Auto-save and Backup.
-Using @tramp
+Using @tramp{}
* Filename Syntax:: @tramp{} filename conventions.
* Multi-hop filename syntax:: Multi-hop filename conventions.
@@ -198,7 +211,7 @@ How file names, directories and localnames are mangled and managed
@end menu
@node Overview
-@chapter An overview of @tramp
+@chapter An overview of @tramp{}
@cindex overview
After the installation of @tramp{} into your @value{emacs-name}, you
@@ -208,8 +221,8 @@ control, and @command{dired} are transparently enabled.
Your access to the remote machine can be with the @command{rsh},
@command{rlogin}, @command{telnet} programs or with any similar
-connection method. This connection must pass ASCII successfully to be
-usable but need not be 8-bit clean.
+connection method. This connection must pass @acronym{ASCII}
+successfully to be usable but need not be 8-bit clean.
The package provides support for @command{ssh} connections out of the
box, one of the more common uses of the package. This allows
@@ -359,7 +372,7 @@ behind the scenes when you open a file with @tramp{}.
@c For the end user
@node Obtaining @tramp{}
@chapter Obtaining @tramp{}.
-@cindex obtaining Tramp
+@cindex obtaining @tramp{}
@tramp{} is freely available on the Internet and the latest release
may be downloaded from
@@ -380,20 +393,15 @@ following URL and then clicking on the CVS link in the navigation bar
at the top.
@noindent
-@uref{http://savannah.gnu.org/projects/tramp/}
+@uref{http://savannah.nongnu.org/projects/tramp/}
@noindent
Or follow the example session below:
@example
] @strong{cd ~/@value{emacs-dir}}
-] @strong{cvs -d:pserver:anoncvs@@subversions.gnu.org:/cvsroot/tramp login}
-
-(Logging in to anoncvs@@subversions.gnu.org)
-CVS password: @strong{(just hit RET here)}
-@dots{}
-
-] @strong{cvs -z3 -d:pserver:anoncvs@@subversions.gnu.org:/cvsroot/tramp co tramp}
+] @strong{export CVS_RSH="ssh"}
+] @strong{cvs -z3 -d:ext:anoncvs@@savannah.nongnu.org:/cvsroot/tramp co tramp}
@end example
@noindent
@@ -403,6 +411,7 @@ updates from the repository by issuing the command:
@example
] @strong{cd ~/@value{emacs-dir}/tramp}
+] @strong{export CVS_RSH="ssh"}
] @strong{cvs update -d}
@end example
@@ -445,11 +454,12 @@ filenames in July 2002.
@cindex configuration
@cindex default configuration
-@tramp{} is (normally) fully functional when it is initially
-installed. It is initially configured to use the @command{ssh} program
-to connect to the remote host and to use base-64 encoding (on the
-remote host, via @command{mimencode}, and on the local host via the
-built-in support for base-64 encoding in Emacs).
+@tramp{} is (normally) fully functional when it is initially installed.
+It is initially configured to use the @command{ssh} program to connect
+to the remote host and to use base64 or uu encoding to transfer the
+files through that shell connection. So in the easiest case, you just
+type @kbd{C-x C-f} and then enter the filename
+@file{@value{tramp-prefix}@var{user}@@@var{machine}@value{tramp-postfix}@var{/path/to.file}}.
On some hosts, there are problems with opening a connection. These are
related to the behavior of the remote shell. See @xref{Remote shell
@@ -457,10 +467,13 @@ setup}, for details on this.
If you do not wish to use these commands to connect to the remote
host, you should change the default connection and transfer method
-that @tramp uses. There are several different methods that @tramp{}
+that @tramp{} uses. There are several different methods that @tramp{}
can use to connect to remote machines and transfer files
(@pxref{Connection types}).
+If you don't know which method is right for you, see @xref{Default
+Method}.
+
@menu
* Connection types:: Types of connections made to remote machines.
@@ -468,8 +481,12 @@ can use to connect to remote machines and transfer files
* External transfer methods:: External transfer methods.
* Multi-hop Methods:: Connecting to a remote host using multiple hops.
* Default Method:: Selecting a default method.
+ Here we also try to help those who
+ don't have the foggiest which method
+ is right for them.
* Customizing Methods:: Using Non-Standard Methods.
* Customizing Completion:: Selecting config files for user/host name completion.
+* Password caching:: Reusing passwords for several connections.
* Remote Programs:: How @tramp{} finds and uses programs on the remote machine.
* Remote shell setup:: Remote shell setup hints.
* Windows setup hints:: Issues with Cygwin ssh.
@@ -486,7 +503,7 @@ advantages and limitations. Both types of connection make use of a
remote shell access program such as @command{rsh}, @command{ssh} or
@command{telnet} to connect to the remote machine.
-This connection is used to perform many of the operations that @tramp
+This connection is used to perform many of the operations that @tramp{}
requires to make the remote file system transparently accessible from
the local machine. It is only when visiting files that the methods
differ.
@@ -544,9 +561,9 @@ allow you to transfer files between @emph{user identities} rather than
hosts, see below.)
These methods depend on the existence of a suitable encoding and
-decoding command on remote machine. Locally, @tramp{} may be able to use
-features of Emacs to decode and encode the files or it may require
-access to external commands to perform that task.
+decoding command on remote machine. Locally, @tramp{} may be able to
+use features of @value{emacs-name} to decode and encode the files or
+it may require access to external commands to perform that task.
@cindex uuencode
@cindex mimencode
@@ -635,7 +652,7 @@ easy to implement, so I haven't got around to it, yet.
@cindex sshx method
@cindex Cygwin (with sshx method)
-As you expect, this is similar to @option{ssh}, only a little
+As you would expect, this is similar to @option{ssh}, only a little
different. Whereas @option{ssh} opens a normal interactive shell on
the remote host, this option uses @samp{ssh -t -t @var{host} -l
@var{user} /bin/sh} to open a connection. This is useful for users
@@ -652,11 +669,11 @@ question (yet), therefore you will need to make sure that you can log
in without such questions.
This is also useful for Windows users where @command{ssh}, when
-invoked from an Emacs buffer, tells them that it is not allocating a
-pseudo tty. When this happens, the login shell is wont to not print
-any shell prompt, which confuses @tramp{} mightily. For reasons
-unknown, some Windows ports for @command{ssh} (maybe the Cygwin one)
-require the doubled @samp{-t} option.
+invoked from an @value{emacs-name} buffer, tells them that it is not
+allocating a pseudo tty. When this happens, the login shell is wont
+to not print any shell prompt, which confuses @tramp{} mightily. For
+reasons unknown, some Windows ports for @command{ssh} (maybe the
+Cygwin one) require the doubled @samp{-t} option.
This supports the @samp{-p} kludge.
@@ -760,7 +777,7 @@ call @samp{ssh -1} and @samp{ssh -2}, respectively. This way, you can
explicitly select whether you want to use the SSH protocol version 1
or 2 to connect to the remote host. (You can also specify in
@file{~/.ssh/config}, the SSH configuration file, which protocol
-should be used, and use the regular @option{ssh} method.)
+should be used, and use the regular @option{scp} method.)
Two other variants, @option{scp1_old} and @option{scp2_old}, use the
@command{ssh1} and @command{ssh2} commands explicitly. If you don't
@@ -800,7 +817,7 @@ This method supports the @samp{-p} hack.
@cindex ssh (with scpx method)
@cindex Cygwin (with scpx method)
-As you expect, this is similar to @option{scp}, only a little
+As you would expect, this is similar to @option{scp}, only a little
different. Whereas @option{scp} opens a normal interactive shell on
the remote host, this option uses @samp{ssh -t -t @var{host} -l
@var{user} /bin/sh} to open a connection. This is useful for users
@@ -810,10 +827,10 @@ just gives @tramp{} a more-or-less `standard' login shell to work
with.
This is also useful for Windows users where @command{ssh}, when
-invoked from an Emacs buffer, tells them that it is not allocating a
-pseudo tty. When this happens, the login shell is wont to not print
-any shell prompt, which confuses @tramp{} mightily. Maybe this
-applies to the Cygwin port of SSH.
+invoked from an @value{emacs-name} buffer, tells them that it is not
+allocating a pseudo tty. When this happens, the login shell is wont
+to not print any shell prompt, which confuses @tramp{} mightily.
+Maybe this applies to the Cygwin port of SSH.
This method supports the @samp{-p} hack.
@@ -854,19 +871,21 @@ This method uses the command @samp{fsh @var{host} -l @var{user}
@cindex method fsh
@cindex fsh method
+
There is no inline method using @command{fsh} as the multiplexing
provided by the program is not very useful in our context. @tramp{}
opens just one connection to the remote host and then keeps it open,
anyway.
-@ifset emacs
@item @option{ftp}
@cindex method ftp
@cindex ftp method
This is not a native @tramp{} method. Instead of, it forwards all
requests to @value{ftp-package-name}.
+@ifset xemacs
+This works only for unified filenames, see @ref{Issues}.
@end ifset
@@ -889,7 +908,7 @@ directory @code{/}), all available shares are listed.
Since authorization is done on share level, you will be prompted
always for a password if you access another share on the same host.
-Due to security reasons, the password is not cached.
+This can be suppressed by @ref{Password caching}.
MS Windows uses for authorization both a user name and a domain name.
Because of this, the @tramp{} syntax has been extended: you can
@@ -907,10 +926,11 @@ methods, where in such a case the local user name is taken.
The @option{smb} method supports the @samp{-p} hack.
-@strong{Please note:} If Emacs runs locally under MS Windows, this
-method isn't available. Instead of, you can use UNC file names like
-@file{//melancholia/daniel$$/.emacs}. The only disadvantage is that
-there's no possibility to specify another user name.
+@strong{Please note:} If @value{emacs-name} runs locally under MS
+Windows, this method isn't available. Instead of, you can use UNC
+file names like @file{//melancholia/daniel$$/.emacs}. The only
+disadvantage is that there's no possibility to specify another user
+name.
@end table
@@ -1013,7 +1033,7 @@ the standard port.
@vindex tramp-default-method
When you select an appropriate transfer method for your typical usage
-you should set the variable @var{tramp-default-method} to reflect that
+you should set the variable @code{tramp-default-method} to reflect that
choice. This variable controls which method will be used when a method
is not specified in the @tramp{} file name. For example:
@@ -1023,7 +1043,7 @@ is not specified in the @tramp{} file name. For example:
@vindex tramp-default-method-alist
You can also specify different methods for certain user/host
-combinations, via the variable @var{tramp-default-method-alist}. For
+combinations, via the variable @code{tramp-default-method-alist}. For
example, the following two lines specify to use the @option{ssh}
method for all user names matching @samp{john} and the @option{rsync}
method for all host names matching @samp{lily}. The third line
@@ -1039,7 +1059,7 @@ the machine @samp{localhost}.
@noindent
See the documentation for the variable
-@var{tramp-default-method-alist} for more details.
+@code{tramp-default-method-alist} for more details.
External transfer methods are normally preferable to inline transfer
methods, giving better performance. They may not be useful if you use
@@ -1064,6 +1084,48 @@ methods to connect. These provide a much higher level of security,
making it a non-trivial exercise for someone to obtain your password or
read the content of the files you are editing.
+
+@subsection Which method is the right one for me?
+@cindex choosing the right method
+
+Given all of the above, you are probably thinking that this is all fine
+and good, but it's not helping you to choose a method! Right you are.
+As a developer, we don't want to boss our users around but give them
+maximum freedom instead. However, the reality is that some users would
+like to have some guidance, so here I'll try to give you this guidance
+without bossing you around. You tell me whether it works @dots{}
+
+My suggestion is to use an inline method. For large files, out-of-band
+methods might be more efficient, but I guess that most people will want
+to edit mostly small files.
+
+I guess that these days, most people can access a remote machine by
+using @code{ssh}. So I suggest that you use the @code{ssh} method.
+So, type @kbd{C-x C-f /ssh:root@@otherhost:/etc/motd @key{RET}} to
+edit the @file{/etc/motd} file on the other host.
+
+If you can't use @code{ssh} to log in to the remote host, then select a
+method that uses a program that works. For instance, Windows users
+might like the @code{plink} method which uses the PuTTY implementation
+of @code{ssh}. Or you use Kerberos and thus like @code{krlogin}.
+
+For the special case of editing files on the local host as another
+user, see the @code{su} or @code{sudo} method.
+
+People who edit large files may want to consider @code{scp} instead of
+@code{ssh}, or @code{pscp} instead of @code{plink}. These out-of-band
+methods are faster than inline methods for large files. Note, however,
+that out-of-band methods suffer from some limitations. Please try
+first whether you really get a noticeable speed advantage from using an
+out-of-band method! Maybe even for large files, inline methods are
+fast enough.
+
+The reason why I'm suggesting to use inline methods is that they work
+even if the remote end is asking you for a password. Out-of-band
+methods don't work in this situation. Also, multi-hop methods are
+inherently inline.
+
+
@node Customizing Methods
@section Using Non-Standard Methods
@cindex customizing methods
@@ -1109,7 +1171,7 @@ Example:
@defun tramp-set-completion-function method function-list
This function sets @var{function-list} as list of completion functions
-for @var{method}.
+for @var{method}.
Example:
@example
@@ -1145,6 +1207,21 @@ in such files, it can return host names only.
This function returns the host nicknames defined by @code{Host} entries
in @file{~/.ssh/config} style files.
+@item @code{tramp-parse-shostkeys}
+@findex tramp-parse-shostkeys
+
+SSH2 parsing of directories @file{/etc/ssh2/hostkeys/*} and
+@file{~/ssh2/hostkeys/*}. Hosts are coded in file names
+@file{hostkey_PORTNUMBER_HOST-NAME.pub}. User names are always nil.
+
+@item @code{tramp-parse-sknownhosts}
+@findex tramp-parse-shostkeys
+
+Another SSH2 style parsing of directories like
+@file{/etc/ssh2/knownhosts/*} and @file{~/ssh2/knownhosts/*}. This
+case, hosts names are coded in file names
+@file{HOST-NAME.ALGORITHM.pub}. User names are always nil.
+
@item @code{tramp-parse-hosts}
@findex tramp-parse-hosts
@@ -1181,6 +1258,49 @@ Example:
@end defun
+@node Password caching
+@section Reusing passwords for several connections.
+@cindex passwords
+
+Sometimes it is necessary to connect to the same remote host several
+times. Reentering passwords again and again would be annoying, when
+the choosen method does not support access without password prompt
+throught own configuration.
+
+By default, @tramp{} caches the passwords entered by you. They will
+be reused next time if a connection needs them for the same user name
+and host name, independant of the connection method.
+
+@vindex password-cache-expiry
+Passwords are not saved permanently, that means the password caching
+is limited to the lifetime of your @value{emacs-name} session. You
+can influence the lifetime of password caching by customizing the
+variable @code{password-cache-expiry}. The value is the number of
+seconds how long passwords are cached. Setting it to @code{nil}
+disables the expiration.
+
+@findex tramp-clear-passwd
+A password is removed from the cache if a connection isn't established
+successfully. You can remove a password from the cache also by
+executing @kbd{M-x tramp-clear-passwd} in a buffer containing a
+related remote file or directory.
+
+@vindex password-cache
+If you don't like this feature for security reasons, password caching
+can be disabled totally by customizing the variable
+@code{password-cache} (setting it to @code{nil}).
+
+Implementation Note: password caching is based on the package
+password.el in No Gnus. For the time being, it is activated only when
+this package is seen in the @code{load-path} while loading @tramp{}.
+@ifset tramp-inst
+If you don't use No Gnus, you can take password.el from the @tramp{}
+@file{contrib} directory, see @ref{Installation parameters}.
+@end ifset
+It will be activated mandatory once No Gnus has found its way into
+@value{emacs-name}.
+
+
@node Remote Programs
@section How @tramp{} finds and uses programs on the remote machine.
@@ -1241,7 +1361,7 @@ There are different possible strategies for pursuing this problem. One
strategy is to enable @tramp{} to deal with all possible situations.
This is a losing battle, since it is not possible to deal with
@emph{all} situations. The other strategy is to require you to set up
-the remote host such that it behaves like @tramp{} expect. This might
+the remote host such that it behaves like @tramp{} expects. This might
be inconvenient because you have to invest a lot of effort into shell
setup before you can begin to use @tramp{}.
@@ -1310,6 +1430,16 @@ The other approach is to teach @tramp{} about these questions. See
the variables @code{tramp-actions-before-shell} and
@code{tramp-multi-actions} (for multi-hop connections).
+
+@item Environment variables named like users in @file{.profile}
+
+If you have a user named frumple and set the variable @code{FRUMPLE} in
+your shell environment, then this might cause trouble. Maybe rename
+the variable to @code{FRUMPLE_DIR} or the like.
+
+This weird effect was actually reported by a @tramp{} user!
+
+
@item Non-Bourne commands in @file{.profile}
After logging in to the remote host, @tramp{} issues the command
@@ -1364,22 +1494,21 @@ find out if the shell is Bourne-ish?
@cindex backup
@vindex backup-directory-alist
-Explaining auto-save is still to do.
-
-Normally, Emacs writes backup files to the same directory as the
-original files, but this behavior can be changed via the variable
-@code{backup-directory-alist}. In connection with @tramp{}, this can
-have unexpected side effects. Suppose that you specify that all backups
-should go to the directory @file{~/.emacs.d/backups/}, and then you edit
-the file @file{/su:root@@localhost:/etc/secretfile}. The effect is that
-the backup file will be owned by you and not by root, thus possibly
-enabling others to see it even if they were not intended to see it.
+Normally, @value{emacs-name} writes backup files to the same directory
+as the original files, but this behavior can be changed via the
+variable @code{backup-directory-alist}. In connection with @tramp{},
+this can have unexpected side effects. Suppose that you specify that
+all backups should go to the directory @file{~/.emacs.d/backups/}, and
+then you edit the file @file{/su:root@@localhost:/etc/secretfile}.
+The effect is that the backup file will be owned by you and not by
+root, thus possibly enabling others to see it even if they were not
+intended to see it.
When @code{backup-directory-alist} is nil (the default), such problems
do not occur.
If you wish to customize the variable, the workaround is to include
-special settings for Tramp files. For example, the following statement
+special settings for @tramp{} files. For example, the following statement
effectively `turns off' the effect of @code{backup-directory-alist} for
@tramp{} files:
@@ -1389,6 +1518,29 @@ effectively `turns off' the effect of @code{backup-directory-alist} for
(cons tramp-file-name-regexp nil))
@end lisp
+The same problem can happen with auto-saving files.
+@ifset emacs
+Since @value{emacs-name} 21, the variable
+@code{auto-save-file-name-transforms} keeps information, on which
+directory an auto-saved file should go. By default, it is initialized
+for @tramp{} files to the local temporary directory.
+
+On some versions of @value{emacs-name}, namely the version built for
+Debian Linux, the variable @code{auto-save-file-name-transforms}
+contains the directory where @value{emacs-name} was built. A
+workaround is to manually set the variable to a sane value.
+
+If auto-saved files should go into the same directory as the original
+files, @code{auto-save-file-name-transforms} should be set to nil.
+
+Another possibility is to set the variable
+@code{tramp-auto-save-directory} to a proper value.
+@end ifset
+@ifset xemacs
+For this purpose you can set the variable
+@code{tramp-auto-save-directory} to a proper value.
+@end ifset
+
@node Windows setup hints
@section Issues with Cygwin ssh
@@ -1406,29 +1558,30 @@ setting up Cygwin in their FAQ at @uref{http://cygwin.com/faq/}.
@cindex method scpx with Cygwin
@cindex scpx method with Cygwin
If you wish to use the @code{scpx} connection method, then you might
-have the problem that Emacs calls @code{scp} with a Windows filename
-such as @code{c:/foo}. The Cygwin version of @code{scp} does not know
-about Windows filenames and interprets this as a remote filename on the
-host @code{c}.
+have the problem that @value{emacs-name} calls @code{scp} with a
+Windows filename such as @code{c:/foo}. The Cygwin version of
+@code{scp} does not know about Windows filenames and interprets this
+as a remote filename on the host @code{c}.
One possible workaround is to write a wrapper script for @code{scp}
which converts the Windows filename to a Cygwinized filename.
-I guess that another workaround is to run Emacs under Cygwin, or to run
-a Cygwinized Emacs.
+I guess that another workaround is to run @value{emacs-name} under
+Cygwin, or to run a Cygwinized @value{emacs-name}.
@cindex Cygwin and ssh-agent
-@cindex SSH_AUTH_SOCK and Emacs on Windows
+@cindex SSH_AUTH_SOCK and @value{emacs-name} on Windows
If you want to use either @code{ssh} based method on Windows, then you
might encounter problems with @code{ssh-agent}. Using this program,
you can avoid typing the pass-phrase every time you log in (and the
@code{scpx} method more or less requires you to use @code{ssh-agent}
because it does not allow you to type a password or pass-phrase).
-However, if you start Emacs from a desktop shortcut, then the
-environment variable @code{SSH_AUTH_SOCK} is not set and so Emacs and
-thus @tramp{} and thus @code{ssh} and @code{scp} started from @tramp{}
-cannot communicate with @code{ssh-agent}. It works better to start
-Emacs from the shell.
+However, if you start @value{emacs-name} from a desktop shortcut, then
+the environment variable @code{SSH_AUTH_SOCK} is not set and so
+@value{emacs-name} and thus @tramp{} and thus @code{ssh} and
+@code{scp} started from @tramp{} cannot communicate with
+@code{ssh-agent}. It works better to start @value{emacs-name} from
+the shell.
If anyone knows how to start @code{ssh-agent} under Windows in such a
way that desktop shortcuts can profit, please holler. I don't really
@@ -1436,8 +1589,8 @@ know anything at all about Windows@dots{}
@node Usage
-@chapter Using @tramp
-@cindex using @tramp
+@chapter Using @tramp{}
+@cindex using @tramp{}
Once you have installed @tramp{} it will operate fairly transparently. You
will be able to access files on any remote machine that you can log in
@@ -1448,15 +1601,15 @@ details of the system to connect to. This is similar to the syntax used
by the @value{ftp-package-name} package.
@cindex type-ahead
-Something that might happen which surprises you is that Emacs
-remembers all your keystrokes, so if you see a password prompt from
-Emacs, say, and hit @kbd{@key{RET}} twice instead of once, then the
-second keystroke will be processed by Emacs after @tramp{} has done
-its thing. Why, this type-ahead is normal behavior, you say. Right
-you are, but be aware that opening a remote file might take quite a
-while, maybe half a minute when a connection needs to be opened.
-Maybe after half a minute you have already forgotten that you hit that
-key!
+Something that might happen which surprises you is that
+@value{emacs-name} remembers all your keystrokes, so if you see a
+password prompt from @value{emacs-name}, say, and hit @kbd{@key{RET}}
+twice instead of once, then the second keystroke will be processed by
+@value{emacs-name} after @tramp{} has done its thing. Why, this
+type-ahead is normal behavior, you say. Right you are, but be aware
+that opening a remote file might take quite a while, maybe half a
+minute when a connection needs to be opened. Maybe after half a
+minute you have already forgotten that you hit that key!
@menu
* Filename Syntax:: @tramp{} filename conventions.
@@ -1532,9 +1685,9 @@ This is done by replacing the initial
The user, machine and file specification remain the same.
So, to connect to the machine @code{melancholia} as @code{daniel},
-using the @option{su} method to transfer files, and edit @file{.emacs}
+using the @option{ssh} method to transfer files, and edit @file{.emacs}
in my home directory I would specify the filename
-@file{@value{tramp-prefix}su@value{tramp-postfix-single-hop}daniel@@melancholia@value{tramp-postfix}.emacs}.
+@file{@value{tramp-prefix}ssh@value{tramp-postfix-single-hop}daniel@@melancholia@value{tramp-postfix}.emacs}.
@node Multi-hop filename syntax
@@ -1544,7 +1697,7 @@ in my home directory I would specify the filename
The syntax of multi-hop file names is necessarily slightly different
than the syntax of other @tramp{} file names. Here's an example
-multi-hop file name, first in Emacs syntax and then in XEmacs syntax:
+multi-hop file name:
@example
@value{tramp-prefix}multi@value{tramp-postfix-single-hop}rsh@value{tramp-postfix-multi-hop}out@@gate@value{tramp-postfix-single-hop}telnet@value{tramp-postfix-multi-hop}kai@@real.host@value{tramp-postfix}/path/to.file
@@ -1618,7 +1771,7 @@ is a possible completion for the respective method,
machine,
@end ifset
and @samp{@value{tramp-prefix-single-hop}toto@value{tramp-postfix}}
-might be a host @tramp has detected in your @file{~/.ssh/known_hosts}
+might be a host @tramp{} has detected in your @file{~/.ssh/known_hosts}
file (given you're using default method @option{ssh}).
If you go on to type @kbd{e @key{TAB}}, the minibuffer is completed to
@@ -1707,7 +1860,7 @@ Where can I get the latest @tramp{}?
There is also a Savannah project page.
@noindent
-@uref{https://savannah.gnu.org/projects/tramp/}
+@uref{http://savannah.nongnu.org/projects/tramp/}
@item
Which systems does it work on?
@@ -1717,8 +1870,9 @@ as XEmacs 21. XEmacs 20 is more problematic, see the notes in
@file{tramp.el}. I don't think anybody has really tried it on Emacs 19.
The package was intended to work on Unix, and it really expects a
-Unix-like system on the remote end, but some people seemed to have some
-success getting it to work on NT Emacs.
+Unix-like system on the remote end (except the @option{smb} method),
+but some people seemed to have some success getting it to work on NT
+Emacs.
There is some informations on @tramp{} on NT at the following URL;
many thanks to Joe Stoy for providing the information:
@@ -1744,7 +1898,7 @@ packages which make @value{ftp-package-name} file name handlers active.
You can see it applying @kbd{C-h v file-name-handler-alist}:
@example
-file-name-handler-alist's value is
+file-name-handler-alist's value is
(("^/[^/:]*\\'" . ange-ftp-completion-hook-function)
("^/[^/:]*[^/:.]:" . ange-ftp-hook-function)
("^/[^/]*$" . tramp-completion-file-name-handler)
@@ -1826,8 +1980,9 @@ work on NT with some tweaking.
@item
How can I get notified when @tramp{} file transfers are complete?
-The following snippet can be put in your @file{~/.emacs} file. It makes
-Emacs beep after reading from or writing to the remote host.
+The following snippet can be put in your @file{~/.emacs} file. It
+makes @value{emacs-name} beep after reading from or writing to the
+remote host.
@lisp
(defadvice tramp-handle-write-region
@@ -1931,7 +2086,7 @@ operations on files accessed via @tramp{}.
In the case of a remote file, the @code{shell-command} interface is
used, with some wrapper code, to provide the same functionality on the
-remote machine as would be seen on the local machine.
+remote machine as would be seen on the local machine.
@node Changed workfiles
@@ -1974,10 +2129,11 @@ Minor implementation details, &c.
@node Remote File Ownership
@subsection How VC determines who owns a workfile
-Emacs provides the @code{user-full-name} function to return the login name
-of the current user as well as mapping from arbitrary user id values
-back to login names. The VC code uses this functionality to map from the
-uid of the owner of a workfile to the login name in some circumstances.
+@value{emacs-name} provides the @code{user-full-name} function to
+return the login name of the current user as well as mapping from
+arbitrary user id values back to login names. The VC code uses this
+functionality to map from the uid of the owner of a workfile to the
+login name in some circumstances.
This will not, for obvious reasons, work if the remote system has a
different set of logins. As such, it is necessary to delegate to the
@@ -2095,6 +2251,29 @@ uses EFS for downloading new packages. So, obviously, EFS has to be
installed from the start. If the filenames were unified, @tramp{}
would have to be installed from the start, too.
+@ifset xemacs
+@strong{Note:} If you'ld like to use a similar syntax like
+@value{ftp-package-name}, you need the following settings in your init
+file:
+
+@lisp
+(setq tramp-unified-filenames t)
+(require 'tramp)
+@end lisp
+
+The autoload of the @value{emacs-name} @tramp{} package must be
+disabled. This can be achieved by setting file permissions @code{000}
+to the files @file{.../xemacs-packages/lisp/tramp/auto-autoloads.el*}.
+
+In case of unified filenames, all @value{emacs-name} download sites
+are added to @code{tramp-default-method-alist} with default method
+@code{ftp} @xref{Default Method}. These settings shouldn't be touched
+for proper working of the @value{emacs-name} package system.
+
+The syntax for unified filenames is described in the @tramp{} manual
+for @value{emacs-other-name}.
+@end ifset
+
@end itemize
@node Concept Index
@@ -2119,3 +2298,7 @@ would have to be installed from the start, too.
@c ** Use `filename' resp. `file name' consistently.
@c ** Use `host' resp. `machine' consistently.
@c ** Consistent small or capitalized words especially in menues.
+
+@ignore
+ arch-tag: f96dd66e-6dd3-4c92-8d77-9c56205ba808
+@end ignore
diff --git a/man/trampver.texi b/man/trampver.texi
index f728531b9e9..38862115ce9 100644
--- a/man/trampver.texi
+++ b/man/trampver.texi
@@ -5,7 +5,7 @@
@c configure.ac, so you should edit that file and run
@c "autoconf && ./configure" to change the version number.
@macro trampver{}
-2.0.36
+2.0.39
@end macro
@c Other flags from configuration
@@ -32,6 +32,7 @@
@set tramp-postfix :
@set tramp-postfix-single-hop :
@set tramp-postfix-multi-hop :
+@set japanese-manual tramp_ja-emacs.html
@end ifset
@c XEmacs counterparts.
@@ -44,6 +45,7 @@
@set tramp-postfix ]
@set tramp-postfix-single-hop /
@set tramp-postfix-multi-hop :
+@set japanese-manual tramp_ja-xemacs.html
@end ifset
@c Empty macro definitions in order to satisfy texi2dvi
@@ -55,6 +57,8 @@
@c The installation chapter is needed only in case Tramp is installed
@c standalone. That's why it is included from `trampinst.texi'.
-@c Otherwise, '/dev/null/' is tken, which leaves this part empty.
-
+@c Otherwise, '/dev/null/' is taken, which leaves this part empty.
+@ignore
+ arch-tag: e0fe322c-e06b-46eb-bb5b-d091b521f41c
+@end ignore
diff --git a/man/trouble.texi b/man/trouble.texi
index 737fcf12fb0..e7f6ae7608b 100644
--- a/man/trouble.texi
+++ b/man/trouble.texi
@@ -124,8 +124,8 @@ about the undo facility.
normally, and how to recognize them and correct them. For a list of
additional problems you might encounter, see @ref{Bugs and problems, ,
Bugs and problems, efaq, GNU Emacs FAQ}, and the file @file{etc/PROBLEMS}
-in the Emacs distribution. Type @kbd{C-h F} to read the FAQ; type
-@kbd{C-h P} to read the @file{PROBLEMS} file.
+in the Emacs distribution. Type @kbd{C-h C-f} to read the FAQ; type
+@kbd{C-h C-e} to read the @file{PROBLEMS} file.
@menu
* DEL Does Not Delete:: What to do if @key{DEL} doesn't delete.
@@ -426,7 +426,7 @@ to do so effectively, you must know when and how to do it.
Before reporting a bug, it is a good idea to see if it is already
known. You can find the list of known problems in the file
-@file{etc/PROBLEMS} in the Emacs distribution; type @kbd{C-h P} to read
+@file{etc/PROBLEMS} in the Emacs distribution; type @kbd{C-h C-e} to read
it. Some additional user-level problems can be found in @ref{Bugs and
problems, , Bugs and problems, efaq, GNU Emacs FAQ}. Looking up your
problem in these two documents might provide you with a solution or a
@@ -683,7 +683,7 @@ terminal-dependent bug without access to a terminal of the type that
stimulates the bug.@refill
@item
-If non-ASCII text or internationalization is relevant, the locale that
+If non-@acronym{ASCII} text or internationalization is relevant, the locale that
was current when you started Emacs. On GNU/Linux and Unix systems, or
if you use a Posix-style shell such as Bash, you can use this shell
command to view the relevant values:
@@ -1062,3 +1062,7 @@ Look in the service directory for someone who might help you for a fee.
The service directory is found in the file named @file{etc/SERVICE} in the
Emacs distribution.
@end itemize
+
+@ignore
+ arch-tag: c9cba76d-b2cb-4e0c-ae3f-19d5ef35817c
+@end ignore
diff --git a/man/vip.texi b/man/vip.texi
index fc34eacc865..cba1998f011 100644
--- a/man/vip.texi
+++ b/man/vip.texi
@@ -121,7 +121,7 @@ explained in more detail in the GNU Emacs Manual.
@cindex end (of buffer)
@cindex region
-Conceptually, a @dfn{buffer} is just a string of ASCII characters and two
+Conceptually, a @dfn{buffer} is just a string of @acronym{ASCII} characters and two
special characters @key{PNT} (@dfn{point}) and @key{MRK} (@dfn{mark}) such
that the character @key{PNT} occurs exactly once and @key{MRK} occurs at
most once. The @dfn{text} of a buffer is obtained by deleting the
@@ -1003,7 +1003,7 @@ The following commands are used to mark positions in the buffer.
@item m @var{ch}
@kindex 155 @kbd{m} (@code{vip-mark-point})
Store current point in the register @var{ch}. @var{ch} must be a
-lower-case ASCII letter.
+lower-case @acronym{ASCII} letter.
@item m <
Set mark at the beginning of current buffer.
@item m >
@@ -1944,3 +1944,7 @@ file.
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: 7c5d17b9-1d21-4261-a88a-b9fdbbf1020b
+@end ignore
diff --git a/man/viper.texi b/man/viper.texi
index c0059da3a97..a31ce9a003d 100644
--- a/man/viper.texi
+++ b/man/viper.texi
@@ -2779,7 +2779,7 @@ As if all that is not enough, Viper (through its interface to Emacs
macros) lets the user define keyboard macros that ask for confirmation or
even prompt the user for input and then continue. To do this, one should
type @kbd{C-x q} (for confirmation) or @kbd{C-u C-x q} (for prompt).
-For details, @pxref{Kbd Macro Query,,Customization,emacs,The GNU Emacs
+For details, @pxref{Keyboard Macro Query,,Customization,emacs,The GNU Emacs
Manual} @refill
When the user finishes defining a macro (which is done by typing @kbd{C-x)} ---
@@ -3140,7 +3140,7 @@ Return, Enter
We also use @samp{word} for alphanumeric/non-alphanumeric words, and
@samp{WORD} for whitespace delimited words. @samp{char} refers to any
-ASCII character, @samp{CHAR} to non-whitespace character.
+@acronym{ASCII} character, @samp{CHAR} to non-whitespace character.
Brackets @samp{[]} indicate optional parameters; @samp{<count>} also
optional, usually defaulting to 1. Brackets are elided for
@samp{<count>} to eschew obfuscation.
@@ -4542,3 +4542,7 @@ zapman@@cc.gatech.edu (Jason Zapman II),
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: f53e866a-15cf-4b1e-aead-77da9da1e864
+@end ignore
diff --git a/man/widget.texi b/man/widget.texi
index d1d7bae0315..290c56c6812 100644
--- a/man/widget.texi
+++ b/man/widget.texi
@@ -10,7 +10,7 @@
@c %**end of header
@copying
-Copyright @copyright{} 2000, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 2000, 2002, 2003 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -112,7 +112,7 @@ supposed to fill out a number of fields, each of which has a specific
meaning. The user is not supposed to change or delete any of the text
between the fields. Examples of forms in Emacs are the @file{forms}
package (of course), the customize buffers, the mail and news compose
-modes, and the @sc{html} form support in the @file{w3} browser.
+modes, and the @acronym{HTML} form support in the @file{w3} browser.
@cindex widget library, why use it
The advantages for a programmer of using the @code{widget} package to
@@ -211,7 +211,16 @@ change you make must be contained within a single editable text field.
For example, capitalizing all text from the middle of one field to the
middle of another field is prohibited.
-Editing text fields are created by the @code{editable-field} widget.
+Editable text fields are created by the @code{editable-field} widget.
+
+An editable field must be surrounded by static text on both sides, that
+is, text that does not change in the lifetime of the widget. If the
+field extends to the end of the line, the terminating line-feed character
+will count as the necessary static text on that end, but you will have
+to provide the static text before the field yourself. The
+@code{:format} keyword is useful for generating the static text; for
+instance, if you give it a value of @code{"Name: %v"}, the "Name: " part
+will count as the static text.
The editing text fields are highlighted with the
@code{widget-field-face} face, making them easy to find.
@@ -573,8 +582,9 @@ Emacsen that supports it.
Specifies how to display a message whenever you move to the widget with
either @code{widget-forward} or @code{widget-backward} or move the mouse
over it (using the standard @code{help-echo} mechanism). The argument
-is either a string to display or a function of one argument, the widget,
-which should return a string to display.
+is either a string to display, a function of one argument, the widget,
+which should return a string to display, or a form that evaluates to
+such a string.
@vindex indent@r{ keyword}
@item :indent
@@ -729,7 +739,7 @@ TYPE ::= (url-link [KEYWORD ARGUMENT]... URL)
@end example
@findex browse-url-browser-function@r{, and @code{url-link} widget}
-When this link is invoked, the @sc{www} browser specified by
+When this link is invoked, the @acronym{WWW} browser specified by
@code{browse-url-browser-function} will be called with @var{url}.
@node info-link, push-button, url-link, Basic Types
@@ -1576,24 +1586,31 @@ in the buffer, and returns a widget object.
Function to delete a widget. The function takes one argument, a widget,
and should remove all traces of the widget from the buffer.
+The default value is:
+
+@defun widget-default-delete widget
+Remove @var{widget} from the buffer.
+Delete all @code{:children} and @code{:buttons} in @var{widget}.
+@end defun
+
+In most cases you should not change this value, but instead use
+@code{:value-delete} to make any additional cleanup.
+
@vindex value-create@r{ keyword}
@item :value-create
Function to expand the @samp{%v} escape in the format string. It will
be called with the widget as its argument and should insert a
representation of the widget's value in the buffer.
+Nested widgets should be listed in @code{:children} or @code{:buttons}
+to make sure they are automatically deleted.
+
@vindex value-delete@r{ keyword}
@item :value-delete
Should remove the representation of the widget's value from the buffer.
It will be called with the widget as its argument. It doesn't have to
remove the text, but it should release markers and delete nested widgets
-if such have been used.
-
-The following predefined function can be used here:
-
-@defun widget-children-value-delete widget
-Delete all @code{:children} and @code{:buttons} in @var{widget}.
-@end defun
+if these are not listed in @code{:children} or @code{:buttons}.
@vindex value-get@r{ keyword}
@item :value-get
@@ -1780,3 +1797,7 @@ variables, and widgets described in this manual.
@setchapternewpage odd
@contents
@bye
+
+@ignore
+ arch-tag: 2b427731-4c61-4e72-85de-5ccec9c623f0
+@end ignore
diff --git a/man/windows.texi b/man/windows.texi
index bc6347c53ed..100abaf3c93 100644
--- a/man/windows.texi
+++ b/man/windows.texi
@@ -400,3 +400,7 @@ windows together. You can also turn it on by customizing the variable
scroll-all-scroll-down-all}, @kbd{M-x scroll-all-page-down-all} and
their corresponding ``up'' equivalents. To make this mode useful,
you should bind these commands to appropriate keys.
+
+@ignore
+ arch-tag: 8bea7453-d4b1-49b1-9bf4-cfe4383e1113
+@end ignore
diff --git a/man/woman.texi b/man/woman.texi
index 590b78022f6..108225dbbf6 100644
--- a/man/woman.texi
+++ b/man/woman.texi
@@ -1,5 +1,4 @@
\input texinfo @c -*-texinfo-*-
-@c $Id: woman.texi,v 1.12 2002/10/02 23:24:31 karl Exp $
@c %**start of header
@setfilename ../info/woman
@settitle WoMan: Browse Unix Manual Pages ``W.O. (without) Man''
@@ -18,7 +17,7 @@
This file documents WoMan: A program to browse Unix manual pages `W.O.
(without) man'.
-Copyright @copyright{} 2001, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 2001, 2002, 2004 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@@ -196,7 +195,7 @@ requests.
The distinction between @code{TROFF} and @code{NROFF} is that
@code{TROFF} was designed to drive a phototypesetter whereas
-@code{NROFF} was designed to produce essentially @sc{ascii} output for a
+@code{NROFF} was designed to produce essentially @acronym{ASCII} output for a
character-based device similar to a teletypewriter (usually abbreviated
to ``teletype'' or ``tty''). Hence, @code{TROFF} supports much finer
control over output positioning than does @code{NROFF} and can be seen
@@ -298,8 +297,8 @@ WoMan is running byte code whereas most of the formatting done by
@code{man} uses machine code, and is a testimony to the quality of the
Emacs Lisp system.
-@code{NROFF} simulates non-@sc{ascii} characters by using one or more
-@sc{ascii} characters. WoMan should be able to do much better than
+@code{NROFF} simulates non-@acronym{ASCII} characters by using one or more
+@acronym{ASCII} characters. WoMan should be able to do much better than
this. I have recently begun to add support for WoMan to use more of the
characters in its default font and to use a symbol font, and it is an
aspect that I intend to develop further in the near future. It should
@@ -766,7 +765,7 @@ primarily used internally by WoMan.
Emacs provides an interface to detect automatically the format of a file
and decode it when it is visited. It is used primarily by the
facilities for editing rich (i.e.@: formatted) text, as a way to store
-formatting information transparently as @sc{ascii} markup. WoMan can in
+formatting information transparently as @acronym{ASCII} markup. WoMan can in
principle use this interface, but it must be configured explicitly.
This use of WoMan does not seem to be particularly advantageous, so it
@@ -1329,9 +1328,9 @@ The SysV standard man pages use two character suffixes, and this is
becoming more common in the GNU world. For example, the man pages in
the @code{ncurses} package include @file{toe.1m}, @file{form.3x}, etc.
-@strong{Note:} an optional compression regexp will be appended, so this
-regexp @emph{must not} end with any kind of string terminator such as
-@code{$} or @code{\\'}.
+@strong{Please note:} an optional compression regexp will be appended,
+so this regexp @emph{must not} end with any kind of string terminator
+such as @code{$} or @code{\\'}.
@item woman-file-compression-regexp
A regular match expression used to match compressed man file extensions
@@ -1388,9 +1387,9 @@ ignored. Default is @code{t}. This gives the standard @code{ROFF} behavior.
If @code{nil} then they are left in the buffer, which may aid debugging.
@item woman-preserve-ascii
-A boolean value. If non-@code{nil} then preserve @sc{ascii} characters in the
-WoMan buffer. Otherwise, non-@sc{ascii} characters (that display as
-@sc{ascii}) may remain, which is irrelevant unless the buffer is to be
+A boolean value. If non-@code{nil} then preserve @acronym{ASCII} characters in the
+WoMan buffer. Otherwise, non-@acronym{ASCII} characters (that display as
+@acronym{ASCII}) may remain, which is irrelevant unless the buffer is to be
saved to a file. Default is @code{nil}.
@item woman-emulation
@@ -1445,7 +1444,7 @@ This section currently applies @emph{only} to Microsoft Windows.
WoMan provides partial experimental support for special symbols,
initially only for MS-Windows and only for MS-Windows fonts. This
-includes both non-@sc{ascii} characters from the main text font and use
+includes both non-@acronym{ASCII} characters from the main text font and use
of a separate symbol font. Later, support will be added for other font
types (e.g.@: @code{bdf} fonts) and for the X Window System. In Emacs
20.7, the current support works partially under Windows 9x but may not
@@ -1453,7 +1452,7 @@ work on any other platform.
@vtable @code
@item woman-use-extended-font
-A boolean value. If non-@code{nil} then WoMan may use non-@sc{ascii} characters
+A boolean value. If non-@code{nil} then WoMan may use non-@acronym{ASCII} characters
from the default font. Default is @code{t}.
@item woman-use-symbol-font
@@ -1642,3 +1641,7 @@ Eli Zaretskii, @email{eliz@@is.elta.co.il}
@printindex cp
@bye
+
+@ignore
+ arch-tag: a1a6b715-396f-4378-9b94-0b2ca0aa5028
+@end ignore
diff --git a/man/xresources.texi b/man/xresources.texi
index 702c6feedc4..515ad9f4b4c 100644
--- a/man/xresources.texi
+++ b/man/xresources.texi
@@ -142,6 +142,7 @@ frame. Select one of them, such as @samp{menubar}, then select
@samp{Show Resource Box} from the @samp{Commands} menu. This displays
a list of all the meaningful X resources and allows you to edit them.
Changes take effect immediately if you click on the @samp{Apply} button.
+(See the @code{editres} man page for more details.)
@node Table of Resources
@appendixsec Table of X Resources for Emacs
@@ -392,15 +393,22 @@ In the menu bar, the color of the foreground for a selected item.
@item horizontalSpacing
Horizontal spacing in pixels between items. Default is 3.
@item verticalSpacing
-Vertical spacing in pixels between items. Default is 1.
+Vertical spacing in pixels between items. Default is 2.
@item arrowSpacing
Horizontal spacing between the arrow (which indicates a submenu) and
the associated text. Default is 10.
@item shadowThickness
-Thickness of shadow line around the widget.
+Thickness of shadow line around the widget. Default is 1.
+
+Also determines the thickness of shadow lines around other objects,
+for instance 3D buttons and arrows. If you have the impression that
+the arrows in the menus do not stand out clearly enough or that the
+difference between ``in'' and ``out'' buttons is difficult to see, set
+this to 2. If you have no problems with visibility, the default
+probably looks better. The background color may also have some effect
+on the contrast.
@item margin
-The margin of the menu bar, in characters. The default of 4 makes the
-menu bar appear like the LessTif/Motif one.
+The margin of the menu bar, in characters. Default is 1.
@end table
@node LessTif Resources
@@ -551,7 +559,12 @@ the standard GTK @file{~/.gtkrc-2.0} file or with the Emacs specific
customizing specific GTK widget features. To customize Emacs font,
background, faces etc., use the normal X resources, see @ref{Resources}.
-In these files you first defines a style and then how to apply that style
+ Some GTK themes override these mechanisms, which means that using
+these mechanisms will not work to customize them. We recommend that
+you use @file{~/.emacs.d/gtkrc} for customizations, since
+@file{~/.gtkrc-2.0} seems to be ignored when running GConf with GNOME.
+
+ In these files you first defines a style and then how to apply that style
to widgets (@pxref{GTK widget names}). Here is an example of how to
change the font for Emacs menus:
@@ -566,6 +579,21 @@ widget "*emacs-menuitem*" style "menufont"
@end smallexample
+ Here is a more elaborate example, showing how to change the parts of
+the scroll bar:
+
+@smallexample
+style "scroll"
+@{
+ fg[NORMAL] = "red"@ @ @ @ @ # The arrow color.
+ bg[NORMAL] = "yellow"@ @ # The thumb and background around the arrow.
+ bg[ACTIVE] = "blue"@ @ @ @ # The trough color.
+ bg[PRELIGHT] = "white"@ # The thumb color when the mouse is over it.
+@}
+
+widget "*verticalScrollBar*" style "scroll"
+@end smallexample
+
There are some things you can set without using any style or widget name,
which affect GTK as a whole. Most of these are poorly documented, but can
be found in the `Properties' section of the documentation page for
@@ -702,7 +730,7 @@ The names for the emacs widgets, and their classes, are:
@tab @code{GtkVHbox}
@item @code{emacs}
@tab @code{GtkFixed}
-@item @code{verticalScrollbar}
+@item @code{verticalScrollBar}
@tab @code{GtkVScrollbar}
@item @code{emacs-toolbar}
@tab @code{GtkToolbar}
@@ -717,7 +745,7 @@ Thus, for Emacs you can write the two examples above as:
@smallexample
widget "Emacs.pane.menubar" style "my_style"
-widget "Emacs.pane.emacs.verticalScrollbar" style "my_style"
+widget "Emacs.pane.emacs.verticalScrollBar" style "my_style"
@end smallexample
GTK absolute names are quite strange when it comes to menus
@@ -929,3 +957,7 @@ family. It corresponds to the fifth part of an X font name. It is one of
@noindent
@var{size} is a decimal number that describes the font size in points.
+
+@ignore
+ arch-tag: 9b6ff773-48b6-41f6-b2f9-f114b8bdd97f
+@end ignore