TopLeaf creates a file system hierarchy for each SGML document added to it. These are known as "partitions" (Figure 3). The partition contains a copy of the relevant DTD and the other control files required to typeset a document built to this DTD. These are a style file (defining the page layout), a mapping file (which connects SGML elements to typesetting function calls as in Listing Two), and a macros file (which contains user-written functions for controlling special typesetting tasks). The partition also has multiple subdirectories to store images of each update cycle.
TopLeaf does in the background what most loose-leaf publishing systems do in the foreground. Rather than splitting a document into several pages and letting the document author figure out which pages need revision, the document author is always presented with a continuous file representing an entire chapter. In the background, TopLeaf figures where the page boundaries occur, and after an initial set up, locks the pages so that updating can take place. Updates are still implemented through the continuous SGML file, but when passed back to TopLeaf, the pages are reconstructed. A difference engine detects where changes to the data have been made on a page, and that page is then flagged as having been updated. As material is added, there may be overflow. In this case, new pages get created on-the-fly (for example, if a page gets created between pages 2 and 3, it is called 2.1 so that page 3 does not have to get renumbered, which would violate page revisioning rules). These pages are variously known as dot-pages, stroke-pages, or a-pages, depending on the numbering scheme implemented. TopLeaf supports five levels of dot-pages. That is, it can generate a page numbered 2.1.1.1.1.1 between pages 2 and 3, each of these having its own life cycle.
To control the change cycle, TopLeaf breaks down the process into two phases: the update phase and the published phase. When TopLeaf is instructed to publish the changes, the edits made since the last publish phase are incorporated into the document, and this version becomes the basis for the next update cycle. TopLeaf lets you edit and reedit a document as many times as you like before making the edits official. This is extremely useful for the review and approval process where, if a reviewer wants a change undone, it is possible to do so quite easily before the changes are made official.
-- J.S.B.
Back to Article