On 8/14/2025 6:48 PM, Thomas A. Schmitz wrote:
Your approach below looks promising, but when I try to wrap my xmlsetups
in a \startsetups ... \stopsetups pair, I get this error:
! The file ended when scanning an argument.
tex error > tex error on line 37 in file ./test.tex:
\ignorearguments \popmacro \commalistcommand \xmlprocessfile
{rezeptionssetups} {aristophanes.xml} {}\xmlprocessfile
{rezeptionssetups} {cicero.xml} {}\xmlprocessfile {rezeptionssetups}
{spaetantike.xml} {}\stop \stoptext
<line 3.37>
\stoptext
Example:
\startsetups rezeption:body
\xmlsetsetup{#1}{*}{-}
\xmlsetsetup{#1}{document|
index}{xml:*}
\stopxmlsetups
^^^ you stop something you don't start .. check the symmetry of start stop
wrt multiple setups:
you can load all kind of xml files using explicit namespaces so, not #1
but {one} {two} etc an when you then need something you just access it
explicitly, so no #1 but {two} ; you can mix and match any way you like
the #1 approach is just a generic one
when your main one is {main} you can also use that anywhere, so in the
middle of some setup (say one that does a chapter title) you can just
access something {main} which is then the root of the same document
\xmlregistersetup{xml:rezeptionsetups}
\startxmlsetups xml:document
\xmlflush{#1}
\stopxmlsetups
\stopsetups
The solution with \placelist[footnote][criterium=text] does not work for
me, I will have to parse the tuc file in my code. So my question is
still: how can I delete/reset/overwrite/deregister an xml setup?
All best
Thomas
On 8/13/25 21:49, Denis Maier via ntg-context wrote:
I'm not sure you need this. I've recently had a project where I've
processed a single source XML multiple times. Each environment
contains a set of xmlsetups that work for the relevant node.
\environment layout
\environment bits-inkunabeln
\environment bits-einleitung
\environment bits-register
\environment bits-ack
\environment bits-biblio
\environment bits-glossary
\starttext
% INTRODUCTION
\begingroup
\setups{einleitung}
\xmlprocessfile{bits-einleitung}{bits.xml}{}
\endgroup
% ACKNOWLEDGEMENTS
\begingroup
\setups{einleitung}
\xmlprocessfile{bits-ack}{bits.xml}{}
\endgroup
% ABBREVIATIONS
\begingroup
\xmlprocessfile{bits-glossary}{bits.xml}{}
\endgroup
% BIBLIOGRAPHY
\begingroup
\xmlprocessfile{bits-biblio}{bits.xml}{}
\endgroup
% MONGOLICA
\begingroup
\xmlprocessfile{bits-inkunabeln}{bits.xml}{}
\endgroup
% INDEX
\begingroup
\setups{register}
\xmlprocessfile{bits-index}{bits.xml}{}
\endgroup
\stoptext
___________________________________________________________________________________
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
___________________________________________________________________________________
--
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
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
___________________________________________________________________________________