Subject: bug#56815: 29.0.50; Isearch lazy-highlight highlights too much when truncate-lines is in effect

From: Juri Linkov <[email-masked]>
Date: Fri, 29 Jul 2022 21:14:47 +0300

> This reminds me of something I wondered about when futzing about with
> inhibiting lazy-highlights w.r.t. text covered by a `display' property
> (which was fixed a different way):
>
> Would it be possibly to make the isearch lazy-highlight just skip the
> portions of the buffer that aren't visible?

Indeed what is worth trying is to add pos-visible-in-window-group-p
either to isearch-filter-predicate, or directly to isearch-lazy-highlight-search.
Isearch.el already has some uses of pos-visible-in-window-group-p,
but currently only in isearch-update.