Author extensions

The CSS file used for rendering DITA content is located in ${frameworks}/dita/css/dita.css.

Specific actions for DITA topic documents are:

  • Bold - surrounds the selected text with b tag.

  • Italic - surrounds the selected text with i tag.

  • Underline - surrounds the selected text with u tag.

    [Note]Note

    For all of the above actions if there is no selection then a new specific tag will be inserted. These actions are available in any document context.

  • Cross Reference - inserts an xref element with the value of attribute format set to "dita", and type set to "topic". The target of the xref is selected in a dialog which lists all the IDs available in a file selected by the user.

    Figure 6.3. Insert a cross reference in a DITA document

    Insert a cross reference in a DITA document

  • File Reference - inserts an xref element with the value of attribute format set to "xml".

  • Web Link - inserts an xref element with the value of attribute format set to "html", and scope set to "external".

  • Related Link to Topic - inserts a link element inside a related-links parent.

  • Related Link to File - inserts a link element with the format attribute set to "xml" inside a related-links parent.

  • Related Link to Web Page - inserts a link element with the attribute format set to "html" and scope set to "external" inside a related-links parent.

    [Note]Note

    The actions for inserting references described above are grouped inside link toolbar actions group.

  • Insert Section/Step - inserts a new section/step in the document, depending on the current context. A new section will be inserted in either one of the following contexts:

    • section context, when the value of 'class' attribute of the current element or one of its ancestors contains 'topic' or 'section'.

    • topic's body context, when the value of 'class' attribute of the current element contains 'topic/body'.

    A new step will be inserted in either one of the following contexts:

    • task step context, when the value of 'class' attribute of the current element or one of its ancestors contains 'task/step'.

    • task steps context, when the value of 'class' attribute of the current element contains 'task/steps'.

  • Insert Paragraph - inserts a new paragraph depending on the current context. If current context is a paragraph context (the value of 'class' attribute of the current element or one of its ancestors contains 'topic/p') then a new paragraph will be inserted after this paragraph. Otherwise a new paragraph is inserted at caret position.

  • Insert Concept - inserts a new concept. Concepts provide background information that users must know before they can successfully work with a product or interface. This action is available in one of the following contexts:

    • concept context, one of the current element ancestors is a concept. In this case an empty concept will be inserted after the current concept.

    • concept or dita context, current element is a concept or dita. In this case an empty concept will be inserted at current caret position.

    • dita topic context, current element is a topic child of a dita element. In this case an empty concept will be inserted at current caret position.

    • dita topic context, one of the current element ancestors is a dita's topic. In this case an empty concept will be inserted after the first topic ancestor.

  • Insert Task - inserts a new task. Tasks are the main building blocks for task-oriented user assistance. They generally provide step-by-step instructions that will enable a user to perform a task. This action is available in one of the following contexts:

    • task context, one of the current element ancestors is a task. In this case an empty task will be inserted after the last child of the first concept's ancestor.

    • task context, the current element is a task. In this case an empty task will be inserted at current caret position.

    • topic context, the current element is a dita's topic. An empty task will be inserted at current caret position.

    • topic context, one of the current element ancestors is a dita's topic. An empty task will be inserted after the last child of the first ancestor that is a topic.

  • Insert Reference - inserts a new reference in the document. A reference is a top-level container for a reference topic. This action is available in one of the following contexts:

    • reference context, one of the current element ancestors is a reference. In this case an empty reference will be inserted after the last child of the first ancestor that is a reference.

    • reference or dita context, the current element is either a dita or a reference. An empty reference will be inserted at caret position.

    • topic context, the current element is topic descendant of dita element. An empty reference will be inserted at caret position.

    • topic context, the current element is descendant of dita element and descendant of topic element. An empty reference will be inserted after the last child of the first ancestor that is a topic.

  • Insert Graphic - inserts a graphic object at the caret position. This is done by inserting a <image> element. The following graphical formats are supported: GIF, JPG, JPEG, BMP, PNG and SVG.

  • Insert Content Reference - inserts a content reference at the caret position.

    The DITA conref attribute provides a mechanism for reuse of content fragments. The conref attribute stores a reference to another element and is processed to replace the referencing element with the referenced element. The element containing the content reference acts as a placeholder for the referenced element. The identifier for the referenced element must be either absolute or resolvable in the context of the referencing element. See here for more details.

    <oXygen/> will display the referred content of a DITA conref if it can resolve it to a valid resource. If you use URI's instead of local paths and you have a catalog used in the DITA OT transformation you can add the catalog to <oXygen/> and if the URI's can be resolved the referred content will be displayed.

    A content reference is inserted with the action Insert a DITA Content Reference available on the toolbar Author custom actions and on the menu DITAInsert.

    Figure 6.4. Insert Content Reference Dialog

    Insert Content Reference Dialog

    In the URL chooser you can choose the file from which you want to reuse content. Depending on the Target type filter you will see a tree of elements which can be referred (which have id's). For each element the XML content is shown in the preview area. The Conref value is computed automatically for the selected tree element. After pressing OK an element with the same name as the target element and having the attribute conref with the value specified in the Conref value field will be inserted at caret position.

  • Insert Ordered List - inserts an ordered list with one list item.

  • Insert Unordered List - inserts an unordered list with one list item.

  • Insert List Item - inserts a new list item for in any of the above two list types.

  • Insert Table - opens a dialog that allows you to configure the table to be inserted.

    Figure 6.5. Insert Table Dialog

    Insert Table Dialog


    The dialog allows the user to configure the number of rows and columns of the table, if the header will be generated, if the title will be added and how the table will be framed.

  • Insert Row - inserts a new table row with empty cells. The action is available when the caret position is inside a table.

  • Insert Column - inserts a new table column with empty cells after the current column. The action is available when the caret position is inside a table.

  • Insert Cell - inserts a new empty cell depending on the current context. If the caret is positioned between two cells, a new one will be inserted at caret's position. If the caret is inside a cell, then the new one will be created after the current cell.

  • Delete Column - deletes the table column where the caret is located.

  • Delete Row - deletes the table row where the caret is located.

  • Join Row Cells - joins the content of the selected cells. The operation is available if the selected cells are from the same row and they have the same row span. The action is also available when the selection is missing, but the caret is positioned between two cells.

  • Join Cell Above - joins the content of cell from current caret position with that of the cell above it. Note that this action works only if both cells have the same column span.

  • Join Cell Below - joins the content of cell from current caret position with that of the cell below it. Note that this action works only if both cells have the same column span.

  • Split Cell To The Left - splits the cell from current caret position in two, inserting a new empty table cell to the left. Note that this action works only if the current cell spans over more than one column. The column span of the source cell will be decreased with one.

  • Split Cell To The Right - splits the cell from current caret position in two, inserting a new empty table cell to the right. Note that this action works only if the current cell spans over more than one column. The column span of the source cell will be decreased with one.

  • Split Cell Above - splits the cell from current caret position in two, inserting a new empty table cell above. Note that this action works only if the current cell spans over more than one row. The row span of the source cell will be decreased with one.

  • Split Cell Below - splits the cell from current caret position in two, inserting a new empty table cell below. Note that this action works only if the current cell spans over more than one row. The row span of the source cell will be decreased with one.

[Note]Note

DITA supports CALS table model similar with DocBook document type in addition to the simpletable element specific for DITA.

[Caution]Caution

Column specifications are required for table actions to work properly.

All actions described above are available in the contextual menu, main menu (DITA submenu) and in the Author custom actions toolbar.

Templates

Default templates available for DITA topics are stored in ${frameworksDir}/dita/templates/topic folder. They can be used for easily creating a DITA's concept, reference, task or topic.

These templates are available when creating new documents from templates.

DITA - Composite

New DITA Composite

DITA - Concept

New DITA Concept

DITA - Glossentry

New DITA Glossentry

DITA - Reference

New DITA Reference

DITA - Task

New DITA Task

DITA - Topic

New DITA Topic