Book logo xindy

A Flexible Indexing System

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: define location rule used for Xindy online manual

	Hello Tim,

sorry for my late response

Tim Arnold writes:
 > Hi
 > I want to create an online doc index using Xindy,
 > and of course, I need to define a location class
 > that can accept a URL.
 > I understand how to do that for a standard format
 > of a URL, but I need to be able to handle urls of
 > arbitrary length.
 > My question for the group is:
 > Where are the *.xdy file(s) that were used to create
 > the index of the Xindy manual (e.g. manual-6.html, in the
 > most recent distibution)?

This index is the result of hand-weaving the index and it has not been
processed by xindy. Sorry for that. 

Actually the problem you mention is not trivial to solve per se. I
don't know how deep you have digged into xindy but one of its
assumptions about the ordering of location references is that you can
represent a location reference for ordering purposes as a pair of
(type, vector of integer). The order of types is specified with the
DEFINE-LOCATION-CLASS-ORDER primitive. The order of integer values is
used to sort the references lexicographically, e.g. (1 2) < (2) < (3
1) < (3 2), etc. Unfortunately this is hard-wired into the internals
of xindy and one should stick to that to avoid rewriting parts of it.

Each of the numbers in this vector is derived from the so-called
basetypes, e.g. basetype "Roman" gives you '1000' for a 'M'. The
problem is that a basetype is only allowed to result in a single
number whereas in the URL example one actually needs a whole vector of
numbers as response.

Ex. Sum.: Currently this does not work!

I have some lines of code that could be used to circumvent this
problem. Unfortunately this requires to re-dump xindy and I currently
have not all the missing pieces together. If you are able to do that I
can send you some information on how to apply these patches to do some

Cheers, Roger

Roger Kehr
Computer Science Department         Darmstadt University of Technology