[OS X TeX] Emacs 22.92, %! and TeXShop

Stephen Moye stephenmoye at cox.net
Fri Jan 26 02:34:48 CET 2007


I just started using emacs 22.92 -- I have been using emacs 22.50.  
Unlike v22.50, when I open a TeXShop TeX file with emacs 22.92, it is  
opened as a PostScript file. I imagined that it had something to do  
with the first line of the file:

	%!TEX TS-program = latex

Sure enough, I went digging using

	C-h v auto-mode-alist

and found a line in files.el:

	("%![^V]" . ps-mode)

in addition to what I expected:

	("\\.[tT]e[xX]\\'" . tex-mode)

So emacs is looking inside the file to make a better guess about what  
kind of file it is. I tried changing

	("%![^V]" . ps-mode)

to

	("%![^VT]" . ps-mode)

but that did not work.

I really like emacs 22.nn, but this is a bit of a bother. Can I put  
something in my .emacs file to counter this unwanted cleverness? I  
know that I can put

	%-*-latex-*-

as the first line of the file and both emacs and TeXShop will be  
happy, but that seems an unnecessary complication.

Any suggestions? Or, alternatively, where else should I more  
appropriately post this query?

Thank you for any insights.


Stephen Moye

------------------------- Helpful Info -------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
List Reminders & Etiquette: http://www.esm.psu.edu/mac-tex/list/





More information about the macostex-archives mailing list