From 5d528dee12f824b717d3fb2f14c530eb2c38dfe4 Mon Sep 17 00:00:00 2001 From: blendoit Date: Tue, 3 Sep 2019 20:58:00 -0700 Subject: tweaks --- init_latex.el | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 init_latex.el (limited to 'init_latex.el') diff --git a/init_latex.el b/init_latex.el new file mode 100644 index 0000000..7500166 --- /dev/null +++ b/init_latex.el @@ -0,0 +1,17 @@ +;; Function obtained from https://wiki.archlinux.org/index.php/Emacs#SyncTeX_support + +(defcustom tex-my-viewer "zathura --fork -s -x \"emacsclient --eval '(progn (switch-to-buffer (file-name-nondirectory \"'\"'\"%{input}\"'\"'\")) (goto-line %{line}))'\"" + "PDF Viewer for TeX documents. You may want to fork the viewer +so that it detects when the same document is launched twice, and +persists when Emacs gets closed. + +Simple command: + + zathura --fork + +We can use + + emacsclient --eval '(progn (switch-to-buffer (file-name-nondirectory \"%{input}\")) (goto-line %{line}))' + +to reverse-search a pdf using SyncTeX. Note that the quotes and double-quotes matter and must be escaped appropriately." +:safe 'stringp) -- cgit v1.2.3