This manual is for CC Mode in Emacs.
Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
- 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
+2003, 2004, 2005, 2006 Free Software Foundation, Inc.
@quotation
Permission is granted to copy, distribute and/or modify this document
@vskip 0pt plus 1filll
@insertcopying
-This manual was generated from $Revision: 1.35 $ of $RCSfile: cc-mode.texi,v $, which can be
+This manual was generated from $Revision$ of $RCSfile$, which can be
downloaded from
@url{http://cvs.savannah.gnu.org/viewcvs/emacs/emacs/man/cc-mode.texi}.
@end titlepage
@item The (indentation) style
The basic ``shape'' of indentation created by @ccmode{}---by default,
this is @code{gnu} style (except for Java and AWK buffers). A list of
-the availables styles and their descriptions can be found in
+the available styles and their descriptions can be found in
@ref{Built-in Styles}. A complete specification of the @ccmode{}
style system, including how to create your own style, can be found in
the chapter @ref{Styles}. To set your style to @code{linux}, either
about it for normal use.
@code{c-indent-command} does different things, depending on the
-settting of @code{c-syntactic-indentation} (@pxref{Indentation Engine
+setting of @code{c-syntactic-indentation} (@pxref{Indentation Engine
Basics}):
@itemize @bullet
@dfn{subword}. Here are some examples:
@multitable {@samp{NSGraphicsContext}} {@samp{NS}, @samp{Graphics}, and @samp{Context}}
-@headitem Nomenclature
+@c This could be converted to @headitem when we require Texinfo 4.7
+@iftex
+@item @b{Nomenclature}
+ @tab @b{Subwords}
+@end iftex
+@ifnottex
+@item Nomenclature
@tab Subwords
+@item ---------------------------------------------------------
+@end ifnottex
@item @samp{GtkWindow}
@tab @samp{Gtk} and @samp{Window}
@item @samp{EmacsFrameClass}
@findex c-downcase-subword
@findex downcase-subword (c-)
@multitable @columnfractions .20 .40 .40
-@headitem Key @tab Word oriented command @tab Subword oriented command
+@c This could be converted to @headitem when we require Texinfo 4.7
+@iftex
+@item @b{Key} @tab @b{Word oriented command} @tab @b{Subword oriented command}
+@end iftex
+@ifnottex
+@item Key @tab Word oriented command @tab Subword oriented command
+@item ----------------------------------------------------------------------------
+@end ifnottex
@item @kbd{M-f} @tab @code{forward-word} @tab @code{c-forward-subword}
@item @kbd{M-b} @tab @code{backward-word} @tab @code{c-backward-subword}
@item @kbd{M-@@} @tab @code{mark-word} @tab @code{c-mark-subword}
@chapter Configuration Basics
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
-@cindex Emacs Initiliazation File
+@cindex Emacs Initialization File
@cindex Configuration
You configure @ccmode{} by setting Lisp variables and calling (and
perhaps writing) Lisp functions@footnote{DON'T PANIC!!! This isn't
@ccmode{} still uses the value on that variable if it's set.} is used
then as the comment prefix. It defaults to @samp{*
}@footnote{Actually, this default setting of
-@code{c-block-comment-prefix} typically gets overriden by the default
+@code{c-block-comment-prefix} typically gets overridden by the default
style @code{gnu}, which sets it to blank. You can see the line
splitting effect described here by setting a different style,
e.g. @code{k&r} @xref{Choosing a Style}.}, which makes a comment
that @var{action}s are usually a list containing some combination of
the symbols @code{before} and @code{after} (@pxref{Hanging Braces}).
For more flexibility, you can instead specify brace ``hanginess'' by
-giving a synctactic symbol an @dfn{action function} in
+giving a syntactic symbol an @dfn{action function} in
@code{c-hanging-braces-alist}; this function determines the
``hanginess'' of a brace, usually by looking at the code near it.
the proper functioning of @ccmode{}.
This variable is also bound in three other circumstances:
-(i)@tie{}when calling a c-hanging-semi&comma-criteria function
-(@pxref{Hanging Semicolons and Commas}; (ii)@tie{}when calling a
-line-up function (@pxref{Custom Line-Up}; (iii)@tie{}when calling a
+(i)@w{ }when calling a c-hanging-semi&comma-criteria function
+(@pxref{Hanging Semicolons and Commas}; (ii)@w{ }when calling a
+line-up function (@pxref{Custom Line-Up}; (iii)@w{ }when calling a
c-special-indent-hook function (@pxref{Other Indentation}).
@end defvar
@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@tie{}(SIGINT,
-SIG_IGN)} and @samp{abort@tie{}()}. Clean up occurs when the opening
+mandated by the GNU coding standards, e.g. @samp{signal@w{ }(SIGINT,
+SIG_IGN)} and @samp{abort@w{ }()}. Clean up occurs when the opening
parenthesis is typed. This clean-up should never be active in AWK
Mode, since such a space is syntactically invalid for user defined
functions.
@item cpp-macro
The start of a preprocessor macro definition. @ref{Literal Symbols}.
@item cpp-define-intro
-The first line inside a multiline preproprocessor macro if
+The first line inside a multiline preprocessor macro if
@code{c-syntactic-indentation-in-macros} is set. @ref{Multiline Macro
Symbols}.
@item cpp-macro-cont
different one''. @xref{c-offsets-alist}.
The subsections below describe all the standard line-up functions,
-categorized by the sort of token the lining-up centres around. For
+categorized by the sort of token the lining-up centers around. For
each of these functions there is a ``works with'' list that indicates
which syntactic symbols the function is intended to be used with.
@comment !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Normally, the lines in a multi-line macro are indented relative to
-eachother as though they were code. You can suppress this behaviour
+each other as though they were code. You can suppress this behaviour
by setting the following user option:
@defopt c-syntactic-indentation-in-macros
(defun my-c-initialization-hook ()
(define-key c-mode-base-map "\C-m" 'c-context-line-break)
(define-key c-mode-base-map [?\C-\M-a] 'c-beginning-of-defun)
- (define-key c-mode-base-map [?\C-\M-e] 'c-end-of-defun)
+ (define-key c-mode-base-map [?\C-\M-e] 'c-end-of-defun))
(add-hook 'c-initialization-hook 'my-c-initialization-hook)
;; offset customizations not in my-c-style