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: Re: DOCBOOK: Modularity and Emacs psgml mode

Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Tue, Aug 28, 2001 at 08:04:25PM +0200, Massimiliano Mirra wrote:
> I am adopting the common layout which uses system entities to split
> the work in more manageable files, like:
> <!doctype book public "-//OASIS//DTD DocBook V3.1//EN" [
> <!entity chapter1 system "chap1.sgml">
> <!entity chapter2 system "chap2.sgml">
> ]>
> <book>
> &chapter1
> &chapter2
> </book>
> This means that I cannot begin chap1.sgml and chap2.sgml with:
> <!doctype chapter public "-//OASIS//DTD DocBook V3.1//EN" []>
> Because, of course, the file will be included and it cannot present
> such a line in the middle of the document.
> However, this also means that I cannot edit chap1.sgml and chap2.sgml
> taking advantage of Emacs psgml mode, because it won't find any
> identifier/catalog.
> Is there any way to overcome this?

Put something like this at the bottom of chap*.sgml.

     Local Variables:
     mode: sgml
     sgml-declaration: "chapter.decl"
     sgml-indent-data: t
     sgml-omittag: nil
     sgml-always-quote-attributes: t
     sgml-parent-document: ("book.sgml" "part" "chapter")

Where "../chapter.decl" contains this line.

    <!doctype chapter public "-//OASIS//DTD DocBook V3.1//EN">

If your chapters are direct children of the <book> element, without any
intervening <part> elements, change the last line to

    sgml-parent-document: ("book.sgml" "book" "chapter")

replace "book.sgml" with whatever the name of your master document is.

The FreeBSD project uses this technique extensively.  Take a look at


for more examples.

FreeBSD: The Power to Serve             http://www.freebsd.org/
FreeBSD Documentation Project           http://www.freebsd.org/docproj/

          --- 15B8 3FFC DDB4 34B0 AA5F  94B7 93A8 0764 2C37 E375 ---

Content-Type: application/pgp-signature
Content-Disposition: inline

Version: GnuPG v1.0.6 (FreeBSD)
Comment: For info see http://www.gnupg.org



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

Powered by eList eXpress LLC