I'm using LyX 2.0.7, and I tried to enable 'Synchronization with output' by following the guide on LyX wiki.

I couldn't succeed after doing each step exactly as the wiki stated. After lots of experiments to get it work, I followed the steps for 'Enable SyncTeX in LyX' for LyX 1.6, which can be applied to LyX 2.0 with some modification, and it make SyncTex work!

As it explained the wiki page, the steps for enabling SyncTex is different in version 1.6.* and 2.0, the following quotes are from the wiki page.

Lyx 2.0 >

  1. In Document > Settings > Output, check Synchronize with output
  2. If your viewer needs another output format than \synctex=-1 (which is the default), select > it or insert it in "Custom Macro"
  3. Modify Output > General > PDF for your PDF viewer (see the viewer-specific notes below)

Lyx 1.6

  1. Enter Tools > Preferences > File Handling > Export programs
  2. Click "LaTeX (pdflatex) > PDF (pdflatex)" in the list. In the "Export program" box, it now says pdflatex $$i. Instead, put pdflatex -synctex=-1 $$i there.
  3. Click Modify to the right of the list, then Apply.

The question is: Since LyX 2.0 has specific settings for enabling SyncTex, why it is not enough to enable it there as the wiki page suggest? and why it is still required to change the latex command line argument?

Can anyone confirm this problem? Is it a bug or is it how it suppose to function? If it's a bug how can we report it?

  • Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. Apr 1, 2014 at 11:43
  • What is your OS? I've heard of issues mainly with Windows. Which PDF reader are you trying to sync with? And what is your TeX installation (TeX Live 201X?) ?
    – scottkosty
    Apr 1, 2014 at 19:13
  • @scottkosty I'm using MikTex(latest) on Windows, and I use SumatraPDF. Sumatra works fine, the problem is that LyX does not pass -synctex=-1 to pdflatex command automatically when it is enabled in the preferences.
    – Meti
    Apr 1, 2014 at 21:30
  • @Medi OK, I found a report and solution of the same problem (Windows + MikTeX + Summatra). See the answer.
    – scottkosty
    Apr 1, 2014 at 23:13

1 Answer 1


This is a MikTeX issue, as confirmed by Enrico Forestieri:

For some reason, miktex does not understand/obey the command lyx inserts into the preamble when you check the "Enable Forward/Reverse Search" button in the toolbar and does not generate the necessary info.

The generation of the required info can be forced by changing the converter "LaTeX (pdflatex) -> PDF (pdflatex)" in Preferences->File handling->Converters from the default "pdflatex $$i" to "pdflatex -synctex=1 $$i" (i.e., by adding the -synctex=1 switch). After that it should work (supposing that you performed the necessary configuration as explained in the above link).

  • Thank you for your answer, but in my question, I already stated that the problem can be solved by adding ` -synctex=1` argument to pdflatex command as the wiki suggest for LyX 1.6. As your solution suggest, it is a bug with MikTex. Has this bug been confirmed or reported? If not how can someone report it? (+1 for answer confirming the issue)
    – Meti
    Apr 2, 2014 at 4:06
  • @Medi I will edit the answer. I do not know of any MikTeX bug report. If you report it, please update us here with a link.
    – scottkosty
    Apr 3, 2014 at 0:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .