auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX] xdvi and its -unique option


From: jfbu
Subject: [AUCTeX] xdvi and its -unique option
Date: Sun, 23 Nov 2014 19:47:26 +0100

Hi,

on Linux systems, the default setup for launching  xdvi
from emacs/auctex via the View icon in the toolbar or the
View choice after typing C-c C-c
is seen in 
TeX-view-program-list-builtin
to be the concatenation of various strings, the specification
starts with
"%(o?)xdvi"
(mode-io-correlate " -sourceposition \"%n %b\" -editor \"%cS\"")
....

The second line says to check if I/O correlation is on, only 
if it is are then the -sourceposition etc... things used.

A nice side effect of these flags 
is that when one re-does C-c C-c, no
new instance of xdvi is created.

However, at least in my testing (on Mac OS X, after
having forced use of this definition of View
in output-dvi case), when there is no
I/O correlation, only xdvi is issued with no flags, 
and each time one does this, a *new* xdvi instance is launched.

As xdvi checks for modification of the dvi file, people
on big screens presumably never do again C-c C-c nor click
in the Emacs toolbar on the View icon, once a first xdvi window
exists.

But on small screens, it is often faster to type C-c C-c 
on the keyboard, than to move the mouse with the hope to find
some visible part of the xdvi window  to click upon

To address this I added a line
(not-io-correlate " -unique") 
to the "xdvi" definition,
where not-io-correlate is a predicate I defined in TeX-view-predicate-list

here is how it looks in my custom file:

'(TeX-view-predicate-list (quote ((not-io-correlate (not 
TeX-source-correlate-mode))))) 
               
I mention this here in case someone has a better advice,
or in case people find some use to it for their own needs.

Best wishes

Jean-Francois




reply via email to

[Prev in Thread] Current Thread [Next in Thread]