aboutsummaryrefslogtreecommitdiffstats
path: root/doc/lispref
diff options
context:
space:
mode:
authorStefan Monnier2010-09-30 01:28:20 +0200
committerStefan Monnier2010-09-30 01:28:20 +0200
commita01a7932080e8a6e7bc8472c58cefabcc2c37df3 (patch)
tree94b28b19c8f1536e76ffe7d5826811b74a79e3a5 /doc/lispref
parentcc390e46c7ba95b76ea133d98fd386214cd01709 (diff)
parent6b0f7311f16646e0de2045b2410e20921901c616 (diff)
downloademacs-a01a7932080e8a6e7bc8472c58cefabcc2c37df3.tar.gz
emacs-a01a7932080e8a6e7bc8472c58cefabcc2c37df3.zip
Merge from trunk
Diffstat (limited to 'doc/lispref')
-rw-r--r--doc/lispref/ChangeLog4
-rw-r--r--doc/lispref/text.texi16
2 files changed, 14 insertions, 6 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index e3df5fab9e9..ec065e9ce76 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -1,3 +1,7 @@
12010-09-18 Stefan Monnier <monnier@iro.umontreal.ca>
2
3 * text.texi (Special Properties): Clarify when modification-hooks run.
4
12010-09-11 Stefan Monnier <monnier@iro.umontreal.ca> 52010-09-11 Stefan Monnier <monnier@iro.umontreal.ca>
2 6
3 * syntax.texi (Syntax Flags): Document new `c' flag. 7 * syntax.texi (Syntax Flags): Document new `c' flag.
diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi
index ff4e65d299f..04e1e714133 100644
--- a/doc/lispref/text.texi
+++ b/doc/lispref/text.texi
@@ -3230,12 +3230,16 @@ the @code{line-prefix} variable). @xref{Truncation}.
3230@cindex hooks for changing a character 3230@cindex hooks for changing a character
3231@kindex modification-hooks @r{(text property)} 3231@kindex modification-hooks @r{(text property)}
3232If a character has the property @code{modification-hooks}, then its 3232If a character has the property @code{modification-hooks}, then its
3233value should be a list of functions; modifying that character calls all 3233value should be a list of functions; modifying that character calls
3234of those functions. Each function receives two arguments: the beginning 3234all of those functions before the actual modification. Each function
3235and end of the part of the buffer being modified. Note that if a 3235receives two arguments: the beginning and end of the part of the
3236particular modification hook function appears on several characters 3236buffer being modified. Note that if a particular modification hook
3237being modified by a single primitive, you can't predict how many times 3237function appears on several characters being modified by a single
3238the function will be called. 3238primitive, you can't predict how many times the function will
3239be called.
3240Furthermore, insertion will not modify any existing character, so this
3241hook will only be run when removing some characters, replacing them
3242with others, or changing their text-properties.
3239 3243
3240If these functions modify the buffer, they should bind 3244If these functions modify the buffer, they should bind
3241@code{inhibit-modification-hooks} to @code{t} around doing so, to 3245@code{inhibit-modification-hooks} to @code{t} around doing so, to