Am 2014-08-28 um 23:39 schrieb Hans Hagen
I just recognized there’s a problem with references, esp. register:
.... <section detail="Titel" location="aut:2"> <sectiontitle>Erinnerung </sectiontitle> .... <registerentry>Erinnerung</registerentry> <registerpages> <break/> <registerpage><link destination="internal(3)" location="aut:3">4</link></registerpage></registerpages> .... <registerentry>Vor meinem inn’ren Auge schweben Namen</registerentry> <registerpages> <break/> <registerpage><link destination="internal(4)" location="aut:4">4</link></registerpage></registerpages>
(These are title and start of lyrics of a song.)
Beside the inconvenience that there is no node wrapping registerentry and registerpages, the locations don’t match. If there are several index entries pointing to the same point (page), as here, they’re continuously numbered, so that it’s no solution to just subtract 1, as I do at the moment to create my ToC.
new beta
\setupbackend [export=yes, xhtml=yes, css=export-example.css]
\starttext
\index{foo}foo \page \index{bar}bar \page \index{foo}foo \page \index{bar}bar \page \index{foo+test}foo \page \index{bar+test}bar \page
\placeregister[index]
\stoptext
gives:
<register detail="index"> <registersection> <registertag>b</registertag> <registerentries> <registerentry> <registercontent>bar</registercontent> <registerpages><registerpage>2</registerpage><registerseparator>,</registerseparator><registerpage>4</registerpage></registerpages> </registerentry> <registerentries> <registerentry> <registercontent>test</registercontent> <registerpages><registerpage>6</registerpage></registerpages> </registerentry> </registerentries> </registerentries> </registersection> <registersection> <registertag>f</registertag> <registerentries> <registerentry> <registercontent>foo</registercontent> <registerpages><registerpage>1</registerpage><registerseparator>,</registerseparator><registerpage>3</registerpage></registerpages> </registerentry> <registerentries> <registerentry> <registercontent>test</registercontent> <registerpages><registerpage>5</registerpage></registerpages> </registerentry> </registerentries> </registerentries> </registersection> </register>
Maybe the internal location numbers mean something, but I need a working reference; export.xml doesn’t know anything about pages, therefore the destination makes no sense. Doesn’t ConTeXt have some unique internal reference name?
Thank you for caring, the tag hierarchy is good now, but why did you leave out the locations now? I need some connection between register entry and the origin to be able to create a link. I can’t use the page numbers, since they don’t exist in the XML (and of course they make no sense there). Greetlings, Hraban --- http://www.fiee.net/texnique/ http://wiki.contextgarden.net https://www.cacert.org (I'm an assurer)