Moveable decorators
Behavior in previous versions of the DSL Tools
In previous versions of the DSL Tools, such as, in the DSL Class diagram which is provided as a sample, you could very easily end-up with a very cluttered diagram:
New behavior
With the moveable decorators feature, the DSL author can choose let the decorators on a connector be moveable by the user.
How the DSL author enables the moveable decorators?
- In the DslDefinition.dsl file, select the decorators of the connector that you want to let moveable. Note in the picture below that I selected the four decorators of the AssociationConnector
- In the Properties window, change the IsMoveable property to True
- Transform All templates and rebuild
What is the behavior for the user?
Having letting the decorators on this connector being moveable, the designer’s user will now be able to drag each of them to the position of his/her choice:
If the user selects a decorator, it will be visualized with a segment from the original location to the moved location
If the user selects the connector, all the segments from the connector to the moved position will be displayed:
If the user wants to reset the location of a moved decorator to its original location, there is a contextual command
which let the decorator get it’s original location
Improvements for Beta2
In Beta1, the segments from the connector to the decorators are visible even if the displayed text is empty, which a few customers have found to be is a bit confusing. Therefore, in Beta2 these lines will be invisible if the text is empty, and the empty decorators won’t be selectable.