Subject: Re: How can Zle -U interfere with zsh-syntax-highlighting?
From: Mikael Magnusson <[email-masked]>
To: Sebastian Gniazdowski <[email-masked]>
Cc: Zsh hackers list <[email-masked]>
Date: Sun, 15 May 2016 17:37:28 +0200
List-Id: Zsh Workers List <zsh-workers.zsh.org>

On Sun, May 15, 2016 at 5:24 PM, Sebastian Gniazdowski
<[email-masked]> wrote:
> PS. Also, just noting that print -zr doesn't do highlighting

When the stack pops, the code that calls the pre-redraw hook isn't
reached. I tried putting it there but it caused crashes. I asked if
anyone was interested in looking into that when I posted the patches
but IIRC there were no responses to that. Those mails probably have
some info about what areas of the code to look at though. If you do
zle -M "$BUFFER" in your zle-line-init hook, you will see that it
already contains the text, so doing highlight from there _should_
work, but doesn't. I guess the hook is called before the code that
unsets all the region_highlight arrays.

-- 
Mikael Magnusson