[Top][All Lists]

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

Re: Auctex&Beamer recognising pdftex mode automatically

From: Peter Dyballa
Subject: Re: Auctex&Beamer recognising pdftex mode automatically
Date: Fri, 11 May 2007 11:32:13 +0200

Am 11.05.2007 um 00:14 schrieb Brendan Halpin:

I've been looking for a way to get Emacs/AucTeX to recognise that a
paticular latex file should be processed by pdflatex, and was
delighted to stumble on the fact that \usepackage[pdftex]{graphicx}
or \documentclass[pdftex]{...} was enough.

But it doesn't seem to work for Beamer files, i.e.
\documentclass[pdftex]{beamer} still gets put in LaTeX-mode. Is
this an oddity of beamer.cls?

In a modern TeX installation latex is a sym-link, for example to pdftex, which itself is actually pdfetex. So latex produces PDF directly.

You can make AUCTeX prefer pdfTeX by adding this customisation(s, enabling micro-typography for DVI output, too):

         '(TeX-PDF-mode t)
        ; '(TeX-DVI-via-PDFTeX t)

The third option is to add a file local variable:

        %%% TeX-command-default: "pdfelatex"

which needs to de defined as a TeX command in AUCTeX.

IMO it is not recommended to restrict TeX packages to some mode (pdftex, dvips, ...), except you use a package of which you exactly know that it is not able to determine whether (x)dvipdfm(x) or dvips or something else will process the DVI output. Not using such a restrictive options the LaTeX source is free to be compiled by any TeX version to PDF, DVI, or whatever. It can be useful to have a construct like this in the file's preamble:

           \immediate\write16{\jobname: Bonjour, PDF !}
        %   \DeclareGraphicsExtensions{.png,.gif,.tif,.jpeg}
        \else           % for non-pdfTeX
           \immediate\write16{¡Hola \jobname: DVI!}
        %   \DeclareGraphicsExtensions{.eps,.ps}



The human brain operates at only 10% of its capacity. The rest is overhead for the operating system.

reply via email to

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