[OS X TeX] texdoc via Applescript

Claus Gerhardt gerhardt at math.uni-heidelberg.de
Sun Nov 26 17:27:46 EST 2006


Below is an Applescript for running texdoc. You will also need a  
shell script that is actually running texdoc.

My recent Switcher distribution contains a bin folder with updates  
(path settings) for my shell scripts. One of the scripts is named  
whichc. Rename it to texdocc and replace the command which by texdoc,  
then you can use the script, if the bin folder is saved inside

~/Library/Flashmode

In TeXLive the corresponding documents are mostly pdf files that will  
be opened in Preview.

Claus


-- Applescript

set dialogSelection to "Enter the name of the document you are  
looking for, e.g., index"
activate
set input to the text returned of (display dialog dialogSelection  
default answer "" buttons {"Cancel", "Ok"} default button "Ok")
set output to do shell script "~/Library/Flashmode/bin/texdocc " & input


------------------------- 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 MacOSX-TeX mailing list