Werner Hennrich schrieb am 12.02.2021 um 08:26:
Hello everyone,
please can you give me pointers on how to easiest parse multi-valued
\dummyparameter{...} like in
\something[...,weather={sunshine, rain, hail},...]
so that I can test for e.g. rain, sunshine, wind, hail, mist, fog,
storm etc, each if it is present or not?
...so I can keep my number of parameters down and my parameter list as
simple as possible.
I have no idea what to search for in the docs or (better) in the test
cases / samples.
Would be great if you could just let me know where to look or what to
sarch for
\starttext
\def\something[#1]%
{\getdummyparameters[weather=,#1]%
\processallactionsinset
[\dummyparameter{weather}]
[sunshine=>Sunshine\endgraf,
rain=>Rain\endgraf,
hail=>Hail\endgraf]}
\something[weather=sunshine]
\blank
\something[weather={sunshine,rain}]
\stoptext
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the
Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________