Subject: RE: bug#43702: Emacs master: Incorrect highlighting in regexp isearch.

From: Drew Adams <[email-masked]>
Date: Thu, 1 Oct 2020 12:39:50 -0700 (PDT)

> >> Maybe better to do what Drew proposed: to distinguish the odd groups
> >> from the even groups, i.e. to have only 2 additional faces
> >> (a brighter face like the current isearch-group-1 for the odd groups,
> >> and a darker face for the even groups).
> >
> > I like the idea.
> 
> Implemented now on the trunk where isearch-group-odd is created
> from the isearch-group-1 face, and isearch-group-even
> from the isearch-group-4 face.
> 
> The result is quite nice:

Sorry, but IMO that's horrible.  And you really should
show more regexps, not just a sequence of groups, but
nested groups etc.

Regexp matching is complex.  And that's the point:
WYSIWYG visualization of a user's regexp on the fly.

My suggestion: provide a fair number of group faces,
to make it easy to identify which parts of a regexp
correspond to which parts of the current search hit.

This should be simple.  I've done it.  And used it,
for a long time.  Why reinvent the wheel, replacing
a circle with an octagon?