You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by Ross Gardler <ro...@saafe.org> on 2002/11/17 17:21:03 UTC
Creating cross references in generated docs
I am currently using Forrest to work on a publishable document as in
published in a book. This has required me to make a few changes to the
skins to do things like number figures and tables and other such minor
changes.
However, a more major change is creating cross-references in the text.
For example:
"The foo is illustrated in Figure 2."
I have done this by utilising the "role" attribute of the link element,
e.g.:
<p>The foo is illustrated in <link href="#foo" role="xref"/></p>
When this is rendered by the stylesheet it detects what type of element
has the id attribute value of "foo" and displays "Figure" or "Table"
accordingly.
This prompts two questions:
1) Is this a correct usage of the role attribute? If not how would you
suggest going about this?
2) Do you want the patch files for the forrest skin, or perhaps this is
too specialist for the default?
Ross