From: Alexander Peshkov (peshkov@renderx.com)
Date: Tue May 25 2004 - 03:44:28 PDT
Hello Henrik,
If I understood you correctly, you want consequent words which start
with the same syllables to be represented by their common part in the
dictionary running header. You can achieve this using markers, but
you'll have to do some work in XSLT. I'll outline one possible
approach below.
I suppose your data consists of term-description pairs. Note that you
have to decide which number of starting letters in consequent terms
should be common in order for them to be groped together under the
same prefix. Let it be 4 letters as in your example.
First of all in XSLT stylesheet you will create an index (using
xsl:key) of terms based on their four starting letters. Then you will
iterate over this index with xsl:for-each (order items in alphabetical
order using xsl:sort). Inside this cycle you will perform two main steps:
1) Define variable with marker value: if current item correspond to
the single term the whole term will be used as marker value, if
there are several terms share the same prefix, then this prefix
will be used as marker content.
2) Apply templates for every term-description pair (don't forget to
order terms with common prefix alphabetically) passing to handler
template the variable with marker value.
Inside 'term' template you will wrap term into fo:block with fo:marker
that has value passed in as a parameter. Note that term description
should be *outside* of this marker and fo:retrieve-marker should have
retrieve-position="first-starting-within-page".
I believe that this method will allow you to achieve desired result.
The only limitation I can see is that you have to fix number of common
letters, however this restriction is quite reasonable.
Hope this helps.
Best regards,
Alexander Peshkov mailto:peshkov@renderx.com
RenderX
HR> I'm using retrieve-marker for the the running heads for prossing a dictonary.
HR> The top left header should be the keyword of the first entry starting on the page. So far so good.
HR> But when more entries on the pages start with the same phrase, the received marker will be truncated.
HR> I.e.:
HR> the two first entries keywords are:
HR> decibel
HR> decimeter
HR> the running header ends up with 'deci-' and not 'decibel'
HR> How do I overrule this behaviour?
HR> --Henrik
HR> -------------------
HR> (*) To unsubscribe, send a message with words 'unsubscribe xep-support'
HR> in the body of the message to majordomo@renderx.com from the address
HR> you are subscribed from.
HR> (*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/tos.html
-------------------
(*) To unsubscribe, send a message with words 'unsubscribe xep-support'
in the body of the message to majordomo@renderx.com from the address
you are subscribed from.
(*) By using the Service, you expressly agree to these Terms of Service http://www.renderx.com/tos.html
This archive was generated by hypermail 2.1.5 : Tue May 25 2004 - 03:56:42 PDT