![](https://secure.gravatar.com/avatar/cedc4d83943006afe3994fb0a0455f82.jpg?s=120&d=mm&r=g)
Hello, is there something in ConTeXt like the \AtBeginDocument in LaTeX ? Peter -- http://pmrb.free.fr/contact/ _____________________________________ FilmSearch engine: http://f-s.sf.net/
![](https://secure.gravatar.com/avatar/cedc4d83943006afe3994fb0a0455f82.jpg?s=120&d=mm&r=g)
On Fri, 11 Jun 2004, Hans Hagen wrote:
Peter Münster wrote:
Hello,
is there something in ConTeXt like the \AtBeginDocument in LaTeX ?
\appendtoks something \to \everystarttext
could work
In fact, I'm looking for something, that also works for startproduct. Seems to work only for starttext. Perhaps, I could do something like this: \let\startproductO=\startproduct \def\startproduct{something\startproductO} ? Peter P.S.: Unfortunately, it is quite hard to browse the core-*.tex files, because of the mix of 2 languages... Are the non-english user-interfaces really used? -- http://pmrb.free.fr/contact/ _____________________________________ FilmSearch engine: http://f-s.sf.net/
![](https://secure.gravatar.com/avatar/49e63acb01f2ca80efce7eed08310ce8.jpg?s=120&d=mm&r=g)
Peter Münster wrote:
\let\startproductO=\startproduct \def\startproduct{something\startproductO} ?
hm, starttext is called anyway so it should work with product as well you code is wrong, think about something (untested): \let\petermunstersstartproduct\startproduct \def\startproduct{something\let\startproduct\petermunstersstartproduct\startproduct}
Peter
P.S.: Unfortunately, it is quite hard to browse the core-*.tex files, because of the mix of 2 languages... Are the non-english user-interfaces really used?
sure, i use it, esp for dutch books (styles) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
![](https://secure.gravatar.com/avatar/cedc4d83943006afe3994fb0a0455f82.jpg?s=120&d=mm&r=g)
On Sun, 13 Jun 2004, Hans Hagen Outside wrote:
hm, starttext is called anyway so it should work with product as well
Indeed, I saw this in the definition of \startproduct. Now I know, why it does not work here: in my example (see below), \startproduct is called before the environment is read in. file env.tex: \startenvironment env \appendtoks\def\TestIt{test}\to\everystarttext \stopenvironment file proj.tex: \startproject proj \environment env \product prod \stopproject file prod.tex: \startproduct prod \project proj Test it: \TestIt \stopproduct Doesn't matter, I'll find other solutions for my purposes.
P.S.: Unfortunately, it is quite hard to browse the core-*.tex files, because of the mix of 2 languages... Are the non-english user-interfaces really used?
sure, i use it, esp for dutch books (styles)
Excuse me, in fact it was a silly question. Cheers, Peter -- http://pmrb.free.fr/contact/ _____________________________________ FilmSearch engine: http://f-s.sf.net/
![](https://secure.gravatar.com/avatar/49e63acb01f2ca80efce7eed08310ce8.jpg?s=120&d=mm&r=g)
Patrick Gundlach wrote:
Hello Peter,
is there something in ConTeXt like the \AtBeginDocument in LaTeX ?
does \appendtoks{Hello} \to \everystarttext
do what you need?
beware: in your example grouple is applied as well as a space added after the } Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (4)
-
Hans Hagen
-
Hans Hagen Outside
-
Patrick Gundlach
-
Peter Münster