[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Formatting the document with TeX, LaTeX or ConTeXt, viewing
with a previewer, printing the document, running BibTeX, making an
index, or checking the document with lacheck
or chktex
all
require running an external command.
There are two ways to run an external command, you can either run it on
all of the current documents with TeX-command-master
, or on the
current region with TeX-command-region
. A special case of
running TeX on a region is TeX-command-buffer
which differs
from TeX-command-master
if the current buffer is not its own
master file.
TeX-master
. The available commands are
controlled by the variable TeX-command-list
.
See section 10. How to install AUCTeX, for a discussion about TeX-command-list
and
5. Multifile Documents for a discussion about TeX-master
.
transient-mark-mode
), use the old region. The name
of the region file is controlled by the variable TeX-region
. The
name of the master file is controlled by the variable TeX-master
.
The header is all text up to the line matching the regular expression
TeX-header-end
. The trailer is all text from the line matching
the regular expression TeX-trailer-start
. The available commands
are controlled by the variable TeX-command-list
.
transient-mark-mode
active, where marks get disabled
automatically, the region would need to get properly set before each
call to TeX-command-region
. If you fix the current region with
C-c C-t C-r, then it will get used for more commands even though
mark and point may change. An explicitly activated mark, however, will
always define a new region when calling TeX-command-region
.
AUCTeX will allow one process for each document, plus one process for the region file to be active at the same time. Thus, if you are editing n different documents, you can have n plus one processes running at the same time. If the last process you started was on the region, the commands described in 4.3 Catching the errors and 4.5 Controlling the output will work on that process, otherwise they will work on the process associated with the current document.
AUCTeX will try to guess what command you want to invoke, but by
default it will assume that you want to run TeX in TeX mode and
LaTeX in LaTeX mode. You can overwrite this by setting the
variable TeX-command-default
.
TeX-command-list
.
If you want to overwrite the values of TeX-header-end
,
TeX-trailer-start
, or TeX-command-default
, you can do that
for all files by setting them in either TeX-mode-hook
,
plain-TeX-mode-hook
, or LaTeX-mode-hook
. To overwrite
them for a single file, define them as file variables (see section `File Variables' in The Emacs Editor). You do this by putting special
formatted text near the end of the file.
%%% Local Variables: %%% TeX-header-end: "% End-Of-Header" %%% TeX-trailer-start: "% Start-Of-Trailer" %%% TeX-command-default: "SliTeX" %%% End: |
AUCTeX will try to save any buffers related to the document, and
check if the document needs to be reformatted. If the variable
TeX-save-query
is non-nil, AUCTeX will query before saving
each file. By default AUCTeX will check emacs buffers associated
with files in the current directory, in one of the
TeX-macro-private
directories, and in the TeX-macro-global
directories. You can change this by setting the variable
TeX-check-path
.
If nil, just check the current file. Used when checking if any files have changed.
TeX-PDF-mode
to give it a
different default. The default is used when AUCTeX does not have
additional clue about what a document might want. This option usually
results in calling either PDFTeX or ordinary TeX.
\pdfoutput=0
. This makes it possible to use
packages like `pdfcprot' even when producing DVI files.
TeX-interactive-mode
to give it a different default. In
interactive mode, TeX will pause with an error prompt when errors are
encountered and wait for the user to type something.
You can permanently activate TeX-source-specials-mode
with
(TeX-source-specials-mode 1) |
TeX-source-specials-mode
.
There is a bunch of customization options, use customize-group
on
the group `TeX-source-specials' to find out more.
It has to be stressed very strongly however, that Source Specials can cause differences in page breaks, in spacing, can seriously interfere with various packages and should thus never be used for the final version of a document. In particular, fine-tuning the page breaks should be done with Source Specials switched off.
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |