Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Highlight hook



I've pushed a branch (mikachu/redrawhook) that adds a hook called
zle-line-pre-redraw (maybe not the best name). This is called whenever
the line is edited or the cursor moves (hopefully). As you may spot
from the first commit date, I've used this for a while. There were
some problems with calling it from inside zrefresh() (not to mention
how inefficient that is with how often zrefresh() gets called), but so
far none of those have showed up with where I call it now.

If there are no major problems with this, it might be nice for the
highlighters to not have to wrap every single widget in zsh to call
the highlighting when the line changes, since that also has other side
effects.

-- 
Mikael Magnusson



Messages sorted by: Reverse Date, Date, Thread, Author