Menu

#652 Synctex inverse search not working

closed-fixed
nobody
Interface (198)
5
2010-05-01
2010-03-28
Remi Megret
No

I just installed Skim v1.3.5 under Snow Leopard, tex inverse search does not seems to work:
RESULT:
=> Shift+Cmd+click has no effect, even after setting up a custom command

EXPECTED RESULT:
=> Shift+Cmd+click calls the provided inverse search command that brings an editor

STEPS TO REPRODUCE:
- Install Skim.app in Applications

- Compile file toto.tex as pdf with synctex or pdfsync (tried both)
using
"/usr/texbin/pdflatex" --synctex=-1 -interaction=nonstopmode %.tex
I get:
MacBook-de-Remi:Test remi$ ls -l
-rw-r--r-- 1 remi staff 8 28 mar 14:32 toto.aux
-rw-r--r-- 1 remi staff 3393 28 mar 14:32 toto.log
-rw-r--r-- 1 remi staff 12453 28 mar 14:32 toto.pdf
-rw-r--r-- 1 remi staff 329 28 mar 14:32 toto.pdfsync
-rw-r--r-- 1 remi staff 1756 28 mar 14:32 toto.synctex
-rw-r--r--@ 1 remi staff 119 28 mar 14:32 toto.tex

- Open the generated PDF in Skim
- Check the inverse search command in Preferences:
Tried the default "TexMaker", as well as custom ones:
Command : open
Arguments : -a texmaker --args "%file" -line %line
(The command
open -a texmaker --args /Users/remi/Documents/Test/toto.tex -line 12
works well in a terminal, texmaker.app is installed in /Applications)

- Do Shift+Cmd+Click in the PDF document within Skim
- Nothing happens

From this, I do not know if the problem comes from
- Shift+Cmd+Click is not recognized as an event
- Synctex or pdfsync file is not in a correct format
- The command is not correct

BTW, the Sync pane in Preferences does not grey out the command text line when using default setup (as it does in v1.2.7).

Discussion

  • Remi Megret

    Remi Megret - 2010-03-28

    Test Latex File

     
  • Christiaan Hofman

    The support works perfectly for me. Perhaps the problem is that you have an (outdated) pdfsync and/or synctex file, you should use either one or the other, not both, otherwise you may get confusion by either Skim or the editor.

     
  • Christiaan Hofman

    • status: open --> closed-works-for-me
     
  • Christiaan Hofman

    I see now that the action for the popup is not connected, so the change is not noted. Thanks for the resport, this will be fixed for the next release.

     
  • Christiaan Hofman

    • status: closed-works-for-me --> open-fixed
     
  • Anonymous

    Anonymous - 2010-03-30

    Same problem -- just downloaded 1.3.5 (53) and tex inverse search seems quite broken.
    Not only does the "preset" picker do nothing, but the "Command" and "Arguments" lines do not each transfer focus to the other when you press tab, as one would expect.
    Furthermore, after entering "Command: touch" and "Arguments: /Users/cook/sync_worked_%line_%file", then I tried shift-command-clicking in several places, but no files were created (also the full path /usr/bin/touch didn't work).
    So it looks 100% non-functional to me.
    (My pdf file syncs fine in TeXShop's viewer anyway, so it's not a syncing problem.)
    Maybe the actions for the text fields also aren't connected, so nothing I enter is actually getting into the system?

    Regardless of the nature of this bug, I would also strongly recommend putting the list of default commands/arguments somewhere on the wiki, as currently, after much searching, it seems that this info (which could certainly be useful to others) exists nowhere on the web. Also, if it's easy for people to add (in the wiki) the right command for their favorite editor, then this info is immediately usable by other Skim users, and it can eventually make its way into future Skim releases, improving Skim.

     

    Last edit: Anonymous 2014-03-27
  • Anonymous

    Anonymous - 2010-03-30

    Just downloaded sources and compiled, after hooking up the nextKeyView of each TextField to be the other.
    All the issues seem to be fixed. I set it to Aquamacs Emacs and syncing just worked. Thanks for having already fixed this!

     

    Last edit: Anonymous 2014-12-06
  • Remi Megret

    Remi Megret - 2010-03-31

    Also downloaded from svn and compiled. Cmd+Shift+Click is now connected again.
    I could use it directly with the preset command for texmaker.

    The other preset mentionned by cook, can be found in SKSyncPreferences.m:44
    static SKTeXEditor SKTeXEditors[] = {{@"TextMate", @"mate", @"-l %line \"%file\""},
    {@"BBEdit", @"bbedit", @"+%line \"%file\""},
    {@"TextWrangler", @"edit", @"+%line \"%file\""},
    {@"Emacs", @"emacsclient", @"--no-wait +%line \"%file\""},
    {@"Aquamacs Emacs", @"emacsclient", @"--no-wait +%line \"%file\""},
    {@"Aquamacs", @"emacsclient", @"--no-wait +%line \"%file\""},
    {@"LyX", @"lyxeditor", @"\"%file\" %line"},
    {@"TeXMaker", @"texmaker", @"\"%file\" -line %line"},
    {@"AlphaX", @"alphac", @"+%line \"%file\""}};

    These commands did not work directly as custom commands.
    For instance, using custom command: texmaker, with arguments: "%file" -line %line does nothing for me.

    The reason is in fact explained at https://sourceforge.net/apps/mediawiki/skim-app/index.php?title=TeX_and_PDF_Synchronization.
    Different algorithms are run for preset and custom commands (in SKMainDocument.m:1543): for the preset, Skim tries to fetch the executable from the bundle, which is not the case for custom commands.

    So what worked for me was :
    - either use preset
    - or use custom command with the full path to executable, within the bundle:
    Command: /Applications/texmaker.app/Contents/MacOS/texmaker
    Arguments: "%file" -line %line

    I put these detailed explanations here, if it can be helpful for other people like me who are not very familiar about the bundle/executable thing and that would misunderstand the explanation of the wiki. Just copying the preset seemed reasonable at first, which is not the case obviously.

    Perhaps the display or the wiki could emphasize that the preset command is a bundle name and that it should not be confused with the executable name that is expected for a custom command (for example by showing something like: Command: texmaker (App Bundle) when the texmaker preset is used)

    Thanks for this great piece of software. Once configured, it works like a charm.

     
  • Christiaan Hofman

    • status: open-fixed --> closed-fixed
     

Log in to post a comment.