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] Putting <xref> inside <type>

I cannot give you the reason why the content model of <type> does not
include xref. But I can give you a way to accomplish what you want.

The DocBook DTD includes many empty parameter entities set up to extend the
content models.  These placeholders all start with 'local' in the name of
the parameter entity. In this case, the <type> element's content model uses
the &smallcptr.char.mix; parameter entity, whose declaration includes an
empty %local.smallcptr.char.mix; parameter entity.  So you can extend the
content model as follows in the internal DTD subset as follows:

<!DOCTYPE book PUBLIC public-id system-id  [
<!ENTITY % local.smallcptr.char.mix "|xref">

The "|" means "or" in DTD syntax, so this will extend the content model of
all elements that use the smallcptr.char.mix parameter entity to include

Bob Stayton
Sagehill Enterprises
DocBook Consulting

----- Original Message ----- 
From: "Michael A Nachbaur" <mike@nachbaur.com>
To: <docbook@lists.oasis-open.org>
Sent: Saturday, April 24, 2004 11:13 AM
Subject: [docbook] Putting <xref> inside <type>

> I'm documenting an object-oriented class structure, and would like to
> use cross-references whenever possible, mainly to save me from
> copy-and-pasting everything, but also so the rendered output is
> clickable.  However, when I describe a method with:
> <methodsynopsis>
>     <type><xref linkend="part2.Array"/></type>
>     <methodname>Array</methodname>
>     <methodparam choice="opt" rep="repeat">
>         <parameter>item</parameter>
>     </methodparam>
> </methodsynopsis>
> my validating parser complains about the <xref/> element.  Is there a
> reason why I can't put a cross-reference inside a <type>?  If  I can't
> do this, is there some other way I can accomplish something similar?
> To unsubscribe from this list, send a post to
docbook-unsubscribe@lists.oasis-open.org, or visit

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