diff options
Diffstat (limited to 'Master/texmf-dist/doc/latex/base/usrguide3.tex')
-rw-r--r-- | Master/texmf-dist/doc/latex/base/usrguide3.tex | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/Master/texmf-dist/doc/latex/base/usrguide3.tex b/Master/texmf-dist/doc/latex/base/usrguide3.tex index c378ac85928..82c1c068630 100644 --- a/Master/texmf-dist/doc/latex/base/usrguide3.tex +++ b/Master/texmf-dist/doc/latex/base/usrguide3.tex @@ -36,7 +36,7 @@ \author{\copyright~Copyright 2020-2021, \LaTeX\ Project Team.\\ All rights reserved.} -\date{2021-04-12} +\date{2021-06-11} \NewDocumentCommand\cs{m}{\texttt{\textbackslash\detokenize{#1}}} \NewDocumentCommand\marg{m}{\arg{#1}} @@ -235,9 +235,9 @@ defined. \end{decl} These commands work in the same way as \cs{NewDocumentCommand}, etc.\@, but create environments (\cs{begin}\arg{env} \ldots{} -\cs{end}\arg{environment}). Both the \meta{beg-code} and \meta{end-code} +\cs{end}\arg{env}). Both the \meta{beg-code} and \meta{end-code} may access the arguments as defined by \meta{arg spec}. The arguments will be -given following \cs{begin}\arg{environment}. +given following \cs{begin}\arg{env}. \subsection{Optional arguments} \label{sec:cmd:opt} @@ -302,7 +302,7 @@ argument specification: \end{verbatim} where \verb*|\foobar{arg1} [arg2]| will not find an optional argument. -There is one subtly here due to the difference in handling by \TeX{} of +There is one subtlety here due to the difference in handling by \TeX{} of `control symbols', where the command name is made up of a single character, such as `\texttt{\textbackslash\textbackslash}'. Spaces are not ignored by \TeX{} here, @@ -454,6 +454,18 @@ category code $13$ (active) character matching the \meta{token} will be replaced before the split takes place. Spaces are trimmed at each end of each item parsed. +The \texttt{E} argument type is somewhat special, because with a single +\texttt{E} in the command declaration you may end up with several +arguments in a command (one formal argument per embellishment token). +Therefore, when an argument processor is applied to an \texttt{E}-type +argument, all the arguments pass through that processor before being fed +to the \meta{code}. For example, this command +\begin{verbatim} + \NewDocumentCommand \foo { >{\TrimSpaces} e{_^} } + { [#1](#2) } +\end{verbatim} +applies \cs{TrimSpaces} to both arguments. + \begin{decl} |\SplitList| \arg{token(s)} \end{decl} |