Working with master documents

What is a master document?

The following documents may be used as master documents: DITA map, DocBook 5.1 assembly, DocBook modular documents (for example, a book including chapters by the means of XInclude).

In order to use a document as a master document, simply open this document and check ToolsUse as Master Document. This is done once for all as this choice is is persistent across editing sessions.

Declaring a document as being a master document creates a document set containing the master document and its module document. This document set is automatically updated when the master document is saved to disk.

Notice in the screenshots below that XXE gives the same distinctive color to the tabs containing the master document and its module documents. This makes it easier for the user to spot the members of a document set.

Why check "Use as Master Document"?

By grouping a master document and its module documents, you inform XMLmind XML Editor (XXE) that all the module documents referenced or included, directly or indirectly, by the master document are related. When XXE knows that some of the opened documents are related:

Use case explaining the enhanced cross-reference creation/validation provided by a master document

DITA map mymap.ditamap references 3 topics: topicA.dita, topicB.dita and topicC.dita.

File topicA.dita contains:

<topic id="topicA">
  <title>Topic A</title>

  <body>
    <section id="sectionA1"><title>Section A1</title><p>TODO</p></section>

    <section id="sectionA2"><title>Section A2</title><p>TODO</p></section>
  </body>

  <related-links>
    <link href="nowhere.dita">
      <linktext>Link to nowhere</linktext>
    </link>

    <link href="topicB.dita#topicB/sectionB1">
      <linktext>Link to Section B1</linktext>
    </link>
  </related-links>
</topic>

In the above file, the first link element points to a non-existent target and the second link points to the first section of topicB.dita.

The user wants to check the links found in topicA.dita and also to add an xref element pointing to the first section of topicC.dita. In order to do that, she/he opens topicA.dita in XXE.

Before using mymap.ditamap as a master document:

After using mymap.ditamap as a master document:

Screencast Watch the screencast

Related tutorials

related tutorial Conditional processing made easy