OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

docbook message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: [docbook] Indexterm in glossterm causes validationexception when using glossseealso

Yes, this is a bug. A glossseealso is handled as a cross reference, and the targets of any cross reference should be processed in mode="no.anchor.mode". That mode prevents the inclusion in the link text of nested links and indexterms. Since that mode is not currently used for glossseealso, the link text includes a duplicate marker for the indexterm included in the glossterm. The fix is easy, but could someone please file a bug report on Sourceforge so this can be tracked. Thanks.

Bob Stayton
Sagehill Enterprises

On 1/30/2015 3:48 PM, Richard Hamilton wrote:
You're correct that this is valid DocBook, and I can confirm that you do get a duplicate id, which means it looks like there's a bug in the stylesheets.

BTW, I see the same thing using the XEP extensions, though RenderX actually doesn't detect the error (or at least doesn't report it) and (almost) correctly processes the .fo, even with the duplicate id. I say almost because a printed PDF will be correct, but an online PDF may link the index entry to the wrong instance of the id.

In the short term, I'd suggest moving the indexterm out of the glossterm. It's still valid, and should give you a good index.

I'm going to post this to the docbook-apps list so the folks who maintain the stylesheets can look at this more closely. I got lost in the depths of some pretty complex code, and (frankly:) ran out of time. If no one else looks at it, I'll come back and dig in deeper in a few weeks.

Best regards,
Dick Hamilton
XML Press
XML for Technical Communicators

On Jan 30, 2015, at 1:31, M F <dark.rider85@yahoo.de> wrote:

I am using xsltproc (libxml 20902, libxslt 10128) and I have the following glossary for testing purposes. Note the <glossterm>-tags have <indexterm>-tags each and there is also one <glossseealso>-tag.

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE glossary PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"

<glossary id="glossar">

     <!-- ................... E ................... -->
     <glossdiv id="gloss_E">
         <glossentry id="gloss_e-file">
             <glossterm id="glossterm_e-file">
                 <emphasis role="bold">E-File</emphasis>
                 <glossseealso otherterm="gloss_test">EinTest</glossseealso>

         <glossentry id="gloss_test">
             <glossterm id="gt_gloss_test">
                 <emphasis role="bold">EinTest</emphasis>


When I try to generate a pdf file using apache fop (version 1.1), I will get a ValidationException:
org.apache.fop.fo.ValidationException: Property ID "idp8750595088" (found on "fo:wrapper") previously used; ID values must be unique within a document!

It is because of the <glossseealso>-tag. When resolved, a fo:wrapper-element is created with the same ID as the gloss_test.

Now, if I move the <indexterm>-tag out of the <glossterm>-tag, it works just fine.
I wonder if this is a bug or just a wrong use of the <indexterm>-tag. According to the DTD the <indexterm>-tag is an allowed child of <glossterm>.

Thanks in advance!

Best regards,

To unsubscribe, e-mail: docbook-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: docbook-help@lists.oasis-open.org

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]