0

I am syncing AUCTeX with Sumatra PDF on MSWindows. I used the instructions in Sync Emacs AUCTeX with Sumatra PDF (modulo the fact that I use customization instead of writing the setq in the init file, and the fact that the path to sumatra is different on my machine: see https://www.barik.net/archive/2012/07/18/154432/ for the customization)

(setq TeX-source-correlate-mode t)
(setq TeX-source-correlate-method 'synctex) 
(setq TeX-view-program-list 
  '(("Sumatra PDF" ("\"C:/bin86/SumatraPDF/SumatraPDF.exe\" -reuse-instance" 
                      (mode-io-correlate " -forward-search %b %n ") " %o"))))
 (setq TeX-view-program-selection  
      '(((output-dvi style-pstricks) "dvips and start") (output-dvi "Yap") 
       (output-pdf "Sumatra PDF") (output-html "start")))

However, when there is a space in the file name (e.g. "example 1.tex"), the syncing has problems: when from Emacs I do CRTL-c CRTL-v, it opens both the the file "example 1.pdf" and a dummy "123" file, where 123 is the line number in the source file.

Any suggestions on how to solve this problem?

  • Welcome to StackOverflow! This site is on general programming problems. Maybe you will be more likely to find help on more specialized sites like tex.stackexchange.com or emacs.stackexchange.com. – Alain Merigot Jan 31 '19 at 17:48
  • Here is a link to an answer that contains my AucTeX settings for Sumatra: http://tex.stackexchange.com/a/156617/26911 It has been several years since I played with AucTeX and some components of that package relating to these settings may have changed over the years. – lawlist Feb 03 '19 at 06:27

0 Answers0