diff --git a/autoload/vimtex/view/zathura.vim b/autoload/vimtex/view/zathura.vim index 393a543170..e0ede248b4 100644 --- a/autoload/vimtex/view/zathura.vim +++ b/autoload/vimtex/view/zathura.vim @@ -110,7 +110,8 @@ endfunction " }}}1 -let s:inverse_search_cmd = get(v:, 'progpath', get(v:, 'progname', '')) +let s:inverse_search_cmd = get(g:, 'vimtex_callback_progpath', + \ get(v:, 'progpath', get(v:, 'progname', ''))) \ . (has('nvim') \ ? ' --headless' \ : ' -T dumb --not-a-term -n') diff --git a/doc/vimtex.txt b/doc/vimtex.txt index 109bdc57d6..774e0bbc90 100644 --- a/doc/vimtex.txt +++ b/doc/vimtex.txt @@ -2927,6 +2927,15 @@ OPTIONS *vimtex-options* Default value: 1 +*g:vimtex_callback_progpath* + The path to the vim binary that will be passed to viewers (for example + Zathura) for synctex callbacks. If unset, vimtex will fallback to use + |v:progpath|. You usually don't have to touch this variable, but if your + vim loads vimtex using a wrapper then it needs to be set otherwise + inverse search calls from viewers won't work. + + Default value: unset + *$VIMTEX_OUTPUT_DIRECTORY* This environment variable allows to specify the output directory of auxiliary LaTeX files. If it exists and is a valid path, this path will be