summaryrefslogtreecommitdiff
path: root/doc/lispref/modes.texi
diff options
context:
space:
mode:
authorChong Yidong <cyd@gnu.org>2012-02-16 22:43:41 +0800
committerChong Yidong <cyd@gnu.org>2012-02-16 22:43:41 +0800
commit4230351b56aa91460e144ed0845692652c9b47ec (patch)
treea1ed79f490f25c40315a0ce090d8f2d4e8d392bf /doc/lispref/modes.texi
parent74db95ca362801386ca2ecd4cc9fc0d30a6d6b8f (diff)
downloademacs-4230351b56aa91460e144ed0845692652c9b47ec.tar.gz
Update Syntax chapter of Lisp manual.
* doc/lispref/syntax.texi (Syntax Tables, Syntax Descriptors) (Syntax Table Functions): Copyedits. (Syntax Basics): Don't repeat the material in the preceding node. (Syntax Class Table): Use a table. (Syntax Properties): Document syntax-propertize-function and syntax-propertize-extend-region-functions. (Motion via Parsing): Fix indentation. (Parser State): Update for the new "c" comment style. Fix description of item 7 (comment style). * doc/lispref/modes.texi (Syntactic Font Lock): Add xref to Syntactic Font Lock node.
Diffstat (limited to 'doc/lispref/modes.texi')
-rw-r--r--doc/lispref/modes.texi10
1 files changed, 8 insertions, 2 deletions
diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi
index c3356ef882a..3c5fbfb22c9 100644
--- a/doc/lispref/modes.texi
+++ b/doc/lispref/modes.texi
@@ -2995,6 +2995,12 @@ which syntactic constructs to highlight. There are several variables
that affect syntactic fontification; you should set them by means of
@code{font-lock-defaults} (@pxref{Font Lock Basics}).
+ Whenever Font Lock mode performs syntactic fontification on a stretch
+of text, it first calls the function specified by
+@code{syntax-propertize-function}. Major modes can use this to apply
+@code{syntax-table} text properties to override the buffer's syntax
+table in special cases. @xref{Syntax Properties}.
+
@defvar font-lock-keywords-only
If the value of this variable is non-@code{nil}, Font Lock does not do
syntactic fontification, only search-based fontification based on
@@ -3191,7 +3197,7 @@ reasonably fast.
@end defvar
@node Auto-Indentation
-@section Auto-indentation of code
+@section Automatic Indentation of code
For programming languages, an important feature of a major mode is to
provide automatic indentation. This is controlled in Emacs by
@@ -3214,7 +3220,7 @@ for a compiler, but on the other hand, the parser embedded in the
indentation code will want to be somewhat friendly to syntactically
incorrect code.
-Good maintainable indentation functions usually fall into 2 categories:
+Good maintainable indentation functions usually fall into two categories:
either parsing forward from some ``safe'' starting point until the
position of interest, or parsing backward from the position of interest.
Neither of the two is a clearly better choice than the other: parsing