Re: [NTG-context] Structuring topics
Thank you, Wolfgang. I'll try to get into my tomorrow's clean head and wikify it. )
What's the problem with my answer, i described differences between \def and \define and the most important one is point one, i'll show it to you in two examples
1. \def
\starttext \def\hans{hans} \def\hans{taco} \hans \stoptext
the output of this example is 'taco' because the second \def statement overides the first
2. \define
\starttext \define\hans{hans} \define\hans{taco} \stoptext
the output now is 'hans' because \define checks whether a command with the name \hans is already defined, if this isn't true \hans is created with the content 'hans' while in the second \define \hans is already available and nothing happens but you get a warning on the terminal
system : command \hans is already defined
to summary this you can say \def is for developers and \define for users but this won't work in all cases because \define can't create commands with optional arguments :(
Wolfgang
-- Best Regards, Vyatcheslav Yatskovsky
participants (1)
-
Vyatcheslav Yatskovsky