[OS X TeX] Conditional typesetting engine selection

Peter Dyballa Peter_Dyballa at Web.DE
Fri Nov 25 14:19:24 CET 2005

Am 25.11.2005 um 13:01 schrieb Paul Vickers:

> \ifxetex
>    %!TEX TS-program = xelatex
> \else
>    %!TEX TS-program = pdflatex
> \fi
> %!TEX encoding = UTF-8 Unicode
> %!TEX root = ./Main.tex

This can't work since TeXShop does no TeX parsing. It just looks for 
lines starting with %!TEX and evaluates them accordingly. In your case 
TeXShop might see two mappings of TS-program. Depending on the way 
TeXShop is implemented it either takes the first occurence (a 
requirement fulfilled) or repeats the mapping as often as the TeX 
source offers.

Make pdflatex your default TeX engine in TeXShop (no markup in the 
source) and choose for the final release XeLaTeX from the menu. So in 
case you're in a hurry and press falsely the set button it's only 
pdflatex that starts. And soon finishes ...



The world would be a better place if Larry Wall had been born in
Iceland, or any other country where the native language actually
has syntax.
         -- Peter da Silva

------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
          & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/

More information about the macostex-archives mailing list