Xref: utzoo comp.text:7921 comp.text.tex:5091 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!usc!jarthur!nntp-server.caltech.edu!news From: marcel@cs.caltech.edu (Marcel van der Goot) Newsgroups: comp.text,comp.text.tex,aus.tex Subject: Re: word count on latex document / detex and delatex Keywords: striptex detex words macros Message-ID: <1991Jan31.050715.19150@nntp-server.caltech.edu> Date: 31 Jan 91 05:07:15 GMT References: <5317@gara.une.oz.au> Sender: news@nntp-server.caltech.edu Organization: California Institute of Technology (CS dept) Lines: 41 Nntp-Posting-Host: stun4r.cs.caltech.edu In <5317@gara.une.oz.au> Tony Scott STPG (ascott@gara.une.oz.au) asks > Is there something available that will > count words without taking into account words beginning with a > backslash of those within a group such as > \begin{picture}...\end{picture} etc. And in <1991Jan25.233436.23468@nas.nasa.gov> Lonhyn T. Jasinskyj (lonhyn@nas.nasa.gov) writes > Help! I have searched high and low for detex and delatex. This includes: > labrea, washington, clarkson, ymir, uunet, ohio state, etc. > Where is this most elusive program? Also, there have several times been questions about detex or so for pc's and other machines (that apparently (?) cannot deal with the standard version of detex (if found:-)). On csvax.cs.caltech.edu [131.215.131.131] in pub/tex there is a program striptex.c that strips all macros (i.e., words starting with a backslash, or a backslash followed by a non-letter) from a file. (E.g., "this \it thing" goes to "this thing" and "carr\'e" goes to "carre".) The main advantage of the program is that it is so simple (73 lines); Even if your compiler doesn't quite accept it, it is straightforward to make a few changes to make it work. It doesn't recognize things like \input or LaTeX's \end as anything special though --- that would be a sure way to make it a complicated program. There is a unix-style (i.e., nroff) manual page striptex.l. Marcel van der Goot .---------------------------------------------------------------- | Blauw de viooltjes, marcel@vlsi.cs.caltech.edu | Rood zijn de rozen; | Een rijm kan gezet | Met plaksel en dozen. |