Next / Previous / Contents / TCC Help System / NM Tech homepage

16. Converting DocBook-SGML 4.1 documents

If you have a document built under SGML-based DocBook, like our previously recommended version 4.2, follow these steps to convert it to XML.

  1. Replace the <!DOCTYPE...> declaration at the top of your document with the one from the first two lines of the model file in your working directory (assuming you followed the directory setup procedure above), or use /u/www/docs/tcc/doc/docbook42/model.

  2. Because our current version of emacs's xml-mode is flawed, the current version of the emacs customization files described in the directory setup procedure above, you will actually be in emacs's SGML mode and not its XML mode. Therefore it is necessary to replace all empty tags like <imagedata/> with an opening and closing pair of tags with no content between them. So, for example, instead of the usual XML empty tag construct like

        <imagedata file="penguin.gif" />

    you would instead use

        <imagedata file="penguin.gif"></imagedata>

    You will need to do this for all the empty elements, including these that we use in this document:

    <colspec/>
    <imagedata/>
    <xref/>
  3. If you use pictures and other graphics, refer to the section above on including graphics. At this writing, only JPG and GIF formats are supported.