aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Kangas2022-07-31 01:44:22 +0200
committerStefan Kangas2022-07-31 01:44:22 +0200
commit5b29f8cd98c014b4b3e5844ef128ba97e65ea036 (patch)
tree90475b7bdcae4146ce8b4c9ce11d979ed00ba600
parenta3d974d59f4c352724f5562f4cc53e8a8f6e8cab (diff)
downloademacs-5b29f8cd98c014b4b3e5844ef128ba97e65ea036.tar.gz
emacs-5b29f8cd98c014b4b3e5844ef128ba97e65ea036.zip
Delete redisplay-end-trigger-functions and related defuns
This variable and related functions have been obsolete since 23.1. The last things to depend on this (fast-lock.el and lazy-lock.el) were recently removed. * src/dispextern.h (struct it): Delete field 'redisplay_end_trigger_charpos'. * src/window.c (Fwindow_redisplay_end_trigger) (Fset_window_redisplay_end_trigger): Delete defuns and corresponding defsubrs for functions obsolete since 23.1. * src/window.h (wset_redisplay_end_trigger): Delete function. (GCALIGNED_STRUCT): Delete 'redisplay_end_trigger'. * src/xdisp.c (run_redisplay_end_trigger_hook): Delete function. (syms_of_xdisp) <redisplay_end_trigger_functions>: Delete variable obsolete since 23.1. (init_iterator, next_element_from_buffer): Don't run or set above deleted hook variable. * lisp/subr.el: Delete obsoletion definitions for above deleted defuns and variable. * doc/lispref/hooks.texi (Standard Hooks): * lisp/emacs-lisp/byte-opt.el (side-effect-free-fns): * lisp/loadhist.el (unload-feature-special-hooks): Don't mention above deleted variable. * admin/coccinelle/window.cocci: Adjust for above changes.
-rw-r--r--admin/coccinelle/window.cocci6
-rw-r--r--doc/lispref/hooks.texi1
-rw-r--r--etc/NEWS3
-rw-r--r--lisp/emacs-lisp/byte-opt.el2
-rw-r--r--lisp/loadhist.el2
-rw-r--r--lisp/subr.el3
-rw-r--r--src/dispextern.h3
-rw-r--r--src/window.c27
-rw-r--r--src/window.h10
-rw-r--r--src/xdisp.c49
10 files changed, 4 insertions, 102 deletions
diff --git a/admin/coccinelle/window.cocci b/admin/coccinelle/window.cocci
index 1448febfcc1..4543fb2ce15 100644
--- a/admin/coccinelle/window.cocci
+++ b/admin/coccinelle/window.cocci
@@ -106,9 +106,6 @@ Lisp_Object O;
106- W->column_number_displayed 106- W->column_number_displayed
107+ WVAR (W, column_number_displayed) 107+ WVAR (W, column_number_displayed)
108| 108|
109- W->redisplay_end_trigger
110+ WVAR (W, redisplay_end_trigger)
111|
112- W->combination_limit 109- W->combination_limit
113+ WVAR (W, combination_limit) 110+ WVAR (W, combination_limit)
114| 111|
@@ -225,9 +222,6 @@ Lisp_Object O;
225- XWINDOW (O)->column_number_displayed 222- XWINDOW (O)->column_number_displayed
226+ WVAR (XWINDOW (O), column_number_displayed) 223+ WVAR (XWINDOW (O), column_number_displayed)
227| 224|
228- XWINDOW (O)->redisplay_end_trigger
229+ WVAR (XWINDOW (O), redisplay_end_trigger)
230|
231- XWINDOW (O)->combination_limit 225- XWINDOW (O)->combination_limit
232+ WVAR (XWINDOW (O), combination_limit) 226+ WVAR (XWINDOW (O), combination_limit)
233| 227|
diff --git a/doc/lispref/hooks.texi b/doc/lispref/hooks.texi
index 59b7930732f..339e1387d2e 100644
--- a/doc/lispref/hooks.texi
+++ b/doc/lispref/hooks.texi
@@ -280,7 +280,6 @@ kbd-macro-termination-hook
280signal-hook-function 280signal-hook-function
281 281
282C functions: 282C functions:
283redisplay-end-trigger-functions
284x-lost-selection-functions 283x-lost-selection-functions
285x-sent-selection-functions 284x-sent-selection-functions
286 285
diff --git a/etc/NEWS b/etc/NEWS
index e74f60780f9..489948214df 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -2452,8 +2452,9 @@ but switching to `ash` is generally much preferable.
2452--- 2452---
2453** Some functions and variables obsolete since Emacs 23 have been removed: 2453** Some functions and variables obsolete since Emacs 23 have been removed:
2454'find-emacs-lisp-shadows', 'newsticker-cache-filename', 2454'find-emacs-lisp-shadows', 'newsticker-cache-filename',
2455'redisplay-end-trigger-functions', 'set-window-redisplay-end-trigger',
2455'unify-8859-on-decoding-mode', 'unify-8859-on-encoding-mode', 2456'unify-8859-on-decoding-mode', 'unify-8859-on-encoding-mode',
2456'vc-arch-command'. 2457'vc-arch-command', 'window-redisplay-end-trigger'.
2457 2458
2458+++ 2459+++
2459** New generic function 'function-documentation'. 2460** New generic function 'function-documentation'.
diff --git a/lisp/emacs-lisp/byte-opt.el b/lisp/emacs-lisp/byte-opt.el
index 9817fa0eb15..7a4bbf2e8af 100644
--- a/lisp/emacs-lisp/byte-opt.el
+++ b/lisp/emacs-lisp/byte-opt.el
@@ -1471,7 +1471,7 @@ See Info node `(elisp) Integer Basics'."
1471 window-next-buffers window-next-sibling window-new-normal 1471 window-next-buffers window-next-sibling window-new-normal
1472 window-new-total window-normal-size window-parameter window-parameters 1472 window-new-total window-normal-size window-parameter window-parameters
1473 window-parent window-pixel-edges window-point window-prev-buffers 1473 window-parent window-pixel-edges window-point window-prev-buffers
1474 window-prev-sibling window-redisplay-end-trigger window-scroll-bars 1474 window-prev-sibling window-scroll-bars
1475 window-start window-text-height window-top-child window-top-line 1475 window-start window-text-height window-top-child window-top-line
1476 window-total-height window-total-width window-use-time window-vscroll 1476 window-total-height window-total-width window-use-time window-vscroll
1477 window-width zerop)) 1477 window-width zerop))
diff --git a/lisp/loadhist.el b/lisp/loadhist.el
index 39481ab0684..b4ed0432465 100644
--- a/lisp/loadhist.el
+++ b/lisp/loadhist.el
@@ -128,7 +128,7 @@ from a file."
128 font-lock-unfontify-region-function 128 font-lock-unfontify-region-function
129 kill-buffer-query-functions kill-emacs-query-functions 129 kill-buffer-query-functions kill-emacs-query-functions
130 lisp-indent-function mouse-position-function 130 lisp-indent-function mouse-position-function
131 redisplay-end-trigger-functions suspend-tty-functions 131 suspend-tty-functions
132 temp-buffer-show-function window-scroll-functions 132 temp-buffer-show-function window-scroll-functions
133 window-size-change-functions write-contents-functions 133 window-size-change-functions write-contents-functions
134 write-file-functions write-region-annotate-functions) 134 write-file-functions write-region-annotate-functions)
diff --git a/lisp/subr.el b/lisp/subr.el
index c220a7f4a88..1a16d781174 100644
--- a/lisp/subr.el
+++ b/lisp/subr.el
@@ -1860,10 +1860,7 @@ be a list of the form returned by `event-start' and `event-end'."
1860 1860
1861;;;; Obsolescence declarations for variables, and aliases. 1861;;;; Obsolescence declarations for variables, and aliases.
1862 1862
1863(make-obsolete-variable 'redisplay-end-trigger-functions 'jit-lock-register "23.1")
1864(make-obsolete-variable 'redisplay-dont-pause nil "24.5") 1863(make-obsolete-variable 'redisplay-dont-pause nil "24.5")
1865(make-obsolete 'window-redisplay-end-trigger nil "23.1")
1866(make-obsolete 'set-window-redisplay-end-trigger nil "23.1")
1867(make-obsolete-variable 'operating-system-release nil "28.1") 1864(make-obsolete-variable 'operating-system-release nil "28.1")
1868(make-obsolete-variable 'inhibit-changing-match-data 'save-match-data "29.1") 1865(make-obsolete-variable 'inhibit-changing-match-data 'save-match-data "29.1")
1869 1866
diff --git a/src/dispextern.h b/src/dispextern.h
index 817211e795e..037e02ff58f 100644
--- a/src/dispextern.h
+++ b/src/dispextern.h
@@ -2350,9 +2350,6 @@ struct it
2350 used for overlay strings and strings from display properties. */ 2350 used for overlay strings and strings from display properties. */
2351 ptrdiff_t string_nchars; 2351 ptrdiff_t string_nchars;
2352 2352
2353 /* Position at which redisplay end trigger functions should be run. */
2354 ptrdiff_t redisplay_end_trigger_charpos;
2355
2356 /* True means multibyte characters are enabled. */ 2353 /* True means multibyte characters are enabled. */
2357 bool_bf multibyte_p : 1; 2354 bool_bf multibyte_p : 1;
2358 2355
diff --git a/src/window.c b/src/window.c
index 33a1b8a4bf4..afb8f75537b 100644
--- a/src/window.c
+++ b/src/window.c
@@ -1300,31 +1300,6 @@ window so that the location of point moves off-window. */)
1300 return set_window_hscroll (decode_live_window (window), XFIXNUM (ncol)); 1300 return set_window_hscroll (decode_live_window (window), XFIXNUM (ncol));
1301} 1301}
1302 1302
1303DEFUN ("window-redisplay-end-trigger", Fwindow_redisplay_end_trigger,
1304 Swindow_redisplay_end_trigger, 0, 1, 0,
1305 doc: /* Return WINDOW's redisplay end trigger value.
1306WINDOW must be a live window and defaults to the selected one.
1307See `set-window-redisplay-end-trigger' for more information. */)
1308 (Lisp_Object window)
1309{
1310 return decode_live_window (window)->redisplay_end_trigger;
1311}
1312
1313DEFUN ("set-window-redisplay-end-trigger", Fset_window_redisplay_end_trigger,
1314 Sset_window_redisplay_end_trigger, 2, 2, 0,
1315 doc: /* Set WINDOW's redisplay end trigger value to VALUE.
1316WINDOW must be a live window and defaults to the selected one. VALUE
1317should be a buffer position (typically a marker) or nil. If it is a
1318buffer position, then if redisplay in WINDOW reaches a position beyond
1319VALUE, the functions in `redisplay-end-trigger-functions' are called
1320with two arguments: WINDOW, and the end trigger value. Afterwards the
1321end-trigger value is reset to nil. */)
1322 (register Lisp_Object window, Lisp_Object value)
1323{
1324 wset_redisplay_end_trigger (decode_live_window (window), value);
1325 return value;
1326}
1327
1328/* Test if the character at column X, row Y is within window W. 1303/* Test if the character at column X, row Y is within window W.
1329 If it is not, return ON_NOTHING; 1304 If it is not, return ON_NOTHING;
1330 if it is on the window's vertical divider, return 1305 if it is on the window's vertical divider, return
@@ -8640,8 +8615,6 @@ displayed after a scrolling operation to be somewhat inaccurate. */);
8640 defsubr (&Swindow_body_width); 8615 defsubr (&Swindow_body_width);
8641 defsubr (&Swindow_hscroll); 8616 defsubr (&Swindow_hscroll);
8642 defsubr (&Sset_window_hscroll); 8617 defsubr (&Sset_window_hscroll);
8643 defsubr (&Swindow_redisplay_end_trigger);
8644 defsubr (&Sset_window_redisplay_end_trigger);
8645 defsubr (&Swindow_mode_line_height); 8618 defsubr (&Swindow_mode_line_height);
8646 defsubr (&Swindow_header_line_height); 8619 defsubr (&Swindow_header_line_height);
8647 defsubr (&Swindow_tab_line_height); 8620 defsubr (&Swindow_tab_line_height);
diff --git a/src/window.h b/src/window.h
index c63b1b24d4f..93817a95445 100644
--- a/src/window.h
+++ b/src/window.h
@@ -199,10 +199,6 @@ struct window
199 and Qt, so bitfield can't be used here. */ 199 and Qt, so bitfield can't be used here. */
200 Lisp_Object dedicated; 200 Lisp_Object dedicated;
201 201
202 /* If redisplay in this window goes beyond this buffer position,
203 must run the redisplay-end-trigger-hook. */
204 Lisp_Object redisplay_end_trigger;
205
206 /* t means this window's child windows are not (re-)combined. */ 202 /* t means this window's child windows are not (re-)combined. */
207 Lisp_Object combination_limit; 203 Lisp_Object combination_limit;
208 204
@@ -498,12 +494,6 @@ wset_prev (struct window *w, Lisp_Object val)
498} 494}
499 495
500INLINE void 496INLINE void
501wset_redisplay_end_trigger (struct window *w, Lisp_Object val)
502{
503 w->redisplay_end_trigger = val;
504}
505
506INLINE void
507wset_mode_line_help_echo (struct window *w, Lisp_Object val) 497wset_mode_line_help_echo (struct window *w, Lisp_Object val)
508{ 498{
509 w->mode_line_help_echo = val; 499 w->mode_line_help_echo = val;
diff --git a/src/xdisp.c b/src/xdisp.c
index b1ee7889d46..88a489e290f 100644
--- a/src/xdisp.c
+++ b/src/xdisp.c
@@ -1138,7 +1138,6 @@ static int display_string (const char *, Lisp_Object, Lisp_Object,
1138 ptrdiff_t, ptrdiff_t, struct it *, int, int, int, 1138 ptrdiff_t, ptrdiff_t, struct it *, int, int, int,
1139 int); 1139 int);
1140static void compute_line_metrics (struct it *); 1140static void compute_line_metrics (struct it *);
1141static void run_redisplay_end_trigger_hook (struct it *);
1142static bool get_overlay_strings (struct it *, ptrdiff_t); 1141static bool get_overlay_strings (struct it *, ptrdiff_t);
1143static bool get_overlay_strings_1 (struct it *, ptrdiff_t, bool); 1142static bool get_overlay_strings_1 (struct it *, ptrdiff_t, bool);
1144static void next_overlay_string (struct it *); 1143static void next_overlay_string (struct it *);
@@ -3279,17 +3278,6 @@ init_iterator (struct it *it, struct window *w,
3279 /* Are multibyte characters enabled in current_buffer? */ 3278 /* Are multibyte characters enabled in current_buffer? */
3280 it->multibyte_p = !NILP (BVAR (current_buffer, enable_multibyte_characters)); 3279 it->multibyte_p = !NILP (BVAR (current_buffer, enable_multibyte_characters));
3281 3280
3282 /* Get the position at which the redisplay_end_trigger hook should
3283 be run, if it is to be run at all. */
3284 if (MARKERP (w->redisplay_end_trigger)
3285 && XMARKER (w->redisplay_end_trigger)->buffer != 0)
3286 it->redisplay_end_trigger_charpos
3287 = marker_position (w->redisplay_end_trigger);
3288 else if (FIXNUMP (w->redisplay_end_trigger))
3289 it->redisplay_end_trigger_charpos
3290 = clip_to_bounds (PTRDIFF_MIN, XFIXNUM (w->redisplay_end_trigger),
3291 PTRDIFF_MAX);
3292
3293 it->tab_width = SANE_TAB_WIDTH (current_buffer); 3281 it->tab_width = SANE_TAB_WIDTH (current_buffer);
3294 3282
3295 /* Are lines in the display truncated? */ 3283 /* Are lines in the display truncated? */
@@ -9430,13 +9418,6 @@ next_element_from_buffer (struct it *it)
9430 previously seen overlays is no longer valid. */ 9418 previously seen overlays is no longer valid. */
9431 it->ignore_overlay_strings_at_pos_p = false; 9419 it->ignore_overlay_strings_at_pos_p = false;
9432 9420
9433 /* Maybe run the redisplay end trigger hook. Performance note:
9434 This doesn't seem to cost measurable time. */
9435 if (it->redisplay_end_trigger_charpos
9436 && it->glyph_row
9437 && IT_CHARPOS (*it) >= it->redisplay_end_trigger_charpos)
9438 run_redisplay_end_trigger_hook (it);
9439
9440 if (composition_break_at_point 9421 if (composition_break_at_point
9441 && !NILP (BVAR (current_buffer, enable_multibyte_characters)) 9422 && !NILP (BVAR (current_buffer, enable_multibyte_characters))
9442 && !NILP (Vauto_composition_mode)) 9423 && !NILP (Vauto_composition_mode))
@@ -9504,29 +9485,6 @@ next_element_from_buffer (struct it *it)
9504} 9485}
9505 9486
9506 9487
9507/* Run the redisplay end trigger hook for IT. */
9508
9509static void
9510run_redisplay_end_trigger_hook (struct it *it)
9511{
9512 /* IT->glyph_row should be non-null, i.e. we should be actually
9513 displaying something, or otherwise we should not run the hook. */
9514 eassert (it->glyph_row);
9515
9516 ptrdiff_t charpos = it->redisplay_end_trigger_charpos;
9517 it->redisplay_end_trigger_charpos = 0;
9518
9519 /* Since we are *trying* to run these functions, don't try to run
9520 them again, even if they get an error. */
9521 wset_redisplay_end_trigger (it->w, Qnil);
9522 CALLN (Frun_hook_with_args, Qredisplay_end_trigger_functions, it->window,
9523 make_fixnum (charpos));
9524
9525 /* Notice if it changed the face of the character we are on. */
9526 handle_face_prop (it);
9527}
9528
9529
9530/* Deliver a composition display element. Unlike the other 9488/* Deliver a composition display element. Unlike the other
9531 next_element_from_XXX, this function is not registered in the array 9489 next_element_from_XXX, this function is not registered in the array
9532 get_next_element[]. It is called from next_element_from_buffer and 9490 get_next_element[]. It is called from next_element_from_buffer and
@@ -36129,7 +36087,6 @@ be let-bound around code that needs to disable messages temporarily. */);
36129 DEFSYM (Qoverriding_terminal_local_map, "overriding-terminal-local-map"); 36087 DEFSYM (Qoverriding_terminal_local_map, "overriding-terminal-local-map");
36130 DEFSYM (Qoverriding_local_map, "overriding-local-map"); 36088 DEFSYM (Qoverriding_local_map, "overriding-local-map");
36131 DEFSYM (Qwindow_scroll_functions, "window-scroll-functions"); 36089 DEFSYM (Qwindow_scroll_functions, "window-scroll-functions");
36132 DEFSYM (Qredisplay_end_trigger_functions, "redisplay-end-trigger-functions");
36133 DEFSYM (Qinhibit_point_motion_hooks, "inhibit-point-motion-hooks"); 36090 DEFSYM (Qinhibit_point_motion_hooks, "inhibit-point-motion-hooks");
36134 DEFSYM (Qeval, "eval"); 36091 DEFSYM (Qeval, "eval");
36135 DEFSYM (QCdata, ":data"); 36092 DEFSYM (QCdata, ":data");
@@ -36533,12 +36490,6 @@ is scrolled. It is not designed for that, and such use probably won't
36533work. */); 36490work. */);
36534 Vwindow_scroll_functions = Qnil; 36491 Vwindow_scroll_functions = Qnil;
36535 36492
36536 DEFVAR_LISP ("redisplay-end-trigger-functions", Vredisplay_end_trigger_functions,
36537 doc: /* Functions called when redisplay of a window reaches the end trigger.
36538Each function is called with two arguments, the window and the end trigger value.
36539See `set-window-redisplay-end-trigger'. */);
36540 Vredisplay_end_trigger_functions = Qnil;
36541
36542 DEFVAR_LISP ("mouse-autoselect-window", Vmouse_autoselect_window, 36493 DEFVAR_LISP ("mouse-autoselect-window", Vmouse_autoselect_window,
36543 doc: /* Non-nil means autoselect window with mouse pointer. 36494 doc: /* Non-nil means autoselect window with mouse pointer.
36544If nil, do not autoselect windows. 36495If nil, do not autoselect windows.