|
||||||||||||||||||
|
Introduction | (X)Emacs and AUCTeX | Vim | Nedit | Other Editors Please send corrections and suggestions to Stefan Ulrich.
IntroductionInverse search means that
This functionality is supported by xdvi(k) versions 22.38 and upwards. It uses so-called `source specials' in the DVI file, which can be inserted via a macro package or a command-line option to the (La)TeX program (executable). The macro packages are available as srctex.sty (for plain TeX) or srcltx.sty (for LaTeX) from CTAN:macros/latex/contrib/srcltx/. The (La)TeX version that comes with teTeX-2.0 provides a command line option `-src' to insert these specials automatically. While the macro version might interact badly with other macro packages, the option for the (La)TeX executable should be more robust. However, both versions may affect the line breaks of your document, so it's generally a good idea to disable source specials for the final version of the document. (X)Emacs and AUCTeXAUCTeX (starting with version 11.50) supports inverse search out of the box: When using TeX-source-specials-mode (which can be toggled with the key combination C-c C-t C-s), it will start emacs-server or gnu-server and xdvi(k) as required. Please see the AUCTeX manual for further details (accessible via (info "(auctex) Viewing")).If you are not using AUCTeX, please see the instructions here. Vim v6.0 upwards
Nedit and nc
Other editorsAll above examples are with editors that provide a `server mode', which allows you to load a new file into the already running editor instance. You can also use reverse search with editors that don't have this functionality, with the slight disadvantage that a new instance of the editor will be started for every reverse search. One thing to keep in mind is that non-X editors should be started in a separate window, to avoid clobbering the editor display with xdvi's diagnostic output. To do this, pass the editor command to the -e option of an xterm, e.g. for classic vi, use the following `editor' option/X resource for xdvi(k): xterm -e vi +%l %f If you set the editor via the VISUAL or EDITOR resources, xdvi will pass it to an `xterm -e' command automatically. For X editors, just use the editor name, e.g. (for xjed): xdvi -editor xjed test.dvior set the XEDITOR environment variable: export XEDITOR=xjed |
Last updated on Sun, 10 May 2009 22:15:27 +0200 by Stefan Ulrich |