aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEli Zaretskii2016-01-13 20:29:36 +0200
committerEli Zaretskii2016-01-13 20:29:36 +0200
commit3db8ce4fbd75b978d658df58810adf1deca04708 (patch)
treedf0f7f79227152c046d7fb55b771214afebf0904
parent2e12e8d74855b953e07252c7b173f34f79808296 (diff)
downloademacs-3db8ce4fbd75b978d658df58810adf1deca04708.tar.gz
emacs-3db8ce4fbd75b978d658df58810adf1deca04708.zip
Document 'pre-redisplay-functions'
* doc/lispref/hooks.texi (Standard Hooks): * doc/lispref/display.texi (Forcing Redisplay): Document 'pre-redisplay-functions'.
-rw-r--r--doc/lispref/display.texi18
-rw-r--r--doc/lispref/hooks.texi24
-rw-r--r--etc/NEWS4
3 files changed, 30 insertions, 16 deletions
diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi
index 93b00e17dac..1ac0f05c7d4 100644
--- a/doc/lispref/display.texi
+++ b/doc/lispref/display.texi
@@ -95,11 +95,6 @@ redisplay proceeded to completion; it could have been preempted by
95newly arriving input. 95newly arriving input.
96@end defun 96@end defun
97 97
98@defvar pre-redisplay-function
99A function run just before redisplay. It is called with one argument,
100the set of windows to redisplay.
101@end defvar
102
103 Although @code{redisplay} tries immediately to redisplay, it does 98 Although @code{redisplay} tries immediately to redisplay, it does
104not change how Emacs decides which parts of its frame(s) to redisplay. 99not change how Emacs decides which parts of its frame(s) to redisplay.
105By contrast, the following function adds certain windows to the 100By contrast, the following function adds certain windows to the
@@ -117,6 +112,19 @@ This function does not do a redisplay immediately; Emacs does that as
117it waits for input, or when the function @code{redisplay} is called. 112it waits for input, or when the function @code{redisplay} is called.
118@end defun 113@end defun
119 114
115@defvar pre-redisplay-function
116A function run just before redisplay. It is called with one argument,
117the set of windows to be redisplayed. The set can be @code{nil},
118meaning only the selected window, or @code{t}, meaning all the
119windows.
120@end defvar
121
122@defvar pre-redisplay-functions
123This hook is run just before redisplay. It is called once in each
124window that is about to be redisplayed, with @code{current-buffer} set
125to the buffer displayed in that window.
126@end defvar
127
120@node Truncation 128@node Truncation
121@section Truncation 129@section Truncation
122@cindex line wrapping 130@cindex line wrapping
diff --git a/doc/lispref/hooks.texi b/doc/lispref/hooks.texi
index b8f761de30e..1027aa0343f 100644
--- a/doc/lispref/hooks.texi
+++ b/doc/lispref/hooks.texi
@@ -180,16 +180,6 @@ Hook run when about to switch windows with a mouse command.
180@item mouse-position-function 180@item mouse-position-function
181@xref{Mouse Position}. 181@xref{Mouse Position}.
182 182
183@item post-command-hook
184@itemx pre-command-hook
185@xref{Command Overview}.
186
187@item post-gc-hook
188@xref{Garbage Collection}.
189
190@item post-self-insert-hook
191@xref{Keymaps and Minor Modes}.
192
193@item prefix-command-echo-keystrokes-functions 183@item prefix-command-echo-keystrokes-functions
194@vindex prefix-command-echo-keystrokes-functions 184@vindex prefix-command-echo-keystrokes-functions
195An abnormal hook run by prefix commands (such as @kbd{C-u}) which 185An abnormal hook run by prefix commands (such as @kbd{C-u}) which
@@ -206,6 +196,20 @@ the current prefix command state to the next command. For example,
206@kbd{C-u} needs to pass the state to the next command when the user 196@kbd{C-u} needs to pass the state to the next command when the user
207types @kbd{C-u -} or follows @kbd{C-u} with a digit. 197types @kbd{C-u -} or follows @kbd{C-u} with a digit.
208 198
199@item pre-redisplay-functions
200Hook run in each window just before redisplaying it. @xref{Forcing
201Redisplay}.
202
203@item post-command-hook
204@itemx pre-command-hook
205@xref{Command Overview}.
206
207@item post-gc-hook
208@xref{Garbage Collection}.
209
210@item post-self-insert-hook
211@xref{Keymaps and Minor Modes}.
212
209@ignore 213@ignore
210@item prog-mode-hook 214@item prog-mode-hook
211@itemx special-mode-hook 215@itemx special-mode-hook
diff --git a/etc/NEWS b/etc/NEWS
index 076835c3d20..c51136faf63 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -1349,7 +1349,9 @@ file byte offsets, given the file's encoding.
1349** The default value of `load-read-function' is now `read'. 1349** The default value of `load-read-function' is now `read'.
1350Previously, the default value of `nil' implied using `read'. 1350Previously, the default value of `nil' implied using `read'.
1351 1351
1352** New hook `pre-redisplay-functions', a bit easier to use than pre-redisplay-function. 1352+++
1353** New hook `pre-redisplay-functions'.
1354It is a bit easier to use than `pre-redisplay-function'.
1353 1355
1354** The second arg of `looking-back' should always be provided explicitly. 1356** The second arg of `looking-back' should always be provided explicitly.
1355 1357