[OS X TeX] On the %!TEX ... codes (was Re: Latexian 1.0 Released)

Herbert Schulz herbs at wideopenwest.com
Thu Dec 9 23:12:35 CET 2010


On Dec 9, 2010, at 10:04 AM, Josep Maria Font wrote:

> Hi,
> 
> Very interested in following the recent thread on advantages of using the codes %!TEX xxx = yyy at the beginning of files for several purposes. Especially Juan Luís explanation was very helpful. The examples in his last message have reminded me of one doubt: Is it 
> 
> %!TEX xxx = yyy
> 
> or rather
> 
> % !TEX xxx = yyy ?
> 
> If I recall correctly, the first form was the original one, but due to clash with postscript code it was recommended to use %%!TEX , and later on  % !TEX , which appears in the examples in last message (but not in some of the text). Curiously, TeXShop's Help panel recommends %!TEX in some places, but % !TEX in others. 
> 
> Can anyone clarify and point to a definitive and authoritative source ?
> 
> Finally, it would be helpful to explain the interaction between the 
> 
> % !TEX encoding = IsoLatin
> 
> mechanism and usage of
> 
> \usepackage[latin1]{inputenc}
> 
> and similar options. I think this package has to be called so that typing á in your source file renders á in the typeset; without it, even if you have % !TEX encoding = IsoLatin, the á will be understood but not typeset. Am I right ?
> 
> Thanks to all,
> 
> 
> JMaF
> 
> 
> [Juan Luís: En el Help en español hay un sitio donde dice que no puede haber espacios alrededor del signo = !]
> 
> 
> JM

Howdy,

In TeXShop, at least, any of the forms

%!TeX ...,

%%!TeX ...

and

% !TeX ...

will be accepted. The first, original form had an objection because some PostScript interpreters in printers too %! as the first characters in a file to mean that it was a PostScript file (that is wrong, it is supposed to be %!PS and they were being lazy but there is not much one can do about that). The second version, with the double %%, was invented by me since it solved the ``problem'' with the first version. The official version is the third one, with the space.

Good Luck,

Herb Schulz
(herbs at wideopenwest dot com)






More information about the macostex-archives mailing list