From 46182f49862367599680945cbd4188c96f0c6071 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 23 Jul 2012 23:37:06 +0000 Subject: dowith (5jun12) git-svn-id: svn://tug.org/texlive/trunk@27125 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/generic/dowith/README | 10 ++++------ Master/texmf-dist/doc/generic/dowith/dowith.pdf | Bin 510304 -> 515977 bytes .../texmf-dist/source/generic/dowith/SrcFILEs.txt | 12 ++++++------ Master/texmf-dist/source/generic/dowith/dowith.tex | 16 +++++++++++----- .../texmf-dist/source/generic/dowith/srcfiles.tex | 7 +++++-- Master/texmf-dist/tex/generic/dowith/dowith.RLS | 4 +++- Master/texmf-dist/tex/generic/dowith/dowith.sty | 14 ++++++++++++-- 7 files changed, 41 insertions(+), 22 deletions(-) diff --git a/Master/texmf-dist/doc/generic/dowith/README b/Master/texmf-dist/doc/generic/dowith/README index 1ba2bc15080..66b577a4869 100644 --- a/Master/texmf-dist/doc/generic/dowith/README +++ b/Master/texmf-dist/doc/generic/dowith/README @@ -2,7 +2,7 @@ README for the `dowith' package Apply Command to Each Item in a List of Arguments in TeX's Mouth - (C) Uwe Lueck 2012/05/18 + (C) Uwe Lueck 2012/06/03 `dowith.sty' provides macros for applying a command to all items @@ -22,8 +22,8 @@ between links. This extended package may soon appear here as well. KEYWORDS: programming structures; macro programming, loops, list macros -RELATED PACKAGES: etextools, etoolbox, forarray, forloop, -multido, moredefs, lmake, texapi, xfor, xspace +RELATED PACKAGES: catoptions, etextools, etoolbox, forarray, +forloop, multido, moredefs, lmake, texapi, xfor, xspace LICENSE: @@ -54,6 +54,4 @@ FILE info packages, see Please report bugs, problems, and suggestions via - http://www.contact-ednotes.sty.de.vu - - + http://www.contact-ednotes.sty.de.vu diff --git a/Master/texmf-dist/doc/generic/dowith/dowith.pdf b/Master/texmf-dist/doc/generic/dowith/dowith.pdf index ae9704cae23..48d28085e94 100644 Binary files a/Master/texmf-dist/doc/generic/dowith/dowith.pdf and b/Master/texmf-dist/doc/generic/dowith/dowith.pdf differ diff --git a/Master/texmf-dist/source/generic/dowith/SrcFILEs.txt b/Master/texmf-dist/source/generic/dowith/SrcFILEs.txt index d83f9e15e2f..b55be1a0d0b 100644 --- a/Master/texmf-dist/source/generic/dowith/SrcFILEs.txt +++ b/Master/texmf-dist/source/generic/dowith/SrcFILEs.txt @@ -1,16 +1,16 @@ *File List* - dowith.sty 2012/05/19 v0.21a simple list loop (UL) - dowith.tex 2012/05/22 -- documenting dowith.sty -fifinddo.sty 2012/01/20 v0.51 filtering TeX(t) files by TeX (UL) - makedoc.sty 2011/11/19 v0.42 TeX input from *.sty (UL) + dowith.sty 2012/06/04 v0.22 simple list loop (UL) + dowith.tex 2012/06/03 -- documenting dowith.sty +fifinddo.sty 2012/03/17 v0.51 filtering TeX(t) files by TeX (UL) + makedoc.sty 2012/04/03 v0.51 TeX input from *.sty (UL) niceverb.sty 2011/12/05 v0.44 minimize doc markup (UL) makedoc.cfg 2012/05/10 -- documentation settings mdoccorr.cfg 2011/12/03 -- makedoc local typographical corrections srcfiles.tex 2012/05/20 -- file infos -> SrcFILEs.txt - dowith.RLS 2012/05/22 r0.21e v0.21a; doc.: Kabelschacht vs. TeXbook + dowith.RLS 2012/06/03 r0.22 v0.22 arg. {}; doc.: catoptions *********** - List made at 2012/05/22, 19:31 + List made at 2012/06/04, 12:29 from script file srcfiles.tex diff --git a/Master/texmf-dist/source/generic/dowith/dowith.tex b/Master/texmf-dist/source/generic/dowith/dowith.tex index 97027dc3508..a0cb6ac3099 100644 --- a/Master/texmf-dist/source/generic/dowith/dowith.tex +++ b/Master/texmf-dist/source/generic/dowith/dowith.tex @@ -1,4 +1,4 @@ -\ProvidesFile{dowith.tex}[2012/05/22 documenting dowith.sty] +\ProvidesFile{dowith.tex}[2012/06/03 documenting dowith.sty] \title{%%%\kern-\baselineskip \textsf{\huge dowith.sty}\\---\\Apply Command to % Elements of Lists without Separators\,---\,%%% 2012/05/14 @@ -95,6 +95,7 @@ Iteration is implemented within ``\TeX's mouth," so works within \CtanPkgRef{e-tex}{$\varepsilon$-\TeX}. \MDaddtoabstract{Related packages} +\let\pkg\ctanpkgref \pkg{catoptions}, \pkg{etextools}, \pkg{etoolbox}, \pkg{forarray}, \pkg{forloop}, \pkg{multido}, \pkg{moredefs}, \pkg{lmake}, \pkg{texapi}, \pkg{xfor}, \pkg{xspace} @@ -773,9 +774,12 @@ packages \ctanpkgref{etextools} (Florent Chervet), \ctanpkgref{etoolbox} (Philipp Lehman), and \ctanpkgref{texapi} (Paul Isambert) seem to include and (very much) extend the functionality of 'dowith'. -Also the `\ForEach'\texttt{\dots\unkern} macros of +Also the `\ForEach'\texttt{\dots\unkern\@} macros of %% \@ 2012/06/03 \ctanpkgref{forarray} (Christian Schr\"oppel) seem to extend -the present `\DoWith'\texttt{\dots\unkern} commands. +the present `\DoWith'\texttt{\dots\unkern\@} commands. %% \@ 2012/06/03 +Moreover, Ahmed Musa describes such commands as %% 2012/06/03 +``Parsing \qtd{tsv} lists" in documenting his +\ctanpkgref{catoptions} package. \ctanpkgref{moredefs} (Matt Swift) provides list handling commands like the few that are here.\footnote{\ctanpkgref{arrayjobx} provides somewhat ``exotic" handling of ``lists".} %% 2012/05/10 @@ -994,7 +998,8 @@ Addition and removal commands are provided as well. \subsection{Package File Header (Legalese)} %% sub 2012/05/10 \input{dowith.doc} -\section{Ack.: 25 Years of Kabel\-schacht's Method} %% 2012/05/20 +\newpage %% 2012/06/04 +\section{Ack.: 25 Years of Kabel\-schacht's \cs{expandafter}} %% 2012/05/20 \label{sec:kabel} The essential idea of 'dowith' and `\DoWith' is \[`\if\expandafter\fi'\] @@ -1002,7 +1007,7 @@ The essential idea of 'dowith' and `\DoWith' is % TUGboat Vol.~11 (1990), No.~2, pp.~237--245), % \urlhttpref{tug.org/TUGboat/tb11-2/tb28jeffrey.pdf}.} It was described by \textsc{Alois Kabelschacht} as -\tugbartref{tb08-2/tb18kabel}{``&\expandafter\ vs. &\let\ and &\def\ +\tugbartref{tb08-2/tb18kabel}{``&\expandafter\ vs.\ &\let\ and &\def\ in Conditionals and a Generalization of PLAIN's &\loop"} in TUGboat Vol.~8 (1987), No.~2, pp.~184f.\ (a little more than one column).\foothttpurlref{tug.org/TUGboat/% @@ -1048,3 +1053,4 @@ VERSION HISTORY `\@tfor'; remarks about `\loop' corr.: how to `foreach' ...; Kabelschacht 2012/05/22 r0.21e Kabelschacht vs. TeXbook +2012/06/03 r0.21f cf. `catoptions'; \dots\unkern\@, vs.\ diff --git a/Master/texmf-dist/source/generic/dowith/srcfiles.tex b/Master/texmf-dist/source/generic/dowith/srcfiles.tex index 182905e4c3f..5221ab35f61 100644 --- a/Master/texmf-dist/source/generic/dowith/srcfiles.tex +++ b/Master/texmf-dist/source/generic/dowith/srcfiles.tex @@ -1,15 +1,18 @@ \ProvidesFile{srcfiles.tex}[2012/05/20 file infos -> SrcFILEs.txt] \RequirePackage[r]{nicefilelist}[2012/05/20] %% <- [r] 2012/05/20 -\MFfieldtemplate{f-base}{dowithxx} +%\MFfieldtemplate{f-base}{nicefilelist} +\MFfieldtemplate{f-base}{abcdefgh} \RequirePackage{myfilist} -\EmptyFileList %%% [readprov.sty,myfilist.sty] +\EmptyFileList %%% [nicefilelist.sty] %%% [readprov.sty,myfilist.sty] %% packages: \ReadPackageInfos{dowith} %% documentation: \ReadFileInfos{dowith} %% documentation settings and auxiliaries: \ReadPackageInfos{fifinddo,makedoc,niceverb} +%% TODO readprov unable to handle package options: +%\ReadPackageInfos{nicefilelist} \ReadFileInfos{makedoc.cfg,mdoccorr.cfg} \ReadFileInfos{srcfiles} \ReadFileInfos{dowith.RLS} diff --git a/Master/texmf-dist/tex/generic/dowith/dowith.RLS b/Master/texmf-dist/tex/generic/dowith/dowith.RLS index 545f44bf128..e96cee91760 100644 --- a/Master/texmf-dist/tex/generic/dowith/dowith.RLS +++ b/Master/texmf-dist/tex/generic/dowith/dowith.RLS @@ -1,5 +1,7 @@ \ProvidesFile{dowith.RLS} %% RELEASE INFO - [2012/05/22 r0.21e v0.21a; doc.: Kabelschacht vs. TeXbook] + [2012/06/03 r0.22 v0.22 arg. {}; doc.: catoptions] +% [2012/06/03 r0.21f v0.21a; doc.: catoptions] +% [2012/05/22 r0.21e v0.21a; doc.: Kabelschacht vs. TeXbook] % [2012/05/20 r0.21d v0.21a discussing other cmds ] % [2012/05/18 v0.21 r0.21c @ fix, new doc., .RLS] % [2012/05/14 r0.21 @ fix, .RLS, README/title typo...] diff --git a/Master/texmf-dist/tex/generic/dowith/dowith.sty b/Master/texmf-dist/tex/generic/dowith/dowith.sty index 9b2ce00c4d5..6f75654b984 100644 --- a/Master/texmf-dist/tex/generic/dowith/dowith.sty +++ b/Master/texmf-dist/tex/generic/dowith/dowith.sty @@ -1,5 +1,5 @@ \def\filename{dowith} \def\fileinfo{simple list loop (UL)} -\def\filedate{2012/05/19} \def\fileversion{v0.21a} +\def\filedate{2012/06/04} \def\fileversion{v0.22} %% Copyright (C) 2011 Uwe Lueck, %% http://www.contact-ednotes.sty.de.vu %% -- author-maintained in the sense of LPPL below -- @@ -57,7 +57,16 @@ %% of . An element of (after tokenizing) %% may be either a single token or a group `{}'. \def\DoWith#1#2{% - \ifx\StopDoing#2% + \ifx\StopDoing#2\empty +%% The previous `\empty' (replacing `%') is a bug fix as of v0.22, +%% while in my extension draft I already had it in January 2012. +%% It allows ``empty" arglist items \qtd{\lbtok\rbtok}. +%% Before v0.22, such an empty brace group would have resulted +%% in comparing `\StopDoing' with `\else', so \qtd{\lbtok\rbtok} +%% would have had the same effect as `\StopDoing', the token text +%% after `\else' until `\fi' would have been skipped. +%% Instead, the user may have a reason to allow empty arguments\slash +%% brace groups. \else#1{#2}\expandafter\DoWith\expandafter#1\fi} %% |\StopDoing| delimits the list: \let\StopDoing\DoWith @@ -197,3 +206,4 @@ v0.2 2011/11/02 simpler, documented v0.21 2012/05/14 fix for "generic" and `typeoutfileinfo': @ before ...! v0.21a 2012/05/19 \labels sec:apply, sec:core; \pagebreak? +v0.22 2012/06/04 allow {} items -- cgit v1.2.3