Bug 19236 - PDF viewer should be an installed program
Summary: PDF viewer should be an installed program
Status: CLOSED WONTFIX
Alias: None
Product: Branch 4.0
Classification: Distributions
Component: emacs-mode-auctex (show other bugs)
Version: 4.0
Hardware: all Linux
: P2 normal
Assignee: Nobody's working on this, feel free to take it
QA Contact: Q.A. 4.0
URL:
Keywords:
Depends on: 19558
Blocks:
  Show dependency tree
 
Reported: 2009-03-18 23:30 MSK by Ivan Zakharyaschev
Modified: 2014-11-05 20:17 MSK (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ivan Zakharyaschev 2009-03-18 23:30:36 MSK
emacs-mode-auctex-11.84-alt1
emacs22-common-22.1-alt2
evince-gtk-2.20.1-alt0.M40.5
пакет xpdf не установлен

I opened a LaTeX file, toggled the menu option "Command > TeXing options > PDF mode", C-c C-c (LaTeX), C-c C-c (View), and it wanted to run:

xpdf -remote a -raise a.pdf 

although xpdf is not installed on this system (ALT Lite 4.0.3). But evince-gtk is.

Expected: AUCTeX detects the installed program to view PDF, and uses it. (A trivial thing in modern times; something like that is expected from an OS nowadays, not manual setup of viewers for different types of files.)

Comments on implementation of the feature: AFAIR, similar features for DVI (whether xdvi is available), dvips, dvilj etc. were implemented by making tetex-{xdvi,dvips,dvilj} put a scriptlet into /etc/emacs/site-start.d/ , which sets thevalues of the relevant Emacs variables. Perhaps, all the PDF viewers should put such a scriptlet to /etc/emacs/site-start.d/ , to inform Emacs how it can be used to view PDF.

Another way would be to use the more common "database" of filetype-program associations (I don't know how it is called), so that Emacs just gives a command like "open a.pdf", and the system decides which program that is available to use.
Comment 1 Ivan Zakharyaschev 2009-04-09 21:50:34 MSD
A similar report about using the *installed* evince for viewing DVI (instead of
the not available xdvi): https://bugzilla.altlinux.org/show_bug.cgi?id=19557 .
Comment 2 partizan 2009-05-04 12:20:33 MSD
In 11.85-alt3 xdg-open is used instead xpdf.
Comment 3 kirill 2009-05-05 09:16:34 MSD
In this case emacs-mode-auctex should have a dependency on
either xdg-utils or /usr/bin/xdg-open:
$ rpmquery emacs-mode-auctex
emacs-mode-auctex-11.85-alt3
$ rpmquery --requires emacs-mode-auctex | fgrep xdg
$
Comment 4 kirill 2011-11-02 15:12:28 MSK
We should better drop auctex-11.85-use-system-pdf-viewer.patch as it is:
 1. contains a typo, leading to bug https://bugzilla.altlinux.org/show_bug.cgi?id=22278
 2. patches in a wrong place, default system viewer should be changed 
    by means of TeX-view-program-selection
 3. xdg-open is not good replacement for evince, because it could not open
a specified page of the document which is crucial when working 
in TeX-correlate-source (source specials) mode in auctex.
Comment 5 Michael Shigorin 2014-11-05 20:17:05 MSK
В 4.0/branch исправления не будут вноситься уже технически (заглушена очередь на сборку), поэтому прошу ошибки, актуальные для sisyphus/p7/t7, перевесить на текущие ветки или сизиф.