2

When I follow subham soni's instructions to connect emacs with Okular, I get the error message "Symbol's function definition is void: nil" when emacs tries to call the viewer "Command: (default View)" Any idea why this happens ?

My complete .emacs file is the following:

(custom-set-variables
 ;; custom-set-variables was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.  
 '(TeX-source-correlate-method (quote synctex))
 '(TeX-source-correlate-mode t)
 '(TeX-source-correlate-start-server t)
 '(TeX-view-program-list (quote (("Okular" ("okular %o") "okular --unique %o#src:%n%b"))))
 '(TeX-view-program-selection (quote (((output-dvi has-no-display-manager) "dvi2tty") ((output-dvi style-pstricks) "dvips and gv") (output-pdf "Okular") (output-dvi "xdvi") (output-pdf "Evince") (output-html "xdg-open"))))
 '(delete-selection-mode nil)
 '(mark-even-if-inactive t)
 '(scroll-bar-mode (quote right))
 '(transient-mark-mode 1))
(custom-set-faces
 ;; custom-set-faces was added by Custom.
 ;; If you edit it by hand, you could mess it up, so be careful.
 ;; Your init file should contain only one such instance.
 ;; If there is more than one, they won't work right.
 )
4

Remove the line

'(TeX-view-program-list (quote (("Okular" ("okular %o") "okular --unique %o#src:%n%b"))))

It has a wrong format and anyway is useless if you use a recent AUCTeX version (11.88 or above), Okular is correctly configured out-of-the-box.

  • Thank you, now it works. Though I don't understand why it was wrong. I followed the guide from the link.. – Graph4Me Feb 3 '16 at 11:00
  • If it answers your question please mark it as accepted. You added the line okular --unique %o#src:%n%b to the One executable field, not the Command one as indicated by subham soni. Anyway, there is no need to change Okular setting nowadays. – giordano Feb 3 '16 at 11:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.