From: Eli Zaretskii Date: Thu, 9 Nov 2017 16:22:42 +0000 (+0200) Subject: Fix redisplay of overlay-arrows on GUI frames X-Git-Tag: emacs-26.0.91~346 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9dde8be9cd;p=emacs.git Fix redisplay of overlay-arrows on GUI frames * src/xdisp.c (try_window_reusing_current_matrix) (try_cursor_movement): Disallow these optimizations if the buffer has overlay arrow(s) shown on the fringe(s). (Bug#29198) --- diff --git a/src/xdisp.c b/src/xdisp.c index 69b74dc6298..5fdd39b0c94 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -16066,8 +16066,10 @@ try_cursor_movement (Lisp_Object window, struct text_pos startp, since the handling of this_line_start_pos, etc., in redisplay handles the same cases. */ && !EQ (window, minibuf_window) - && (FRAME_WINDOW_P (f) - || !overlay_arrow_in_current_buffer_p ())) + /* When overlay arrow is shown in current buffer, point movement + is no longer "simple", as it typically causes the overlay + arrow to move as well. */ + && !overlay_arrow_in_current_buffer_p ()) { int this_scroll_margin, top_scroll_margin; struct glyph_row *row = NULL; @@ -17698,7 +17700,11 @@ try_window_reusing_current_matrix (struct window *w) /* Don't try to reuse the display if windows have been split or such. */ || windows_or_buffers_changed - || f->cursor_type_changed) + || f->cursor_type_changed + /* This function cannot handle buffers where the overlay arrow + is shown on the fringes, because if the arrow position + changes, we cannot just reuse the current matrix. */ + || overlay_arrow_in_current_buffer_p ()) return false; /* Can't do this if showing trailing whitespace. */