New answers tagged

0

The following code defines and illustrates a macro \images{}. \images takes one mandatory argument which should be a key-value list of options. The minimum sensible list sets the key images to a list of one or more image files. I've defined this as a macro but it could be easily defined using \NewDocumentEnvironment{images}{m} ... instead, or used within ...


2

Here's expl3 using a \seq variable and splitting the content of the \commandkey{im} macro into sequence items, then looping over those items using a map function, say \loopfunction Basically any loop macro that can split the comma separated value list would do of course. From the documentation of keycommand it's apparent, that this packages uses etoolbox, ...


3

Here is a solution \documentclass{article} \usepackage{lipsum} \newcommand*\editorialtable{% \beforeeditorialtable \begin{tabular}{|l|l|l|l|} \hline \multicolumn{1}{|c}{Section} & \multicolumn{1}{|c}{Subsection} & \multicolumn{1}{|c}{Responsible}&\multicolumn{1}{|c|}{Helpers}\\ \hline \makeeditorialtable \end{tabular} \aftereditorialtable} ...


2

See the updated and better version at the end, please! A preliminary version with expl3 features and key-value interface, only working for a table at the end at the moment! \documentclass{article} \usepackage{xparse} \usepackage{xkeyval} \makeatletter \let\latex@@section\section \let\latex@@subsection\subsection \define@key{editorial}{helper}{% ...


4

If I understand correctly than you looking for one of the following results: or Both images are generated by: \documentclass[border=3mm, multi, tikz]{standalone} \begin{document} \begin{tikzpicture}[ vrtx/.style = {circle, draw, fill=gray!30, inner sep=2pt} ] \coordinate (i) at (0,0); \coordinate ...


0

If you don't mind an additional package, pgffor is quite handy to provide foreach-loops. \documentclass{article} \usepackage{graphicx} \usepackage{pgffor} \begin{document} test \foreach \n in {1,...,2}{ \ifnum\n=2% \includegraphics{pic}% \fi% } \end{document}


2

Something like this? \documentclass{article} \begin{document} \newcount\group \newcount\subj \newcount\nors \group=0 \loop \advance\group by 1 \subj=0 {\loop \advance\subj by 1 \nors=0 {\loop \advance\nors by 1 { group \the\group, subject \the\subj, run \the\nors \par \ifnum\group=2 ...



Top 50 recent answers are included