vimtex icon indicating copy to clipboard operation
vimtex copied to clipboard

Zathura synctex inverse search not working

Open amanjitsk opened this issue 4 months ago • 11 comments

Description

Basically, I don't have inverse search working in Zathura (version 0.5.2 with mupdf backend).

I am honestly quite stumped, and I swear this feature used to work, and broke down somewhere along the many updates etc. I also have coc-vimtex installed but don't think it has anything to do with this.

Here is the relevant config in my vimrc:

let g:tex_flavor = "latex"
let g:vimtex_view_method = 'zathura'
let g:vimtex_view_forward_search_on_start = 0
let g:vimtex_compiler_method = 'latexmk'
let g:vimtex_quickfix_open_on_warning = 0

let g:vimtex_imaps_enabled = 1
let g:vimtex_imaps_leader = ';'
let g:vimtex_compiler_latexmk = {                
    \ 'backend' : 'nvim',
    \ 'background' : 1,                          
    \ 'build_dir' : '',                          
    \ 'callback' : 1,                            
    \ 'continuous' : 1,                          
    \ 'executable' : 'latexmk',                  
    \ 'hooks' : [],                              
    \ 'options' : [                              
    \   '-verbose',                              
    \   '-emulate-aux-dir',
    \   '-f',
    \   '-file-line-error',                      
    \   '-synctex=1',                            
    \   '-interaction=nonstopmode',              
    \ ],                                         
    \}

My latexmkrc contains the following:

$pdf_mode = 1;
$clean_ext = 'bbl synctex.gz';

I also tried looking through similar issues, but didn't find anything that worked. Am I missing a setting or a very silly thing somewhere in my config? I suppose I am under the impression that synctex should just work out of the box. I have also checked that Zathura is installed (and linked) to libsynctex which is responsible for synctex integration, and of course, forward search works without any issues.

I haven't uploaded the minimal vimrc yet, but I will gladly do if nothing seems immediately off with my current setup.

Steps to reproduce

No response

Expected behavior

No response

Actual behavior

No response

Do you use a latexmkrc file?

Yes

VimtexInfo

System info:
  OS: Ubuntu 22.04.2 LTS
  LaTeX version: pdfTeX 3.141592653-2.6-1.40.22 (TeX Live 2022/dev/Debian)
  Vim version: NVIM v0.11.0
  Has clientserver: true
  Servername: /run/user/1000/nvim.150458.0
  $PATH:
    - /bin
    - /home/amanjitsk/.local/bin
    - /home/amanjitsk/.local/bin/i3ipc
    - /home/amanjitsk/.local/bin/i3ipc/i3-focus
    - /home/amanjitsk/.local/bin/i3ipc/i3-focus/tools
    - /home/amanjitsk/.local/bin/rofi-menus
    - /home/amanjitsk/.local/bin/utils
    - /home/amanjitsk/.local/bin/xutils
    - /home/amanjitsk/.local/cargo/bin
    - /home/amanjitsk/.local/go/bin
    - /home/amanjitsk/.local/pyenv/bin
    - /sbin
    - /snap/bin
    - /usr/bin
    - /usr/games
    - /usr/local/bin
    - /usr/local/games
    - /usr/local/sbin
    - /usr/sbin

VimTeX project: bw
  base: bw.tex
  root: /home/amanjitsk/Projects/applications
  tex: /home/amanjitsk/Projects/applications/bw.tex
  main parser: current file verified
  document class: article
  packages: afterpage algorithm2e algorithmic amsbsy amscd amsfonts amsgen amsmath amsopn amssymb amstext amsthm appendix array arxiv atbegshi atbegshi-ltx atveryend atveryend-ltx auxhook babel bbm bigintcalc bitset bm bookmark booktabs calc cancel caption caption3 cleveref color datatool-base datatool-fp defpattern derivative dsfont empheq enumitem environ epsfig epstopdf epstopdf-base esdiff etexcmds etoolbox expl3 fancyvrb floatrow fontenc fp fp-addons fp-basic fp-eqn fp-eval fp-exp fp-pas fp-random fp-snap fp-trigo fp-upn fr-longtable framed geometry gettitlestring glossaries glossaries-compatible-307 glossary-hypernav glossary-list glossary-long glossary-super glossary-tree graphics graphicx grfext hycolor hyperref hyphenat ifoddpage iftex ifthen ifvtex infwarerr inputenc intcalc keyval kvdefinekeys kvoptions kvsetkeys l3keys2e letltxmacro lineno listings longtable lstmisc ltcaption ltxcmds makecell mathbbol mathrsfs mathtools mdframed mfirstuc mhsetup microtype minted nameref natbib needspace nicefrac parskip pdfescape pdftexcmds pgf pgfcalendar pgfcomp-version-0-65 pgfcomp-version-1-18 pgfcore pgffor pgfkeys pgfmath pgfplots pgfrcs pgfsys psfrag pythontex ragged2e refcount relsize rerunfilecheck rotating scalefnt scalerel siunitx subcaption substr supertabular tensor textcase tikz tikz-dependency tracklang translations translator trig trimspaces ulem uniquecounter url wrapfig xcolor xfor xkeyval xparse xspace zref-abspage zref-base
  source files:
    bw.tex
    preamble.tex
  compiler: latexmk
    engine: -pdf
    options:
      -verbose
      -emulate-aux-dir
      -f
      -file-line-error
      -synctex=1
      -interaction=nonstopmode
    callback: 1
    continuous: 1
    executable: latexmk
    job: 
      jobid: 55
      output: /tmp/nvim.amanjitsk/5tYUaV/6
      cmd: max_print_line=2000 latexmk -verbose -emulate-aux-dir -f -file-line-error -synctex=1 -interaction=nonstopmode  -pdf -pvc -pvctimeout- -view=none -e '$compiling_cmd = ($compiling_cmd ? $compiling_cmd . " ; " : "") . "echo vimtex_compiler_callback_compiling"' -e '$success_cmd = ($success_cmd ? $success_cmd . " ; " : "") . "echo vimtex_compiler_callback_success"' -e '$failure_cmd = ($failure_cmd ? $failure_cmd . " ; " : "") . "echo vimtex_compiler_callback_failure"' 'bw.tex'
      pid: 154737
  viewer: Zathura
    xwin id: 65011715
    cmd_forward_search: zathura --synctex-forward 1058:8:'/home/amanjitsk/Projects/IEEE/applications/bw.tex' 'bw.pdf'&
    cmd_start: zathura  -x "/tmp/.mount_nvimEfNFjD/usr/bin/nvim --headless -c \"VimtexInverseSearch %{line}:%{column} '%{input}'\"" 'bw.pdf'&
  qf method: LaTeX logfile

amanjitsk avatar May 28 '25 21:05 amanjitsk