Download RefTEX User Manual

Transcript
Chapter 1: Introduction
1
1 Introduction
RefTEX is a specialized package for support of labels, references, and citations in LaTeX.
RefTEX wraps itself round 3 LaTeX macros: \label, \ref, and \cite. Using these macros
usually requires looking up different parts of the document and searching through BibTeX
database files. RefTEX automates these time–consuming tasks almost entirely. It also
provides functions to display the structure of a document and to move around in this
structure quickly.
Don’t be discouraged by the size of this manual, which covers RefTEX in great depth.
All you need to know to use RefTEX can be summarized on a single page (see Section 1.4
[RefTeX in a Nutshell], page 2). You can go back later to other parts of this document
when needed.
See Section 6.10 [Imprint], page 26, for information about who to contact for help, bug
reports or suggestions.
1.1 Installation
RefTEX is bundled and pre–installed with Emacs since version 20.2.
Users of earlier Emacs distributions (including Emacs 19) can get a copy of the RefTEX
distribution from the maintainers web-page. See Section 6.10 [Imprint], page 26, for more
information.
1.2 Environment
RefTEX needs to access all files which are part of a multifile document, and the BibTeX
database files requested by the \bibliography command. To find these files, RefTEX will
require a search path, i.e., a list of directories to check. Normally this list is stored in the
environment variables TEXINPUTS and BIBINPUTS which are also used by RefTEX. However,
on some systems these variables do not contain the full search path. If RefTEX does not
work for you because it cannot find some files, read Section 6.6 [Finding Files], page 19.
1.3 Entering RefTEX Mode
To turn RefTEX Mode on and off in a particular buffer, use M-x reftex-mode. To turn
on RefTEX Mode for all LaTeX files, add the following lines to your ‘.emacs’ file:
(add-hook ’LaTeX-mode-hook ’turn-on-reftex)
; with AUCTeX LaTeX mode
(add-hook ’latex-mode-hook ’turn-on-reftex)
; with Emacs latex mode