![]() |
Books and multifile documents | ![]() |
When a document gets really large, you may want to subdivide it into smaller pieces. This both makes the individual pieces more easily reusable in other works and it improves the editor's responsiveness. An entire file can be inserted into another one using Insert\(\rightarrow\)Link\(\rightarrow\)Include. In order to speed up the treatment of included documents, they are being buffered. In order to update all included documents, you should use Tools\(\rightarrow\)Update\(\rightarrow\)Inclusions.
When writing a book, one usually puts the individual chapters in files c1.tm, c2.tm until cn.tm. One next creates one file book.tm for the whole book, in which the files c1.tm, c2.tm until cn.tm are included using the above mechanism. The table of contents, bibliography, etc. are usually put into book.tm. The bibliography of book.tm then holds the references cited in all the chapters; with Zotero, its BibTEX file receives them, and Document\(\rightarrow\)Bibliography\(\rightarrow\)Update the citations acts on all the files of the book (see Citations from Zotero).
In order to see cross references to other chapters when editing a particular chapter ci.tm, one may specify book.tm as a “master file” for the files c1.tm to cn.tm using Tools\(\rightarrow\)Project\(\rightarrow\)Attach master. Currently, the chapter numbers themselves are not dealt with by this mechanism, so you may want to manually assign the environment variable chapter-nr at the start of each chapter file in order to get the numbering right when editing.