Subject: bug#14582: 24.3.50.1; Strange overlay behavior, when window-start is inside an overlay.

From: Eli Zaretskii <[email-masked]>
Date: Thu, 03 Feb 2022 19:40:49 +0200

> Date: Wed, 02 Feb 2022 14:31:35 +0200
> From: Eli Zaretskii <[email-masked]>
> Cc: [email-masked], [email-masked], [email-masked]
> 
> > From: Michael Heerdegen <[email-masked]>
> > Cc: [email-masked],  [email-masked],  [email-masked]
> > Date: Wed, 02 Feb 2022 05:02:41 +0100
> > 
> > Is there a third alternative, a hook or something that could be used, to
> > perform this task automatically?
> 
> It cannot be a hook, because from the display engine POV nothing
> happened that could trigger a hook.  The visible contents of the
> window is different, that's all.
> 
> So it shouldn't be a hook, it should be a buffer-local variable that
> would change how redisplay behaves in these cases.  I will see what
> can be done about it.

I installed a change along these lines.  A buffer that sets the new
variable make-window-start-visible non-nil should force redisplay to
reject a window-start point that is in invisible text or is covered by
a "replacing" 'display' property (which also makes window-start
invisible), and choose a different starting point.

Please test.