Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
emacs
emacs
Commits
584b8104
Commit
584b8104
authored
Aug 22, 1997
by
Richard M. Stallman
Browse files
Explain after-change-functions and chars vs bytes.
parent
839dd834
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
3 deletions
+10
-3
lispref/text.texi
lispref/text.texi
+10
-3
No files found.
lispref/text.texi
View file @
584b8104
...
...
@@ -2973,9 +2973,16 @@ buffer that is about to change is always the current buffer.
This variable holds a list of a functions to call after any buffer
modification. Each function receives three arguments: the beginning and
end of the region just changed, and the length of the text that existed
before the change. (To get the current length, subtract the region
beginning from the region end.) All three arguments are integers. The
buffer that's about to change is always the current buffer.
before the change. All three arguments are integers. The buffer that's
about to change is always the current buffer.
The length of the old text is measured in bytes; it is the difference
between the buffer positions before and after that text, before the
change. As for the changed text, its length in bytes is simply the
difference between the first two arguments. If you want the length
in @emph{characters} of the text before the change, you should use
a @code{before-change-functions} function that calls @code{chars-in-region}
(@pxref{Chars and Bytes}).
@end defvar
@defvar before-change-function
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment