Ask question asked 13 years, 8 months ago modified 3 years, 10 months ago I would define a global if clause which setup the color. The \\newcommand macro allows to use an optional argument for the first parameter #1 with:
4 we know that we could define a new command for boldfaced or calligraphic c, for example i can define \newcommand{\cx}{\mathbb{c}}, which will produce the boldfaced c, i.e. Now when we pass the same arguments to this command it's as if we typed {\bfseries cba} in our document, which is what we want. It contains a nested command definition for parameters extension.
Instead of using \newcommand{\targetorg} i would define a command \targetorg, which uses the organisation, e.g.: The difference between \jeroen_add:nn and \jeroen_add:vv is that the. Here's how one can define a simple function and an environment. Note it is declared using \neworrenewcommand, which defines a command if not defined, or redefine.
In latex, one can declare functions in documents using the \\newcommand or \\newenvironment commands. A command defined using \def has to know exactly what its options are, and how they will be presented to it. 9 an interesting example of how one can define commands with different syntax, but doing the same thing, with minumum effort. However, a tex command can be a bit clever and examine things other than its arguments.
Now suppose we want our command to have an optional. 9 first, we define the command \foo. Rather than a simple \colorlet{newcolor}{existingcolor}, which will allow a new color to be defined in terms of existing color (s) (see shades of colors, defining a color using another), it seems.