Tree Editors

This document explains how to use Sirius tree editors/modelers which allow to view and manipulate data in a hierarchical way.

  1. Tree Editors
    1. Introduction
    2. Creating, Renaming and Deleting Trees
    3. Refreshing Trees
    4. Adding and Removing Tree Items
    5. Editing Tree Items
    6. Tree Items Drag and Drop
    7. Quick Outline
    8. Overriding Tree Items Font


Sirius provides support for hierarchical representations called trees, which represent information in a hierarchical way.

Note that as always with Sirius, some of the features described below may or may not be available with all specific tree editors. Some tree editors are configured to only display information but do not allow edition for example. It all depends on which features the person who specified (configured) the tree decided to support.

Creating, Renaming and Deleting Trees

Trees are managed in the same way as the other kinds or representations supported by Sirius (diagrams, tables...). They are created either through the New Representation context menu on a semantic element, or through the Create Representation action on the context menu of a Modeling Project. Newly created trees are automatically opened. To open an existing tree, simply double-click on it in the Model Explorer: it will appear both inside the representation file ( aird file) and under the semantic element it represents inside the semantic model.

You can rename, duplicate or delete a tree by choosing the corresponding action (resp. Rename, Copy or Delete) in the context menu on the tree element in the Model Explorer.

Refreshing Trees

Depending on the value of the Automatic refresh Sirius preference (accessible through Window / Preferences... / Sirius), the contents of opened trees may or may not be automatically updated when the underlying semantic model changes. In manual refresh mode (when Automatic refresh is unchecked), you can explicitly request a refresh of the whole tree by using the Refresh button in the main Eclipse toolbar, as shown below:

Adding and Removing Tree Items

If the tree’s configuration has defined tools to create new element (tree items), they will appear in the context menu of existing tree items. The name of the creation tools is not fixed; it depend on the tree’s configuration, so it will be different for each tree modeler. Note that you must have a tree element selected for the creation tools to appear in the context menu, and the behavior of the tool may depend on the selected element.

If the tree is completely empty and you have no element to select, you can still create elements (if supported by the tree’s configuration) by using the drop-down menus in the main Eclipse toolbar (see screenshot).

Editing Tree Items

There are several ways to activate the edition of a tree item:

Once the edit mode is enabled, simply enter your text and hit Return to validate. The expected format of the edit string and its interpretation depends on how the tree’s configuration has been set up to interpret the text you enter.

Tree Items Drag and Drop

Drag and drop is a feature which can be enabled by the specifier in the tree configuration. It is turned off by default.

Simply select the Tree Items you would like to drag, and drop them inside an other Tree Item. Most of the time, this will result in the dropped element being added to the new location, but the exact effect of the operation is entirely dependent on how the tree was configured by its specifier.

Notice that it may also possible to drag elements from other Eclipse views. Again, this depends on how the tree was configured.

Quick Outline

A quick outline is available with the shortcut Ctrl + O. This allows you to rapidly search text in the displayed name or the contained String attributes of your table elements elements.

The star, *, is a joker character, allowing you to search with more complicated patterns. Regarding this, an element is found if there is a word in its name or one of its attributes that match with the text in the filter, so if you want to search within words too, add * at the start of your pattern. Also, you can navigate along the matching elements with and , and go to the selected element in your editor with Enter.

Overriding Tree Items Font

The tree editor always specify a font and text size to use when displaying tree items. If these do not render well on your machine for any reason, you can tell Sirius to use the default font from your environment instead.

To do so, go to “Window>Preferences”. In the preference window: