[OS X TeX] Reflecting numbering in the source
schremmer.alain at gmail.com
Wed Aug 15 11:23:15 EDT 2007
On Aug 14, 2007, at 9:47 PM, Charilaos Skiadas wrote:
> On Aug 14, 2007, at 7:40 PM, Alain Schremmer wrote:
>> Er, this is what I am already doing (see above) and not what I
>> would like which is for the source to show, commented out since it
>> is after the %, the number of the exercise as it will appear in
>> the pdf.
>> But then of course, I don't see how this could possibly be done
>> since I can't see how the macro could keep track and I was just
>> hoping I was missing the obvious.
> Not exactly what you were looking for, but it should be very easy
> to write a shell/ruby/python script, that goes through your file
> and does essentially a "search and replace", keeping track of how
> many examples it has already encountered, and inserting the
> appropriate number in the right space. Depending on the text editor
> you use, how you would call this script varies.
> Not exactly what you wanted, but certainly removes the necessity of
> having to renumber things manually when you add a new example.
Functionally, exactly what I would like but, practically, way beyond
my reach: I can't even write an Applescript (to be inserted in a
------------------------- 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 MacOSX-TeX