diff options
author | Camil Staps | 2023-01-15 20:48:59 +0100 |
---|---|---|
committer | Camil Staps | 2023-01-15 20:48:59 +0100 |
commit | 04cbdb51a0e02619e0ca8bc717f1a599560befa5 (patch) | |
tree | ffd425a9fd168b5ad9c8a1a7c4a9eb225a6b0642 /vim/.latexmkrc | |
parent | Add JetBrains Mono font (diff) |
Improve synctex; when clicking in the PDF focus the vim window
Diffstat (limited to 'vim/.latexmkrc')
-rw-r--r-- | vim/.latexmkrc | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/vim/.latexmkrc b/vim/.latexmkrc index 8ee0b76..c4ec9ee 100644 --- a/vim/.latexmkrc +++ b/vim/.latexmkrc @@ -13,10 +13,7 @@ $pdf_previewer .= 'zathura'; # -x for synctex: connect to the rpc socket, switch to the file and jump to the line $pdf_previewer .= ' -x "nvim --headless --cmd'; $pdf_previewer .= ' \'let skt=sockconnect(\\"pipe\\",\\"$SERVER\\",{\\"rpc\\":1})'; -$pdf_previewer .= ' | call rpcrequest(skt,\\"nvim_command\\",\\"tab drop %{input}\\")'; -$pdf_previewer .= ' | call rpcrequest(skt,\\"nvim_command\\",\\"%{line}\\")'; -# mysteriously, we need `cd .` to fix the file name in the tabline -$pdf_previewer .= ' | call rpcrequest(skt,\\"nvim_command\\",\\"cd .\\")'; +$pdf_previewer .= ' | call rpcrequest(skt,\\"nvim_command\\",\\"call SyncPDFToTeX(\\\\\\"%{input}\\\\\\",\\\\\\"%{line}\\\\\\")\\")'; $pdf_previewer .= ' | call chanclose(skt)'; $pdf_previewer .= ' | quit\'"'; # final argument for zathura is the PDF |