On 04 Mar 2009, at 19:39, Andreas Delmelle wrote:

FWIW:

On 04 Mar 2009, at 14:56, Georg Datterl wrote:
<snip />
I once started gathering some thoughts on the topic, but didn't get very far...
See: http://wiki.apache.org/xmlgraphics-fop/FormattingObjectsForIndexing

Re-reading this and the original question:
If we would have fo:index-page-citation-list, fo:index-key-reference and the index-key/ref-index-key property pair, the solution would be fairly simple. Adapt the stylesheet to append the node's id to the index-key attribute, so that we get an index-key that maps 1-on-1 to the id. A basic index-page-citation-list is all that is needed to produce sequences without duplicates. Merging sequential page-numbers is already a nice-to-have. By itself, once the basic mechanism proves to be working, this should become easy. The priority after basic implementation (2 objects + 2 properties) should probably go to implementing different separator-sequences. (NTS: may need to adapt that order on the Wiki). I consider it to be on the same level as index-ranges in terms of complexity, but different separators suddenly look more useful...

By itself, the implementation of the 'index-key' property is not that difficult. It is its treatment further on during layout/ rendering that will be a challenge.

As Jeremias hinted, especially layout/rendering.
We will get a LayoutManager whose content can be partly or entirely unresolved (like the PageNumberCitationLM), and can grow significantly in case of large documents. Sometimes reaching one or more lines. This could mean that the layout for all the following pages may need to be revisited, which is something FOP is currently not equipped to do...

It would be easy enough to have such a LayoutManager merge a sequence of citations into one, keeping track of and eliminating duplicates, but the possible side-effects of a mix of resolved and unresolved elements, without somehow redoing the layout, cannot be so easily avoided in the current design.


Regards

Andreas

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to