On Thu, 10 Aug 2006, Steffen Wolfrum wrote:
Hi,
in XML and alike there is a concept of dedicated start/stop in formatting:
<begin heading> ... <end heading > <begin footnote> ... <end footnote > <begin italic> ... <end italic>
But in ConTeXt/TeX we have always the same closing syntax "}". That makes reading the code not easier.
You can always define your own startstop. \definestartstop[italic][before={\bgroup \it},after={\egroup}] and then do \startitalic This is italic \stopitalic When a command takes an optional agrument, you can do use something like this \def\startfootnote% {\unskip\dosingleempty\dostartfootnote} \def\dostartfootnote[#1]#2\stopfootnote% {\footnote[#1]{#2}} You can make such definitions of all your frequently used environments (or, if you prefer, write in XML and let ConTeXt handle XML).
Is there a workaround to define the closing more precisely (like the examples above), so that finding a "}" in a ConTeXt source lets me distinguish what it's about?
There are \bgroup...\egroup which is same as {...} for all practical purposes. Aditya