Trigger nav-flash on synctex or vim jump

I want nav-flash to trigger when the cursor position changes because of a synctex backward search (CTRL+left click in pdf viewer). Is there some way to do that?

I would also like to have nav-flash trigger when I do big jumps in evil mode like G or gg. Is that possible?

The part about synctex backward search can be done by redefining TeX-raise-frame-function. Note that you may also need to overwrite raise-frame based on your DE/WM setup. (check the TeX-raise-frame-function docs for that)

(defun raise-and-flash ()
    (nav-flash-show)
    (raise-frame))
(setq TeX-raise-frame-function #'raise-and-flash)

The part about evil remains unfixed. I’m pretty sure there is currently no easy way to achieve it. One would either need to add post jump hooks to evil and then bind to them, or one would need to record the cursor position all the time and trigger a nav-flash when the cursor changes largely.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.