Thank you Peter! Just wondering... Looking at the files s-mg-01.tex and mag-0000.tex from the context distribution, there is a different approach. Here I find \usemodule. What are the differences? And, when use with? Or is it just a metter of taste? Boris.
From: Peter Rolf
Reply-To: mailing list for ConTeXt users To: mailing list for ConTeXt users Subject: Re: [NTG-context] using 1 layout on several documents Date: Fri, 30 Sep 2005 13:46:45 +0200 Hi Boris,
Boris Pedrofiets wrote:
Hi,
I made a layout that I want to use for several documents. What is the best way to handle this, without placing a copy of the layout description in every file?
Simply use an environment (file).
Something like...
[content of file 'env-mylayout.tex'] -------- \startenvironment env-mylayout
....your layout settings....
\stopenvironment --------
Then put the file somewhere in the tex-path (??/texmf/texmf-local/tex/context/user/ is a good place) and call texhash/mktexlsr(!), so that context can find it;
Now you can use your layout settings by just typing
\environment env-mylayout
at the beginning of your document (before \starttext).
If the environment is not already defined, then context tries to load a file with the same name as the environment name (environment foo --> foo.tex). I just use the prefix 'env-' to seperate the env. files from the rest in this folder (typescripts, modules, ...).
Hope that helps,
Peter
Thanks for helping!
Boris
_________________________________________________________________ Vind alles terug op je PC: MSN Search Toolbar http://toolbar.msn.nl/
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
_______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context
_________________________________________________________________ Nieuw op MSN Messenger 7.5: Dynamische achtergronden http://www1.imagine-msn.com/Messenger/Audio.aspx