On Mon, 21 Jul 2008, Joachim Kreimer-de Fries wrote:
Goden Dag, although my primary field of ConTeXt questions is marginal notes, I use to read the "footnote" threads on NTG-context with curiousness as well .
Am 20.07.2008 um 19:50 schrieb Aditya Mahajan:
When the manual is inadequate, I look at the sources.
=> Which sorces, wich directory and kind of files are meant, if one says "look at the source", where do I find them? (On my TeX-life distribution on Mac OSX 10.4x Tiger with actualized ConTeXt I didn't find the later mentioned "core-not.tex")
I do not know how the file explorer in Mac works. And I do not know where a typical installation installs context in Mac. Suppose it is installed in /usr/local/texlive/2007. The all the context files will be in /usr/local/texlive/2007/texmf-dist/tex/context/base Basically, INSTALL-LOCATION/texmf or INTSTALL-LOCATION/texmf-dist or INSTALL-LOCATION/texmf-context and then tex/context/base directory inside it.
Once you figure out how to scan them for information,
=> Could one comunicate "how to scan them for infomation" or must that stay a secret?
The basic idea is to first understand how a particular command is defined. Here is what I do: go to tex/context/base directory and search (by any means, I use grep, but you can as well use any program that allows you to search inside files) for the command you are looking for: in this case footnote. You may either get a huge number of results, or a few results. If you get a few results, check them manually, to see which file defines a command. A command is usually defined as \def\commandname or (rarely) \edef\commandname \xdef\commandname \gdef\commandname or (more frequently) \define<something>[\v!commandname] here <something> can be any text. If your search gives a lot of results, you need to use a regular expression to filter it to one of the above. I don't know if Finder in Mac allows for regular expressions.
they are easy to understand. [I repeat: "easy to understand"!]
I know what you mean here :)
In this case, core-not.tex says that the options of \setupfootnotes are
[\c!location=\v!page, \c!way=\v!by\v!part, \c!sectionnumber=\v!no, \c!conversion=, \c!rule=\v!on, [etc. and so on...]
Nothing of this and the following code lines I can understand, so it is not "easy" - albeit that one knows the syntax and meanings of these commands.
As far as syntax goes, just ignore those funny \c! \v! thingies. Then you can read them as [location=page, way=bypart, sectionnumber=no, conversion=, rule=on, [etc..] These mean, that i) Footnotes should be located per page. ii) They should be numbered per part. That is, if you start a new part, footnote numbering restarts. iii) I don't know what sectionnumber does, so I ignore it. iv) The number should not be converted to anything. You can convert them to characters, Characters, romannumerals, Romannumberals, etc. v) The footnotes should be proceeded by a rule, etc. You see, most of the keys for all environments take command key-value options. If they are explained in the manual, then great; if they are not, start guessing what they mean, and experiment if you get the right result. Try three times, and if you don't get hit the right answer, ask on the mailing list. Hopefully, someone will reply. Then you know, what a particular option does for *all environments*. If you don't get an answer, well... then ask what you want to achieve, and hopefully someone will tell you if it is possible or not.
=> Where can I find an explanation of this, not to write this kind of code myself but to understand off it, which kind of commands I can use with footnotes (in this case)?
I explained above how I started to understand these things. I am sure that other people have different approaches. I do not understand how TeX works, but reading ConTeXt sources are much easier than reading latex sources. I started with LaTeX, and in LaTeX I could never manage to understand 80% of the what was written in the sources. In ConTeXt, I can understand 50-60%, that is what I meant my "easy". Aditya