I\'m working with GNU Emacs 23.3 (9.0) on Mac OS X 10.7.2. I would like to use synctex to jump between .tex and .pdf files. Although there are many different approaches on t
When you press C-c C-v
(which runs TeX-view
) it should open Skim with the bar on the current line. This is what you set up with the TeX-output-view-style
. You can't get that behaviour from latexmk -pvc
since it doesn't know which line you are on. All latexmk knows is that the file changed. In order to do a forward search you need to run TeX-view
.
You can bind CMD + shift + click to run TeX-view
by adding
(define-key LaTeX-mode-map [M-S-mouse-1] 'TeX-view)
or possibly
(define-key LaTeX-mode-map [s-S-mouse-1] 'TeX-view)
to your TeX-mode-hook
. It depends on your settings which you need, but can find out by pressing C-h C-k
and then CMD+shift+click. Of course adding both shouldn't cause a problem.
To enable the clicking feature of the sync, I added:
(add-hook 'LaTeX-mode-hook
(lambda () (local-set-key (kbd "<S-s-mouse-1>") #'TeX-view))
)
to my .emacs
file.
NOTE: make sure that you are in PDF
mode (use (setq TeX-PDF-mode t)
).