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] | [Elist Home]


Subject: DOCBOOK: Defining ENTITYs in nested entity files



I am a total "first day" newcomer to DocBook, trying to set up a basic
outline for a possible book.  I have a basic set of .sgml files worked
out, but was perplexed about the rationale behind the <!ENTITY> /
&entity; scheme which demands all entities be named in the top-layer
document, rather than localized where it matters.

For example, I considered:

  book.sgml (including <book> &preface; &partfoo; &partbar; </book>)

    preface.sgml (a leaf <preface> </preface>)

    partfoo.sgml (including <part> &chapfoofoo; &chapfoobar; </part>)

      chapfoofoo.sgml (a leaf <chapter> </chapter>)

      chapfoobar.sgml (a leaf <chapter> </chapter>)

    partbar.sgml (including <part> &chapbarfoo; &chapbarbar; </part>)

      chapbarfoo.sgml (a leaf <chapter> </chapter>)

      chapbarbar.sgml (a leaf <chapter> </chapter>)

However, to "include" the nested files, I have to identify all of them
in the book.sgml as <!ENTITY> elements before the <book> tag starts.  I
couldn't find a way to name a file to be included/imported on the spot. 
It seems more natural to me to define the chapter elements in each part
file, and the part files in the book file.

This is merely an annoyance, and if pressed, I could just massage the
.sgml files with a higher level script.  I was just wondering about the
rationale to requiring all external entities at all scopes to be
referenced in the top level file?  (And to point out something I missed,
if indeed I did.)

-- 
[ e d @ h a l l e y . c c ]


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


Powered by eList eXpress LLC