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
emacs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
emacs
emacs
Commits
5f079267
Commit
5f079267
authored
Apr 10, 1994
by
Richard M. Stallman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(Vafter_change_functions, Vbefore_change_functions): New variables.
(syms_of_buffer): Set up Lisp vars.
parent
867dd159
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
4 deletions
+31
-4
src/buffer.c
src/buffer.c
+31
-4
No files found.
src/buffer.c
View file @
5f079267
...
@@ -109,6 +109,8 @@ Lisp_Object Vbuffer_alist;
...
@@ -109,6 +109,8 @@ Lisp_Object Vbuffer_alist;
/* Functions to call before and after each text change. */
/* Functions to call before and after each text change. */
Lisp_Object
Vbefore_change_function
;
Lisp_Object
Vbefore_change_function
;
Lisp_Object
Vafter_change_function
;
Lisp_Object
Vafter_change_function
;
Lisp_Object
Vbefore_change_functions
;
Lisp_Object
Vafter_change_functions
;
Lisp_Object
Vtransient_mark_mode
;
Lisp_Object
Vtransient_mark_mode
;
...
@@ -2586,8 +2588,8 @@ the beginning and end of the range of old text to be changed.\n\
...
@@ -2586,8 +2588,8 @@ the beginning and end of the range of old text to be changed.\n\
No information is given about the length of the text after the change.
\n
\
No information is given about the length of the text after the change.
\n
\
position of the change
\n
\
position of the change
\n
\
\n
\
\n
\
While executing the `before-change-function', changes to buffers do not
\n
\
Buffer changes made while executing the `before-change-function'
\n
\
cause calls to any `before-change-function' or `after-change-function'
."
);
don't call any before-change or after-change functions
."
);
Vbefore_change_function
=
Qnil
;
Vbefore_change_function
=
Qnil
;
DEFVAR_LISP
(
"after-change-function"
,
&
Vafter_change_function
,
DEFVAR_LISP
(
"after-change-function"
,
&
Vafter_change_function
,
...
@@ -2599,10 +2601,35 @@ and the length of the pre-change text replaced by that range.\n\
...
@@ -2599,10 +2601,35 @@ and the length of the pre-change text replaced by that range.\n\
for a deletion, that length is the number of characters deleted,
\n
\
for a deletion, that length is the number of characters deleted,
\n
\
and the post-change beginning and end are at the same place.)
\n
\
and the post-change beginning and end are at the same place.)
\n
\
\n
\
\n
\
While executing the `after-change-function', changes to buffers do not
\n
\
Buffer changes made while executing the `after-change-function'
\n
\
cause calls to any `before-change-function' or `after-change-function'
."
);
don't call any before-change or after-change functions
."
);
Vafter_change_function
=
Qnil
;
Vafter_change_function
=
Qnil
;
DEFVAR_LISP
(
"before-change-functions"
,
&
Vbefore_change_functions
,
"List of functions to call before each text change.
\n
\
Two arguments are passed to each function: the positions of
\n
\
the beginning and end of the range of old text to be changed.
\n
\
\(For an insertion, the beginning and end are at the same place.)
\n
\
No information is given about the length of the text after the change.
\n
\
position of the change
\n
\
\n
\
Buffer changes made while executing the `before-change-functions'
\n
\
don't call any before-change or after-change functions."
);
Vbefore_change_functions
=
Qnil
;
DEFVAR_LISP
(
"after-change-functions"
,
&
Vafter_change_functions
,
"List of function to call after each text change.
\n
\
Three arguments are passed to each function: the positions of
\n
\
the beginning and end of the range of changed text,
\n
\
and the length of the pre-change text replaced by that range.
\n
\
\(For an insertion, the pre-change length is zero;
\n
\
for a deletion, that length is the number of characters deleted,
\n
\
and the post-change beginning and end are at the same place.)
\n
\
\n
\
Buffer changes made while executing the `after-change-functions'
\n
\
don't call any before-change or after-change functions."
);
Vafter_change_functions
=
Qnil
;
DEFVAR_LISP
(
"first-change-hook"
,
&
Vfirst_change_hook
,
DEFVAR_LISP
(
"first-change-hook"
,
&
Vfirst_change_hook
,
"A list of functions to call before changing a buffer which is unmodified.
\n
\
"A list of functions to call before changing a buffer which is unmodified.
\n
\
The functions are run using the `run-hooks' function."
);
The functions are run using the `run-hooks' 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