Thomas Meyer schrieb am 03.10.2024 um 10:59:
Thank you very much, Wolfgang,
that helps me a lot.
But how can I change the formatting
{“weekday,space,day,space,month,space,year”}
so that I get a comma after weekday and a period after day? Where can I
find something about this?
Aside from keywords like day, weekday etc. the \date (and \currentdate)
commands allows free input which used as separator between these
keywords. To set a period as separator just put . as entry in the list
but ensure to use braces around , because it will otherwise be
interpreted as list separator.
When you use TeX command within Lua use double backslashes (\\) because
a backslash has special meaning here and with \\ you tell Lua to put a
single \ in the output.
%%%% begin example
\starttext
\currentdate[weekday,{, },day,. ,month,space,year]
%\currentdate[weekday,{, },day,.\ ,month,space,year]
\currentdate[weekday,\textcomma\ ,day,\textperiod\ ,month,space,year]
\startluacode
context.currentdate{ "weekday,{, },day,. ,month,space,year" }
\stopluacode
\startluacode
context.currentdate{ "weekday,\\textcomma\\ ,day,\\textperiod\\
,month,space,year" }
\stopluacode
\stoptext
%%%% end example
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the
Wiki!
maillist : ntg-context@ntg.nl /
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___________________________________________________________________________________