Settings Help
Comprehensive TeX Archive Network
Home Upload Browse

Direc­tory tex-archive/macros/latex/contrib/ted

                                The ted package

                        A (primitive) token list editor

                  Manuel P\'egouri\'e-Gonnard <>


Just like sed is a stream editor, ted is a token list editor.  Actually, it is
not as powerful as sed, but its main feature is that it really works with
tokens, not only characters.

The ted package provides two user macros: \Substitute and \ShowTokens. The first
one is maybe the most useful: it performs substitutions in token lists (even
inside braces). The second displays each token of the list (one per line) with
its catcode (in the list, not just the current one), and can be useful for
debugging or for TeX learners.

The ted package is designed to work well even if strange tokens (that is,
unusual (charcode, catcode) pairs or tokens with a confusing meaning) occur in
the list.


ted.sty: the package itself
ted.pdf: the (English) documentation and commented code
ted-fr.pdf: the French documentation

ted.dtx: single source for both documentations and package

Version info

2007-12-09  v1.0    First release.
2007-12-12  v1.01   Fixed a stupid bug.
2008-03-02  v1.05   - Fixed a bug when trying to substitute AA in a
                    string ending with A. Also removed a spurious space.
                    - Added an occurrence counter.
2008-03-07  v1.06   - Fixed a bug in \ShowTokens with active spaces.
                    - Slightly expanded the doc (examples).


This material is subject to the LaTeX Project Public License. See for the
details of that license.


Name Size Date Notes
README 1697 2008-03-07 03:01:00
ted-fr.pdf 61561 2008-03-07 03:03:00
ted.dtx 52964 2008-03-07 03:01:00
ted.pdf 143368 2008-03-07 03:02:00
ted.sty 10642 2008-03-07 03:07:00

Down­load the com­plete con­tents of this di­rec­tory in one zip archive (187.1k).

ted – A (prim­i­tive) to­ken list ed­i­tor

Just like sed is a stream ed­i­tor, ted is a to­ken list ed­i­tor. Ac­tu­ally, it is not as pow­er­full as sed, but its main fea­ture is that it re­ally works with to­kens, not only char­ac­ters.

The ted pack­age pro­vides two user macros: \Sub­sti­tute and \ShowTo­kens. The first is maybe the most use­ful: it per­forms sub­sti­tu­tions in to­ken lists (even in­side braces). The sec­ond dis­plays each to­ken of the list (one per line) with its cat­code (in the list, not just the cur­rent one), and can be use­ful for de­bug­ging or for TeX learn­ers.

Ted is de­signed to work well even if strange to­kens (that is, un­usual {char­code, cat­code} pairs or to­kens with a con­fus­ing mean­ing) oc­cur in the list.

Li­censeThe LaTeX Project Public Li­cense
Main­tainerManuel Pé­gourié-Gon­nard
Con­tained inTeXLive as ted
MiKTeX as ted
Topics sup­port for pack­age or doc­u­ment de­bug­ging
See also patch
Guest Book Sitemap Contact 2014-04-16 19:15 CEST