atom feed3 messages in org.oasis-open.lists.docbook-appsRE: DOCBOOK-APPS: Customization layer...
FromSent OnAttachments
Dennis GraceApr 8, 2002 10:13 am 
David CramerApr 8, 2002 10:26 am 
Dennis GraceApr 8, 2002 10:50 am 
Subject:RE: DOCBOOK-APPS: Customization layer question for DocBook XML
From:David Cramer (dcra@broadjump.com)
Date:Apr 8, 2002 10:26:07 am
List:org.oasis-open.lists.docbook-apps

What you want to do is turn off refentry.element before importing docbook, then you can safely redefine it afterwards. Something like this:

<!ENTITY % refentry.element "IGNORE">

<!--load DocBook--> <!ENTITY % DocBookDTD PUBLIC "-//OASIS//DTD DocBook XML V4.2CR1//EN"

"http://www.oasis-open.org/docbook/xml/4.2CR1/docbookx.dtd"> %DocBookDTD;

<!ELEMENT refentry %ho; (beginpage?, (%ndxterm.class;)*, refentryinfo?, refmeta?, (remark|%link.char.class;)*, refnamediv, (refsynopsisdiv?, (refsect1+|refsection+)) +) %ubiq.inclusion;>

Note that I also removed the <![%refentry.element;[ and <!--end of refentry.element-->]]> that wrapped your redeclaration (you do not want this turned off.

Hope that helps, David

-----Original Message----- From: Dennis Grace [mailto:dgr@us.ibm.com] Sent: Monday, April 08, 2002 12:10 PM To: docb@lists.oasis-open.org Subject: DOCBOOK-APPS: Customization layer question for DocBook XML

Allow me to preface this question by admitting that , although I've written several driver files, I've not previously tried to write a customization DTD layer.

I'm trying to produce a man page that is more complex than the standard. Because the resultant man page will describe nested commands (command xxx, subcommands xxx yyy, xxx zzz, xxx aaa, etc., where each subcommand has a fairly complex series of options), I intend to produce a man page that includes several tiers. To that end I wanted to modify the refentry.element portion of dbhier.dtd (I've been using DTD 4.2CR) from

<!ENTITY % refentry.element "INCLUDE"> <![%refentry.element;[ <!ELEMENT refentry %ho; (beginpage?, (%ndxterm.class;)*, refentryinfo?, refmeta?, (remark|%link.char.class;)*, refnamediv, refsynopsisdiv?, (refsect1+|refsection+)) %ubiq.inclusion;> <!--end of refentry.element-->]]>

to allow multiple instances of (refsynopsisdiv?, (refsect1+|refsection+)).

I tried the following customization layer:

<!ENTITY % refentry.element "INCLUDE">

<!--load DocBook--> <!ENTITY % DocBookDTD PUBLIC "-//OASIS//DTD DocBook XML V4.2CR1//EN"

"http://www.oasis-open.org/docbook/xml/4.2CR1/docbookx.dtd"> %DocBookDTD;

<![%refentry.element;[ <!ELEMENT refentry %ho; (beginpage?, (%ndxterm.class;)*, refentryinfo?, refmeta?, (remark|%link.char.class;)*, refnamediv, (refsynopsisdiv?, (refsect1+|refsection+)) +) %ubiq.inclusion;> <!--end of refentry.element-->]]>

I got an error that said "validity error: Redefinition of element refentry" with a pointer to %ubiq.inclusion.

I tried removing the inclusion. I even tried stripping the entire element definition back to the 4.1.2 version, but I still keep getting inclusion errors.

I know the change I'm shooting for is possible, because I tried a SYSTEM identifier with a temporary change to dbhierx.dtd, which worked.

Is something seriously broke in my customization format? What am I missing?

Thanks.

This sentence no verb.