Creating a DITA map using drag and drop

  1. Use File > New and choose DITA Map | Map.
  2. Use File > Save As to give a filename to the newly created map.
  3. Drag a reference to a topic:
    • Using your file manager. Simply drag the icon representing the XML file containing the topic.
    • OR using your web browser. Simply drag the link to the topic as found in an HTML page (or the corresponding bookmark icon as found in the location bar).
    • OR using XXE itself.

      In such case, open in XXE the topic you want to reference and click on the dashed line found at the bottom the tab of the document view to have both the map and the topic side by side.

      For this task, it may be more convenient to have one view at the right of the other rather than one view below the other. To do this, use Options > Quick Preferences > Split Window Vertically .


      • Click anywhere on the document view containing the topic to make sure this document is the active one and then, drag the bookmark icon1 found in XXE's node path bar.

      • OR, if the XML file contains several nested topics, first select the topic element you want to reference as if you wanted to edit it2 and then drag anywhere inside it while pressing the Alt key to drag its reference.

        Note: Alt-drag allows to drag any element having an id attribute without having to select it first. However in the case of a container element such as a section or a topic, it is much easier to first select the element for which you want to drag a reference and then, alt-drag anywhere inside it.

        Note that this drag facility is fully aware of the way elements are referenced in DITA. For example, if you drag a p element having "audience" as its id attribute and if this p element is contained in a topic element contained in file file://home/john/doc/topic1.dita and having "introduction" as its id attribute, you'll end up dragging string "file://home/john/doc/topic1.dita#introduction/audience".

  4. Drop the dragged reference onto any of the following elements: map, topicref, topichead, topicgroup, mapref.
    • Most of the above elements have a drop site which may be used to add a new topicref at the end of the element.
    • Dropping a topic reference onto href=xxx in a topicref may be used to change the href attribute of this element.
    • Dropping a topic reference onto mapref=xxx in a navref may be used to change the mapref attribute of this element.
    XXE will automatically attempt to make the dropped reference relative to the location of the drop site. If, for example, you drop file://home/john/doc/topic1.dita onto a topicref element contained in file://home/john/doc/maps/book.ditamap, its href attribute will contain "../topic1.dita". If the dropped reference cannot be made relative to the location of the drop site (for example, if it is an http:// URL) then the href attribute will contain the dropped reference as is.
1 For an unknown reason, this will not work on the Mac.
2 There are many ways to do this. For example, click several times anywhere inside the topic, while pressing the Ctrl key and without moving the mouse, until you ``reach'' it. More information in XMLmind XML Editor - User's Guide, "Being productive with XXE".