Latex-workshop: [question] Synctex and Okular (Evince)

Created on 22 Apr 2017  路  4Comments  路  Source: James-Yu/LaTeX-Workshop

I am just experimenting with VScode and with LaTeX Workshop.

  1. I use Okular (similar to Evince) as PDF viewer. For inverse search to work an editor specific command is required. For example kile --line %l works with kile. Simply replacing kile with /usr/share/code/code does not work (of course): the correct source is opened in VScode but the prompt is not at the right line. What should I write?

  2. If forward seach (for source to PDF) implemented in LaTeX Workshop?

Thank you.

Most helpful comment

Thank you. Your hint brought me back to vscode.

It did not work right away (it finds the right file but
goes to the eof). The following works

 code --goto %f:%l

All 4 comments

There is no current plan to support external PDF viewer. So you may need to research a little bit on vscode to achieve your objectives, if possible.

I know, this issue is closed, but for the one wondering:

code --goto %f:%l%c

will achieve inverse search for vscode and okular.

Thank you. Your hint brought me back to vscode.

It did not work right away (it finds the right file but
goes to the eof). The following works

 code --goto %f:%l

thanks a lot guys!

versions:

  • Okular 1.8.1
  • LaTeX Workshop 8.2.0
  • vscode
Version: 1.36.1
Commit: 2213894ea0415ee8c85c5eea0d0ff81ecc191529
Date: 2019-07-08T22:55:08.091Z
Electron: 4.2.5
Chrome: 69.0.3497.128
Node.js: 10.11.0
V8: 6.9.427.31-electron.0
OS: Linux x64 5.2.11-1-MANJARO

search:

  • inverse works for me with (Okular -> Settings -> Configure Okular -> Editor -> Custom Text Editor)
code --goto %f:%l
  • forward is currently experimental, but works for me with (reference)
"latex-workshop.view.pdf.external.viewer.command": "okular",
"latex-workshop.view.pdf.external.viewer.args": [
   "--unique",
   "%PDF%"
],
"latex-workshop.view.pdf.viewer": "external",
"latex-workshop.view.pdf.external.synctex.command": "okular",
"latex-workshop.view.pdf.external.synctex.args": [
   "--unique",
   "%PDF%#src:%LINE%%TEX%"
]
Was this page helpful?
0 / 5 - 0 ratings

Related issues

drdebmath picture drdebmath  路  4Comments

s-ilic picture s-ilic  路  3Comments

BjoernDaase picture BjoernDaase  路  3Comments

tenhobi picture tenhobi  路  4Comments

jose-a-sa picture jose-a-sa  路  4Comments