diff options
| author | Eli Zaretskii | 2016-01-13 20:29:36 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2016-01-13 20:29:36 +0200 |
| commit | 3db8ce4fbd75b978d658df58810adf1deca04708 (patch) | |
| tree | df0f7f79227152c046d7fb55b771214afebf0904 | |
| parent | 2e12e8d74855b953e07252c7b173f34f79808296 (diff) | |
| download | emacs-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.texi | 18 | ||||
| -rw-r--r-- | doc/lispref/hooks.texi | 24 | ||||
| -rw-r--r-- | etc/NEWS | 4 |
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 | |||
| 95 | newly arriving input. | 95 | newly arriving input. |
| 96 | @end defun | 96 | @end defun |
| 97 | 97 | ||
| 98 | @defvar pre-redisplay-function | ||
| 99 | A function run just before redisplay. It is called with one argument, | ||
| 100 | the 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 |
| 104 | not change how Emacs decides which parts of its frame(s) to redisplay. | 99 | not change how Emacs decides which parts of its frame(s) to redisplay. |
| 105 | By contrast, the following function adds certain windows to the | 100 | By 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 | |||
| 117 | it waits for input, or when the function @code{redisplay} is called. | 112 | it waits for input, or when the function @code{redisplay} is called. |
| 118 | @end defun | 113 | @end defun |
| 119 | 114 | ||
| 115 | @defvar pre-redisplay-function | ||
| 116 | A function run just before redisplay. It is called with one argument, | ||
| 117 | the set of windows to be redisplayed. The set can be @code{nil}, | ||
| 118 | meaning only the selected window, or @code{t}, meaning all the | ||
| 119 | windows. | ||
| 120 | @end defvar | ||
| 121 | |||
| 122 | @defvar pre-redisplay-functions | ||
| 123 | This hook is run just before redisplay. It is called once in each | ||
| 124 | window that is about to be redisplayed, with @code{current-buffer} set | ||
| 125 | to 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 |
| 195 | An abnormal hook run by prefix commands (such as @kbd{C-u}) which | 185 | An 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 |
| 207 | types @kbd{C-u -} or follows @kbd{C-u} with a digit. | 197 | types @kbd{C-u -} or follows @kbd{C-u} with a digit. |
| 208 | 198 | ||
| 199 | @item pre-redisplay-functions | ||
| 200 | Hook run in each window just before redisplaying it. @xref{Forcing | ||
| 201 | Redisplay}. | ||
| 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 |
| @@ -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'. |
| 1350 | Previously, the default value of `nil' implied using `read'. | 1350 | Previously, 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'. | ||
| 1354 | It 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 | ||