[OS X TeX] New Format Macro (Applescript) for TeXShop

Ramón Figueroa-Centeno ramonf at hawaii.edu
Mon Mar 30 12:34:53 CEST 2009


Aloha,

Using Claus Gerhardt's Flashmode I tend to forget that I would like the first line of my documents to have a format command, e.g. %&pdflatex. These format directives are, of course, useful in much wider contexts.
Therefore, I wrote a Format Macro to insert these format commands in TeXShop. 

Incidentally, searching the web for documentation on the use of these directives has been frustrating because most search engines will ignore "%&". So my knowledge is limited.

I am assuming that all of the formats can be found typing 

fmtutil --listcfg | awk '/^[^#].*/ {print $1}'

in the Terminal (plus ones that might be in a TeX document's directory).

In my distribution I get: aleph, lamed, amstex, cont-en, cont-en, mptopdf, metafun, cslatex, pdfcslatex, csplain, pdfcsplain, eplain, jadetex, pdfjadetex, latex, pdflatex, lualatex, pdflualatex, luatex, pdfluatex, mf, mpost, mfplain, mex, pdfmex, mltex, mllatex, omega, lambda, etex, pdfetex, pdftex, physe, phyzzx, tex, texsis, utf8mex, xetex, xelatex, xmltex and pdfxmltex. Are all of the legal possibilities for a format command, e.g. "%&mex"?

Now, I modified my Macros for Engine, Program and Root to respect documents that have in their first line format commands. For example, when using the Program Macro and such a first line starting with %&pdflatex is found then the "% !TEX TS-program" directive will be inserted in the second line.

You can find these (and more) in my website: <http://www2.hawaii.edu/~ramonf/TeXShop/index.html>.

Thanks,

Ramón



-- 
View this message in context: http://n2.nabble.com/New-Format-Macro-%28Applescript%29-for-TeXShop-tp2556556p2556556.html
Sent from the MacOSX-TeX mailing list archive at Nabble.com.

-------------- next part --------------
----------- Please Consult the Following Before Posting -----------
TeX FAQ: http://www.tex.ac.uk/faq
List Reminders and Etiquette: http://email.esm.psu.edu/mac-tex/
List Archive: http://tug.org/pipermail/macostex-archives/
TeX on Mac OS X Website: http://mactex-wiki.tug.org/
List Info: http://email.esm.psu.edu/mailman/listinfo/macosx-tex



More information about the macostex-archives mailing list