Le 2025-02-11 17:43, Arash Esbati a écrit :
Bonjour François,
François Patte <[email protected]> writes:
When I use C-c-a to compile my document, latexmk is run but at the
end, it complains that "no matching viewer found"....
Thank you for answering. I had to clean a (very) old .emacs file
first...
Does it work for you if you do
• C-c C-c LaTeX RET
• C-c C-v
I use latexmk, so if I do C-c C-c emacs suggest latexmk RET
If I do C-v or C-C emacs suggests View and open Evince *only* the at the
first time (ie. if I run these successive C-c C-c latexmk RET, C-c C-c
View RET immediately after opening a latex file) if, for instance, I
close evince and make a new compilation (C-c C-c latexmk) emacs claims
that it does not find a viewer to display the result of the last
compilation if I do C-c C-c again or C-c C-v.
In theory, it should be sufficient to have this in your init file:
(setq TeX-view-program-selection '((output-pdf "Evince")))
OK, I put this in my .emacs
AUCTeX has an entry for Evince in `TeX-view-program-list-builtin' which
should get you going, in theory.
Sometimes it works sometimes not... Why?
Good question. Do you have any stale AUCTeX installation on your HD?
Do you see something suspicious when you open a .tex file and do:
M-x list-load-path-shadows RET
I had a lot of "path-shadows" due to an install of bbdb module and
curiously the installed paths from the linux distro install hide the
paths from installed elpa install...
I suppressed the bbdb module from elpa and hve no more path-shadows..
? You could try starting Emacs as 'emacs -Q', then eval this in
scratch
(progn
(package-initialize t)
(package-activate 'auctex)
(setq TeX-view-program-selection '((output-pdf "Evince"))))
open your .tex file and run 'C-c C-v' again. My final idea is if your
Emacs supports DBUS. All stab in the dark, I'm not on a Linux machine
and don't use Evince.
I did not succeed doing this...
I am wondering why I have a cheap emacs install...
;-) I hope we can change this impression.
For instance: why other people have a lot of TeX-view-* if they enter
M-x TeX-view- and I have only two: TeX-view (C-c C-v) and
TeX-view-mouse?
Regards.
--
François Patte
UFR de mathématiques et informatique
Laboratoire CNRS MAP5, UMR 8145
Université Paris Descartes
45, rue des Saints Pères
F-75270 Paris Cedex 06
Tél. +33 (0)6 7892 5822
http://www.math-info.univ-paris5.fr/~patte