diff options
Diffstat (limited to 'Master/texmf-dist')
31 files changed, 328 insertions, 243 deletions
diff --git a/Master/texmf-dist/doc/latex/tikzlings/README.md b/Master/texmf-dist/doc/latex/tikzlings/README.md index 83335e5a6e9..d0586008b45 100644 --- a/Master/texmf-dist/doc/latex/tikzlings/README.md +++ b/Master/texmf-dist/doc/latex/tikzlings/README.md @@ -1,7 +1,7 @@ # TikZlings A collection of animals and other beings from the tikz world -Current version: 2022/04/21 version v0.9 +Current version: 2022/06/17 version v1.0 This project is licensed under the LaTeX Project Public License v1.3c or later, see http://www.latex-project.org/lppl.txt diff --git a/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.pdf b/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.pdf Binary files differindex e3040b2821c..06e80aa7254 100644 --- a/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.pdf +++ b/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.pdf diff --git a/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.tex b/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.tex index 4c07dc3578c..3740b1be813 100644 --- a/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.tex +++ b/Master/texmf-dist/doc/latex/tikzlings/tikzlings-doc.tex @@ -33,6 +33,7 @@ allcolors=SteelBlue!50!black ]{hyperref} \usetikzlibrary{3d} +\usetikzlibrary{tikzlings} % macros %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \newcommand{\CTAN}{\textsc{CTAN}\xspace} @@ -223,7 +224,7 @@ \url{https://github.com/samcarter/tikzlings}\\ \url{https://www.ctan.org/pkg/tikzlings} }{samcarter}} -\date{Version v0.9 \textendash{} 2022/04/21} +\date{Version v1.0 \textendash{} 2022/06/17} \begin{document} \maketitle @@ -337,7 +338,7 @@ With regard to the individual components of the \tikzlings, they are located in A short example how the hooks can be used: \begin{tcblisting}{} \newcommand{\mousehookbelly}{% - \fill[red!80!black] +\fill[red!80!black] (0.55, 1.35) -- (0.65, 0.3) -- (-0.65, 0.3) -- (-0.55, 1.35) -- (0.0, 0.9) -- cycle; @@ -345,6 +346,42 @@ A short example how the hooks can be used: \mouse \end{tcblisting} +Another way to use the \tikzlings is the \TikZ library of the same name. By loading this library, all macros from the normal package can be used. In addition the \TikZ library also defines the \tikzlings as \lstinline|pic|'s: +\begin{tcolorbox} +\begin{lstlisting}[morekeywords={bear,penguin,coati,thing,cat,duck,standalone,tikz,document}] +\documentclass{standalone} + +\usepackage{tikz} +\usetikzlibrary{tikzlings} + +\begin{document} +\begin{tikzpicture} +\path (1,0) pic{bear} + (2,1) pic[ + coati/body=blue, + scale=0.5 + ]{coati} + (3,2) pic[ + thing/hat=red + ]{penguin}; +\end{tikzpicture} +\end{document} +\end{lstlisting} + +\tcblower +\begin{tikzpicture} +\path (1,0) pic{bear} + (2,1) pic[ + coati/body=blue, + scale=0.5 + ]{coati} + (3,2) pic[ + thing/hat=red!80!black + ]{penguin}; +\end{tikzpicture} +\end{tcolorbox} + +\clearpage \subsection*{List of all \tikzlings:} \begingroup @@ -353,18 +390,8 @@ A short example how the hooks can be used: \endgroup \makeatletter -% modified from https://chat.stackexchange.com/transcript/message/56515698#56515698 -\ExplSyntaxOn -\cs_new_protected:Npn \tikzlings_load_stys:N #1 { - \clist_map_inline:Nn #1 { - \exp_args:Nx \CommentInput { - tikzlings- \__tikzlings_after_slash:w ##1 / / \s_stop .sty - } - } -} -\cs_new_eq:NN \tikzling@loadstys \tikzlings_load_stys:N -\ExplSyntaxOff -\tikzling@loadstys\tikzling@list +\tikzlings@clistMapInlineNn{\tikzlings@packages@clist}{% + \CommentInput{tikzlings-#1.sty}} \makeatother %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -393,7 +420,7 @@ A short example how the hooks can be used: \subsection{Options} -Only options common for all \tikzlings are supported for the \lstinline|\tikzling|. These are the ability to change the body colour +Options common for all \tikzlings are supported for the \lstinline|\tikzling|. These are the ability to change the body colour \begin{tcblisting}{} \tikzling[body=blue] \end{tcblisting} @@ -413,7 +440,7 @@ And finally the \lstinline|contour| key will only draw the outlines: \tikzling[contour=black] \end{tcblisting} -If an option of a specific tikzlings is used (for example \lstinline|sleeping| which only the koala and sloth can do) this only works if you are lucky and one of them is drawn, in all other cases it will result in an error. +If an option of a specific Ti\emph{k}Zling is used (for example \lstinline|sleeping|, which only the koala and sloth can do) this option will only work for these \tikzlings. For all other \tikzlings, the option will be silently ignored. In addition all usual \TikZ and \lstinline|pgf| keys can be used in the optional argument as well as the accessories presented in the following section. diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlibrarytikzlings.code.tex b/Master/texmf-dist/tex/latex/tikzlings/tikzlibrarytikzlings.code.tex new file mode 100644 index 00000000000..449b2ce5b13 --- /dev/null +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlibrarytikzlings.code.tex @@ -0,0 +1,34 @@ +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% +% TikZ library for the tikzlings package +% A package to bring cute little animals and other beings into tikz +% Maintained by samcarter +% +% Project repository and bug tracker: +% https://github.com/samcarter/tikzlings +% +% Released under the LaTeX Project Public License v1.3c or later +% See http://www.latex-project.org/lppl.txt +% +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\usepackage{tikzlings} + +\ExplSyntaxOn + +\clist_map_inline:Nn \g__tikzlings_names_clist + { + \tikzset + { + % Create a csname in the argument but don't expand it now + #1/.pic/.expanded = { \exp_not:c {#1} }, + #1/.search~also = { , /tikz, /pgf, /thing }, + } + } + +\ExplSyntaxOff + +\tikzset{ + tikzling/.pic={\tikzling}, + tikzling/.search also={,/tikz,/pgf,/thing}, + thing/.search also={,/tikz,/pgf}, +}
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-addons.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-addons.sty index 931b3a4f912..9c41b7cfdef 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-addons.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-addons.sty @@ -12,7 +12,7 @@ % See http://www.latex-project.org/lppl.txt % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-addons}[2022/04/21 version v0.9 Draw additional items for the tikzlings] +\ProvidesPackage{tikzlings-addons}[2022/06/17 version v1.0 Draw additional items for the tikzlings] \RequirePackage{tikz} \usetikzlibrary{patterns} % for the wizard hat @@ -21,32 +21,26 @@ % % List of all TikZlings % -% converting a list of the format -% bee/bees, marmot/marmots, ... -% into a list of the format -% /bee, /marmot, ... -% for the also search option -% usage: \tikzling@iteratesearch\tikzling@list -% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \RequirePackage{tikzlings-list} \RequirePackage{expl3} \ExplSyntaxOn -\cs_new:Npn \tikzlings_iteratesearch:N #1 { - \clist_map_function:NN #1 \__tikzlings_slashed_items:n -} -\cs_new:Npn \__tikzlings_slashed_items:n #1 { - / - \exp_not:N { - \__tikzlings_before_slashsearch:w #1 / \s_stop +\seq_clear:N \l_tmpa_seq + +\clist_map_inline:Nn \g__tikzlings_names_clist + { + \seq_put_right:Nn \l_tmpa_seq { /#1 } } - , -} -\cs_new:Npn \__tikzlings_before_slashsearch:w #1 / #2 \s_stop { - \tl_trim_spaces:n {#1} -} -\cs_new_eq:NN \tikzling@iteratesearch \tikzlings_iteratesearch:N + +% Comma list such as '/anteater,/bat,/bear,...,/wolf' for use with the +% '.search also' handler +\clist_const:Nx \c__tikzlings_search_paths_clist + { + \seq_use:Nn \l_tmpa_seq { , } + } + +\cs_new_eq:NN \tikzlings@search@paths@clist \c__tikzlings_search_paths_clist \ExplSyntaxOff %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -119,7 +113,7 @@ % General % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - /thing/.search also/.expanded={/tikz,/pgf,\tikzling@iteratesearch\tikzling@list}, + /thing/.search also/.expanded={/tikz, /pgf, \tikzlings@search@paths@clist}, %/thing/.unknown/.code=\relax, % bad idea, prevents tikz/pgf keys /thing/.cd, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-anteaters.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-anteaters.sty index d81acbb6793..6e2b75b30e2 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-anteaters.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-anteaters.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-anteaters}[2022/04/21 version v0.9 Drawing anteaters in TikZ] +\ProvidesPackage{tikzlings-anteaters}[2022/06/17 version v1.0 Drawing anteaters in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -45,9 +45,9 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\anteater@body{#1}, + body/.store in = \anteater@body, body = red!55!green!75!blue!66!white, - eye/.code = \def\anteater@eye{#1}, + eye/.store in = \anteater@eye, eye = \anteater@body!70!brown!50!darkgray, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % @@ -123,18 +123,22 @@ % Body %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \anteater@part@draw[\anteater@body] (0.52, 0.8) .. controls (0.52, 0.23) and (0.3, 0.17) .. (0, 0.17) .. controls (-0.3, 0.17) and (-0.52, 0.23) .. (-0.52, 0.8) .. controls (-0.52, 1.35) and (-0.3, 1.8) .. (0, 1.8) .. controls (0.3, 1.8) and (0.52, 1.35) .. (0.52, 0.8) -- cycle; % + % Collar %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \ifanteater@back + \anteater@part@draw[\anteater@body!45!white!95!orange] (-0,1.47) ellipse [x radius=0.36, y radius=0.28]; + \anteater@part@draw[\anteater@body!70!brown!50!darkgray] + (-0,1.47) ellipse [x radius=0.35, y radius=0.23]; + \else% back + \anteater@part@draw[\anteater@body!45!white!95!orange] (0.33, 1.55) -- (-0.33, 1.55) .. controls (-0.5, 1.05) and (-0.1, 0.95) .. (0, 0.60) .. controls (0.1, 0.95) and (0.5, 1.05) .. (0.33, 1.55) -- cycle; + \anteater@part@draw[\anteater@body!70!brown!50!darkgray] (0.33, 1.55) -- (-0.33, 1.55) .. controls (-0.45, 1.1) and (-0.1, 1) .. (0, 0.70) .. controls (0.1, 1) and (0.45, 1.1) .. (0.33, 1.55) -- cycle; + \fi% back + % % adding hook for users to customise %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \csname anteaterhookbelly\endcsname \csname tikzlinghookbelly\endcsname % \ifanteater@back - % - % Head %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \anteater@part@draw[\anteater@body!45!white!95!orange] (-0,1.47) ellipse [x radius=0.36, y radius=0.28]; - % - % Collar %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \anteater@part@draw[\anteater@body!70!brown!50!darkgray] - (-0,1.47) ellipse [x radius=0.35, y radius=0.23]; + % Head %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \anteater@part@draw[\anteater@body] (-0,1.73) ellipse [x radius=0.36, y radius=0.33]; % % Ears %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% @@ -143,10 +147,6 @@ % \else% back % - % Collar %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \anteater@part@draw[\anteater@body!45!white!95!orange] (0.33, 1.55) -- (-0.33, 1.55) .. controls (-0.5, 1.05) and (-0.1, 0.95) .. (0, 0.60) .. controls (0.1, 0.95) and (0.5, 1.05) .. (0.33, 1.55) -- cycle; - \anteater@part@draw[\anteater@body!70!brown!50!darkgray] (0.33, 1.55) -- (-0.33, 1.55) .. controls (-0.45, 1.1) and (-0.1, 1) .. (0, 0.70) .. controls (0.1, 1) and (0.45, 1.1) .. (0.33, 1.55) -- cycle; - % % Ears %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \anteater@part@draw[\anteater@body!70!brown!50!darkgray] (0.3531, 1.9773) .. controls (0.4315, 2.0197) and (0.6217, 2.172) .. (0.5917, 2.2157) .. controls (0.5615, 2.2594) and (0.3224, 2.178) .. (0.2441, 2.1354) .. controls (0.1659, 2.093) and (0.1269, 2.023) .. (0.1569, 1.9793) .. controls (0.1870, 1.9356) and (0.2748, 1.9347) .. (0.3531, 1.9773) -- cycle; \anteater@part@draw[\anteater@body!70!brown!50!darkgray] (-0.3531, 1.9773) .. controls (-0.4315, 2.0197) and (-0.6217, 2.172) .. (-0.5917, 2.2157) .. controls (-0.5615, 2.2594) and (-0.3224, 2.178) .. (-0.2441, 2.1354) .. controls (-0.1659, 2.093) and (-0.1269, 2.023) .. (-0.1569, 1.9793) .. controls (-0.1870, 1.9356) and (-0.2748, 1.9347) .. (-0.3531, 1.9773) -- cycle; diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bats.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bats.sty index 83f73fc6895..3d1bbb27fd6 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bats.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bats.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-bats}[2022/04/21 version v0.9 Drawing bats in TikZ] +\ProvidesPackage{tikzlings-bats}[2022/06/17 version v1.0 Drawing bats in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -47,19 +47,19 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\bat@body{#1}, + body/.store in = \bat@body, body = black!75!white, - ears/.code = \def\bat@ears{#1}, + ears/.store in = \bat@ears, ears = \bat@body, - eye/.code = \def\bat@eye{#1}, + eye/.store in = \bat@eye, eye = white, - pupil/.code = \def\bat@pupil{#1}, + pupil/.store in = \bat@pupil, pupil = black, - mouth/.code = \def\bat@mouth{#1}, + mouth/.store in = \bat@mouth, mouth = black, - feet/.code = \def\bat@feet{#1}, + feet/.store in = \bat@feet, feet = orange, - wings/.code = \def\bat@wings{#1}, + wings/.store in = \bat@wings, wings = 1, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bears.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bears.sty index 916adec3af1..22fbe6c3f32 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bears.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bears.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-bears}[2022/04/21 version v0.9 Draw teddy bears in TikZ] +\ProvidesPackage{tikzlings-bears}[2022/06/17 version v1.0 Draw teddy bears in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -45,11 +45,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\bear@body{#1}, + body/.store in = \bear@body, body = brown, - eye/.code = \def\bear@eye{#1}, + eye/.store in = \bear@eye, eye = \bear@body!30!black, - mouth/.code = \def\bear@mouth{#1}, + mouth/.store in = \bear@mouth, mouth = \bear@body!30!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bees.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bees.sty index 089341f71d7..9fec259bdbd 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bees.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bees.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-bees}[2022/04/21 version v0.9 Drawing bees in TikZ] +\ProvidesPackage{tikzlings-bees}[2022/06/17 version v1.0 Drawing bees in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,19 +46,19 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\bee@body{#1}, + body/.store in = \bee@body, body = yellow!70!orange, - hands/.code = \def\bee@hands{#1}, + hands/.store in = \bee@hands, hands = black, - wings/.code = \def\bee@wings{#1}, + wings/.store in = \bee@wings, wings = blue!20!cyan!30!white, - stripes/.code = \def\bee@stripes{#1}, + stripes/.store in = \bee@stripes, stripes = black, - antennas/.code = \def\bee@antennas{#1}, + antennas/.store in = \bee@antennas, antennas = black, - eye/.code = \def\bee@eye{#1}, + eye/.store in = \bee@eye, eye = black, - mouth/.code = \def\bee@mouth{#1}, + mouth/.store in = \bee@mouth, mouth = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bugs.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bugs.sty index ba816e7b393..65febf3bbc2 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bugs.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-bugs.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-bugs}[2022/04/21 version v0.9 Drawing bugs in TikZ] +\ProvidesPackage{tikzlings-bugs}[2022/06/17 version v1.0 Drawing bugs in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,23 +46,23 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\bug@body{#1}, + body/.store in = \bug@body, body = black!90!white, - arms/.code = \def\bug@arms{#1}, + arms/.store in = \bug@arms, arms = red!80!black, - wings/.code = \def\bug@wings{#1}, + wings/.store in = \bug@wings, wings = red!80!black, - dots/.code = \def\bug@dots{#1}, + dots/.store in = \bug@dots, dots = black!90!white, - antennas/.code = \def\bug@antennas{#1}, + antennas/.store in = \bug@antennas, antennas = red!80!black, - eye/.code = \def\bug@eye{#1}, + eye/.store in = \bug@eye, eye = white, - pupil/.code = \def\bug@pupil{#1}, + pupil/.store in = \bug@pupil, pupil = black, - mouth/.code = \def\bug@mouth{#1}, + mouth/.store in = \bug@mouth, mouth = red, - feet/.code = \def\bug@feet{#1}, + feet/.store in = \bug@feet, feet = red!80!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-cats.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-cats.sty index 37b2f151740..d34599cd7aa 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-cats.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-cats.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-cats}[2022/04/21 version v0.9 Drawing cats in TikZ] +\ProvidesPackage{tikzlings-cats}[2022/06/17 version v1.0 Drawing cats in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -73,14 +73,14 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\cat@body{#1}, + body/.store in = \cat@body, body = gray!30!black, - whiskers/.code = \def\cat@whiskers{#1}, + whiskers/.store in = \cat@whiskers, whiskers = gray!50!white, - eye/.code = \def\cat@eye{#1}, + eye/.store in = \cat@eye, eye = yellow!80!orange, eyes/.forward to = /cat/eye, - pupil/.code = \def\cat@pupil{#1}, + pupil/.store in = \cat@pupil, pupil = black, pupilwidth/.code = \def\cat@pupil@width{#1} \edef\cat@pupil@offset{\strip@pt\dimexpr#1pt/4}, @@ -94,9 +94,9 @@ very wide pupils/.code = \def\cat@pupil@width{0.050} \edef\cat@pupil@offset{\strip@pt\dimexpr 0.050pt/4}, pupil width = 0.015, - paws/.code = \def\cat@paws{#1}, + paws/.store in = \cat@paws, paws = \cat@body, - nose/.code = \def\cat@nose{#1}, + nose/.store in = \cat@nose, nose = red!40!white!80!gray, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-chickens.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-chickens.sty index 62ddc10b5da..1d96fc9d662 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-chickens.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-chickens.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-chickens}[2022/04/21 version v0.9 Draw chickens in TikZ] +\ProvidesPackage{tikzlings-chickens}[2022/06/17 version v1.0 Draw chickens in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -52,17 +52,17 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\chicken@body{#1}, + body/.store in = \chicken@body, body = brown!50!orange!70!yellow!80!white, - eye/.code = \def\chicken@eye{#1}, + eye/.store in = \chicken@eye, eye = white!90!gray, - pupil/.code = \def\chicken@pupil{#1}, + pupil/.store in = \chicken@pupil, pupil = brown!30!black, - bill/.code = \def\chicken@bill{#1}, + bill/.store in = \chicken@bill, bill = yellow, - feet/.code = \def\chicken@feet{#1}, + feet/.store in = \chicken@feet, feet = orange!90!yellow, - comb/.code = \def\chicken@comb{#1}, + comb/.store in = \chicken@comb, comb = red, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty index 773706fadaf..d98c1398f26 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-coatis.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-coatis}[2022/04/21 version v0.9 Drawing coatis in TikZ] +\ProvidesPackage{tikzlings-coatis}[2022/06/17 version v1.0 Drawing coatis in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,11 +46,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\coati@body{#1}, + body/.store in = \coati@body, body = brown!50!darkgray!97!yellow, - eye/.code = \def\coati@eye{#1}, + eye/.store in = \coati@eye, eye = \coati@body!50!black, - rotatehead/.code = \def\coati@rotatehead{#1}, + rotatehead/.store in = \coati@rotatehead, rotate head/.forward to = /coati/rotatehead, rotatehead = 0, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-elephants.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-elephants.sty index 6f67b23d9c3..ffd517febda 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-elephants.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-elephants.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-elephants}[2022/04/21 version v0.9 Draw teddy elephants in TikZ] +\ProvidesPackage{tikzlings-elephants}[2022/06/17 version v1.0 Draw teddy elephants in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -45,9 +45,9 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\elephant@body{#1}, + body/.store in = \elephant@body, body = gray, - eye/.code = \def\elephant@eye{#1}, + eye/.store in = \elephant@eye, eye = \elephant@body!30!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-hippos.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-hippos.sty index fbbe1049e4e..4761516d538 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-hippos.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-hippos.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-hippos}[2022/04/21 version v0.9 Drawing hippos in TikZ] +\ProvidesPackage{tikzlings-hippos}[2022/06/17 version v1.0 Drawing hippos in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -45,15 +45,15 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\hippo@body{#1}, + body/.store in = \hippo@body, body = gray, - eye/.code = \def\hippo@eye{#1}, + eye/.store in = \hippo@eye, eye = white, - pupil/.code = \def\hippo@pupil{#1}, + pupil/.store in = \hippo@pupil, pupil = black, - toes/.code = \def\hippo@toes{#1}, + toes/.store in = \hippo@toes, toes = \hippo@body!55!white, - mouth/.code = \def\hippo@mouth{#1}, + mouth/.store in = \hippo@mouth, mouth = \hippo@body!70!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-koalas.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-koalas.sty index cda377c7466..4968d7b5168 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-koalas.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-koalas.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-koalas}[2022/04/21 version v0.9 Drawing koalas in TikZ] +\ProvidesPackage{tikzlings-koalas}[2022/06/17 version v1.0 Drawing koalas in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -52,11 +52,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\koala@body{#1}, + body/.store in = \koala@body, body = gray!75!white, - eye/.code = \def\koala@eye{#1}, + eye/.store in = \koala@eye, eye = black, - mouth/.code = \def\koala@mouth{#1}, + mouth/.store in = \koala@mouth, mouth = \koala@body!40!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-list.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-list.sty index 748a55818a1..09a0967f2c7 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-list.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-list.sty @@ -1,33 +1,57 @@ -\ProvidesPackage{tikzlings-list}[2022/04/21 version v0.9 Helper package for the tikzlings] +\ProvidesPackage{tikzlings-list}[2022/06/17 version v1.0 Helper package for the tikzlings] %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % List of all TikZlings % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\def\tikzling@list{ - anteater/anteaters, - bat/bats, - bear/bears, - bee/bees, - bug/bugs, - cat/cats, - chicken/chickens, - coati/coatis, - elephant/elephants, - hippo/hippos, - koala/koalas, - marmot/marmots, - mouse/mice, - moles/moles, - owl/owls, - panda/pandas, - penguin/penguins, - pig/pigs, - rhino/rhinos, - sheep/sheep, - sloth/sloths, - snowman/snowmen, - squirrel/squirrels, - wolf/wolves% -} + +\ExplSyntaxOn + +\clist_const:Nn \c__tikzlings_clist + { + anteater / anteaters, + bat / bats, + bear / bears, + bee / bees, + bug / bugs, + cat / cats, + chicken / chickens, + coati / coatis, + elephant / elephants, + hippo / hippos, + koala / koalas, + marmot / marmots, + mouse / mice, + moles / moles, % avoid conflict with siunitx's \mole + owl / owls, + panda / pandas, + penguin / penguins, + pig / pigs, + rhino / rhinos, + sheep / sheep, + sloth / sloths, + snowman / snowmen, + squirrel / squirrels, + wolf / wolves + } + +\clist_new:N \g__tikzlings_names_clist +\clist_new:N \g__tikzlings_packages_clist + +% Store the two “columns” of \c__tikzlings_clist in these variables +\clist_map_inline:Nn \c__tikzlings_clist + { + \seq_set_split:Nnn \l_tmpa_seq { / } {#1} + \clist_gput_right:Nx \g__tikzlings_names_clist + { \seq_item:Nn \l_tmpa_seq { 1 } } + \clist_gput_right:Nx \g__tikzlings_packages_clist + { \seq_item:Nn \l_tmpa_seq { 2 } } + } + +% Define aliases that can be used without \ExplSyntaxOn +\cs_new_eq:NN \tikzlings@clist \c__tikzlings_clist +\cs_new_eq:NN \tikzlings@names@clist \g__tikzlings_names_clist +\cs_new_eq:NN \tikzlings@packages@clist \g__tikzlings_packages_clist + +\ExplSyntaxOff diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-marmots.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-marmots.sty index a2aca2252e2..d67b9fb51db 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-marmots.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-marmots.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-marmots}[2022/04/21 version v0.9 Drawing marmots in TikZ] +\ProvidesPackage{tikzlings-marmots}[2022/06/17 version v1.0 Drawing marmots in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -74,11 +74,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\marmot@body{#1}, + body/.store in = \marmot@body, body = brown, - eye/.code = \def\marmot@eye{#1}, + eye/.store in = \marmot@eye, eye = \marmot@body!50!black, - mouth/.code = \def\marmot@mouth{#1}, + mouth/.store in = \marmot@mouth, mouth = \marmot@body!50!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-mice.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-mice.sty index c34762146a4..b864d03fd6f 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-mice.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-mice.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-mice}[2022/04/21 version v0.9 Drawing mice in TikZ] +\ProvidesPackage{tikzlings-mice}[2022/06/17 version v1.0 Drawing mice in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -49,11 +49,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\mouse@body{#1}, + body/.store in = \mouse@body, body = gray!90!white, - eye/.code = \def\mouse@eye{#1}, + eye/.store in = \mouse@eye, eye = \mouse@body!50!black, - whiskers/.code = \def\mouse@whiskers{#1}, + whiskers/.store in = \mouse@whiskers, whiskers = \mouse@body!50!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-moles.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-moles.sty index 135b00ef2a2..a64afa5720e 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-moles.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-moles.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-moles}[2022/04/21 version v0.9 Drawing moles in TikZ] +\ProvidesPackage{tikzlings-moles}[2022/06/17 version v1.0 Drawing moles in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,17 +46,17 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\moles@body{#1}, + body/.store in = \moles@body, body = gray, - eye/.code = \def\moles@eye{#1}, + eye/.store in = \moles@eye, eye = \moles@body!60!black, - feet/.code = \def\moles@feet{#1}, + feet/.store in = \moles@feet, feet = red!20!white!50!brown, - hands/.code = \def\moles@hands{#1}, + hands/.store in = \moles@hands, hands = red!20!white!50!brown, - muzzle/.code = \def\moles@muzzle{#1}, + muzzle/.store in = \moles@muzzle, muzzle = red!20!white!50!brown, - mouth/.code = \def\moles@mouth{#1}, + mouth/.store in = \moles@mouth, mouth = \moles@body!60!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-owls.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-owls.sty index 7f8c0b905c8..cf57616cc89 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-owls.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-owls.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-owls}[2022/04/21 version v0.9 Draw owls in TikZ] +\ProvidesPackage{tikzlings-owls}[2022/06/17 version v1.0 Draw owls in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,15 +46,15 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\owl@body{#1}, + body/.store in = \owl@body, body = brown!70!black, - eye/.code = \def\owl@eye{#1}, + eye/.store in = \owl@eye, eye = white!90!gray, - pupil/.code = \def\owl@pupil{#1}, + pupil/.store in = \owl@pupil, pupil = brown!30!black, - bill/.code = \def\owl@bill{#1}, + bill/.store in = \owl@bill, bill = orange, - feet/.code = \def\owl@feet{#1}, + feet/.store in = \owl@feet, feet = orange, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pandas.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pandas.sty index cb578eb2808..f746d880e19 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pandas.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pandas.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-pandas}[2022/04/21 version v0.9 Drawing pandas in TikZ] +\ProvidesPackage{tikzlings-pandas}[2022/06/17 version v1.0 Drawing pandas in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,13 +46,13 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\panda@body{#1}, + body/.store in = \panda@body, body = white!90!black, - eye/.code = \def\panda@eye{#1}, + eye/.store in = \panda@eye, eye = white, - pupil/.code = \def\panda@pupil{#1}, + pupil/.store in = \panda@pupil, pupil = black, - mouth/.code = \def\panda@mouth{#1}, + mouth/.store in = \panda@mouth, mouth = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-penguins.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-penguins.sty index de014279140..8bceea8a19d 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-penguins.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-penguins.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-penguins}[2022/04/21 version v0.9 Draw penguins in TikZ] +\ProvidesPackage{tikzlings-penguins}[2022/06/17 version v1.0 Draw penguins in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,17 +46,17 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\penguin@body{#1}, + body/.store in = \penguin@body, body = black, - belly/.code = \def\penguin@belly{#1}, + belly/.store in = \penguin@belly, belly = white!95!black, - feet/.code = \def\penguin@feet{#1}, + feet/.store in = \penguin@feet, feet = yellow!50!orange, - bill/.code = \def\penguin@bill{#1}, + bill/.store in = \penguin@bill, bill = orange, - eye/.code = \def\penguin@eye{#1}, + eye/.store in = \penguin@eye, eye = white!95!black, - pupil/.code = \def\penguin@pupil{#1}, + pupil/.store in = \penguin@pupil, pupil = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pigs.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pigs.sty index bbf91cf52ea..d551f0a0602 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pigs.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-pigs.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-pigs}[2022/04/21 version v0.9 Drawing pigs in TikZ] +\ProvidesPackage{tikzlings-pigs}[2022/06/17 version v1.0 Drawing pigs in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -47,13 +47,13 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\pig@body{#1}, + body/.store in = \pig@body, body = pigdark, - eye/.code = \def\pig@eye{#1}, + eye/.store in = \pig@eye, eye = gray, - tail/.code = \def\pig@tail{#1}, + tail/.store in = \pig@tail, tail = \pig@body, - mouth/.code = \def\pig@mouth{#1}, + mouth/.store in = \pig@mouth, mouth = gray, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-rhinos.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-rhinos.sty index fde702c822e..5ce10d34be2 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-rhinos.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-rhinos.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-rhinos}[2022/04/21 version v0.9 Drawing rhinos in TikZ] +\ProvidesPackage{tikzlings-rhinos}[2022/06/17 version v1.0 Drawing rhinos in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -46,15 +46,15 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\rhino@body{#1}, + body/.store in = \rhino@body, body = gray, - toes/.code = \def\rhino@toes{#1}, + toes/.store in = \rhino@toes, toes = \rhino@body!55!white, - eye/.code = \def\rhino@eye{#1}, + eye/.store in = \rhino@eye, eye = white, - pupil/.code = \def\rhino@pupil{#1}, + pupil/.store in = \rhino@pupil, pupil = black, - mouth/.code = \def\rhino@mouth{#1}, + mouth/.store in = \rhino@mouth, mouth = \rhino@body!70!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sheep.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sheep.sty index eebd85972f6..5c8cd7e6bc3 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sheep.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sheep.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-sheep}[2022/04/21 version v0.9 Drawing sheep in TikZ] +\ProvidesPackage{tikzlings-sheep}[2022/06/17 version v1.0 Drawing sheep in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -51,11 +51,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\sheep@body{#1}, + body/.store in = \sheep@body, body = brown!50!darkgray!97!yellow, - eye/.code = \def\sheep@eye{#1}, + eye/.store in = \sheep@eye, eye = \sheep@body!50!black, - nose/.code = \def\sheep@nose{#1}, + nose/.store in = \sheep@nose, nose = \sheep@body!50!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sloths.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sloths.sty index 2be1bcd9b96..fc7658629dd 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sloths.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-sloths.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-sloths}[2022/04/21 version v0.9 Drawing sloths in TikZ] +\ProvidesPackage{tikzlings-sloths}[2022/06/17 version v1.0 Drawing sloths in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -49,13 +49,13 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\sloth@body{#1}, + body/.store in = \sloth@body, body = slothcol, - eye/.code = \def\sloth@eye{#1}, + eye/.store in = \sloth@eye, eye = black, - eyelid/.code = \def\sloth@eyelid{#1}, + eyelid/.store in = \sloth@eyelid, eyelid = \sloth@body!50!white, - mouth/.code = \def\sloth@mouth{#1}, + mouth/.store in = \sloth@mouth, mouth = \sloth@body!40!black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-snowmen.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-snowmen.sty index bda3d6fe004..a95bda001cb 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-snowmen.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-snowmen.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-snowmen}[2022/04/21 version v0.9 Draw snowmen in TikZ] +\ProvidesPackage{tikzlings-snowmen}[2022/06/17 version v1.0 Draw snowmen in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -47,15 +47,15 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\snowman@body{#1}, + body/.store in = \snowman@body, body = white!95!black, - eye/.code = \def\snowman@eye{#1}, + eye/.store in = \snowman@eye, eye = black, - nose/.code = \def\snowman@nose{#1}, + nose/.store in = \snowman@nose, nose = orange, - mouth/.code = \def\snowman@mouth{#1}, + mouth/.store in = \snowman@mouth, mouth = black, - buttons/.code = \def\snowman@buttons{#1}, + buttons/.store in = \snowman@buttons, buttons = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-squirrels.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-squirrels.sty index 807bfb0b33c..0852a3fd92b 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-squirrels.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-squirrels.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-squirrels}[2022/04/21 version v0.9 Drawing squirrels in TikZ] +\ProvidesPackage{tikzlings-squirrels}[2022/06/17 version v1.0 Drawing squirrels in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -45,11 +45,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\squirrel@body{#1}, + body/.store in = \squirrel@body, body = brown!40!gray!90!red, - eye/.code = \def\squirrel@eye{#1}, + eye/.store in = \squirrel@eye, eye = white, - pupil/.code = \def\squirrel@pupil{#1}, + pupil/.store in = \squirrel@pupil, pupil = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-wolves.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-wolves.sty index cb12ad10f1c..060e7b21f2e 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings-wolves.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings-wolves.sty @@ -12,7 +12,7 @@ %% See http://www.latex-project.org/lppl.txt %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings-wolves}[2022/04/21 version v0.9 Drawing wolves in TikZ] +\ProvidesPackage{tikzlings-wolves}[2022/06/17 version v1.0 Drawing wolves in TikZ] \RequirePackage{tikz} \RequirePackage{tikzlings-addons} @@ -50,11 +50,11 @@ % body % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - body/.code = \def\wolf@body{#1}, + body/.store in = \wolf@body, body = gray!90!white, - eye/.code = \def\wolf@eye{#1}, + eye/.store in = \wolf@eye, eye = white, - pupil/.code = \def\wolf@pupil{#1}, + pupil/.store in = \wolf@pupil, pupil = black, %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % @@ -211,7 +211,7 @@ %% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %\clearpage -%\section[wolf]{Westy, the wolf} +%\section[Wolf]{Westy, the wolf} % %\emph{The wolf was kindly contributed by @cfroccajr. It is named ``Westy'' for the Western CT State University, whose new mascot is a wolf.} % diff --git a/Master/texmf-dist/tex/latex/tikzlings/tikzlings.sty b/Master/texmf-dist/tex/latex/tikzlings/tikzlings.sty index b454d61c711..ecd7562fb87 100644 --- a/Master/texmf-dist/tex/latex/tikzlings/tikzlings.sty +++ b/Master/texmf-dist/tex/latex/tikzlings/tikzlings.sty @@ -12,7 +12,7 @@ % See http://www.latex-project.org/lppl.txt % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\ProvidesPackage{tikzlings}[2022/04/21 version v0.9 Collection of packages to draw animals and other beings in TikZ] +\ProvidesPackage{tikzlings}[2022/06/17 version v1.0 Collection of packages to draw animals and other beings in TikZ] %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % @@ -28,19 +28,12 @@ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \RequirePackage{tikz} -% from https://chat.stackexchange.com/transcript/message/56515698#56515698 \ExplSyntaxOn -\cs_new_protected:Npn \tikzlings_load_packages:N #1 { - \clist_map_inline:Nn #1 { - \exp_args:Nx \RequirePackage { - tikzlings- \__tikzlings_after_slash:w ##1 / / \s_stop - } - } -} -\cs_new:Npn \__tikzlings_after_slash:w #1 / #2 / #3 \s_stop { \tl_trim_spaces:n {#2} } -\cs_new_eq:NN \tikzling@loadpackages \tikzlings_load_packages:N +\cs_new_eq:NN \tikzlings@clistMapInlineNn \clist_map_inline:Nn \ExplSyntaxOff -\tikzling@loadpackages\tikzling@list + +\tikzlings@clistMapInlineNn{\tikzlings@packages@clist}{% + \RequirePackage{tikzlings-#1}} \RequirePackage{tikzlings-addons} @@ -65,31 +58,44 @@ \pgfmathsetseed{\number\pdfrandomseed} \fi -% from https://chat.stackexchange.com/transcript/message/56516469#56516469 -% To be able to x-expand \iterateTikzlings, it has to be expandable, so no 'protected'. Also \clist_map_inline:Nn is not expandable, so we have to use \clist_map_function:NN instead. -\cs_new:Npn \tikzlings_iterate:N #1 { - \clist_map_function:NN #1 \__tikzlings_braced_items:n -} -% \__tikzlings_braced_items:n will receive each clist item, then: -\cs_new:Npn \__tikzlings_braced_items:n #1 { - { % leave an open brace - % we don't want the x-expansion to expand the tikzling command, so we prevent expansion with \exp_not:c. The 'c' variant is used so it builds a csname from its argument, before preventing the expansion: and the argument is what's before the '/' - \exp_not:c { - \__tikzlings_before_slash:w #1 / \s_stop +% #1: tikzling name. +% The second argument of \__tikzlings_show_tikzling:nn will be provided +% by \tikzling. +\cs_new:Npn \__tikzlings_brace_item:n #1 + { { \__tikzlings_show_tikzling:nn {#1} } } + +% #1: tikzling name +% #2: options passed to its command +\cs_new_protected:Npn \__tikzlings_show_tikzling:nn #1#2 + { + \group_begin: + \pgfkeys + { + /#1/.search~also/.expanded = + { /tikz, /pgf, /thing, \tikzlings@search@paths@clist } + } + \use:c {#1} [{#2}] + \group_end: } - } % leave a close brace -} -\cs_new:Npn \__tikzlings_before_slash:w #1 / #2 \s_stop { - \tl_trim_spaces:n {#1} % make sure there are no spaces around the string -} -\cs_new_eq:NN \tikzling@iteraterandom \tikzlings_iterate:N -\cs_new_eq:NN \ExpArgsNnx \exp_args:Nnx -\ExplSyntaxOff +\cs_new_protected:Npn \__tikzlings_declare_pgfmath_random_list:n #1 + { + \pgfmathdeclarerandomlist { tikzlings } {#1} + } -\ExpArgsNnx\pgfmathdeclarerandomlist{tikzlings}{\tikzling@iteraterandom\tikzling@list} +% Variant that uses \edef on the argument, then passes the result to +% \__tikzlings_declare_pgfmath_random_list:n +\cs_generate_variant:Nn \__tikzlings_declare_pgfmath_random_list:n { x } + +% Works because \clist_map_function:NN is expandable +\__tikzlings_declare_pgfmath_random_list:x + { + \clist_map_function:NN \g__tikzlings_names_clist \__tikzlings_brace_item:n + } +\ExplSyntaxOff \newcommand{\tikzling}[1][]{% - \pgfmathrandomitem{\tikzling@random}{tikzlings}% - \tikzling@random[#1] + \pgfmathrandomitem{\tikzlings@random}{tikzlings}% + % #1 is passed as second argument to \__tikzlings_show_tikzling:nn + \tikzlings@random{#1}% } |