What is the (preferred way of) defining a command that
- places a heading (like \section, \chapter, etc.)
- creates a label for this heading that can be referenced
- places the heading in the TOC (I think the TOC part is pretty automatic, yes?)
- places the heading in the index
and what is the (preferred way of) defining a referencing command that
- places a reference to the heading with the name of the heading and it's page number
- makes this reference a Link when generating a PDF
- maybe some options on how the referencing should be spelled out
and what packages are needed for this?
Example:
\headx[label1]{This is a heading}
...
\headxx[label12}]{Some sub-heading}
...
...
For further details, see \headreference[style=short]{label1}.
...
(edit) Note: [style=...] could control what details are inserted. E.g. short could mean to only insert the section name as link (and skip the section number and page). Fullcould mean to also insert section number and page as text for the link. (This is just an example to show that I think that such a command should probably have some fine-tuning switches.)
[style=short]supposed to do? – TH. Sep 20 '10 at 19:29