Renaming Elements in the Diagram
Many texts which can be shown in diagrams can be edited directly there. You don't need to bother changing to the Properties tool window.
Renaming an Element in the Diagram
Prerequisites
The model language is set as display language for diagrams. If required, change the language by clicking the flag in the status bar.
Context
Elements require a unique name within their namespace; if necessary, this is created automatically with a suffix. This name is always the name in the model language.
Diagram contents can be shown with the model language or another language.
You can only edit element names in the model language when outside of the diagram, e.g. in the Properties tool window; this also applies if another display language is set for the diagrams.
Note
The name shown in the diagram can be the name of another element.
In the BPMN diagram, e.g. the name of the called element is typically used for a call activity and not its own name. If a call activity is renamed directly in the diagram, then the name of the called element is modified and not that of its own name. This means that the change directly affects the diagram display. Maintenance changes the name of the call activity to suit the name change.
The message is renamed for send/receive tasks and the service operation is renamed for service tasks.
How to proceed
- Select the model element in the diagram which you want to rename.
- Click [F2] (Rename context menu command).
- Enter the new name for the element and confirm with the [Enter] key or with the [Ctrl]+[Enter] key for multiple entries.
Text Deviations
The text shown in the diagram and the text in the editing field can be different. This is because you can configure exactly what is shown for diagrams. This means that e.g. not only the name of the attribute but the attribute's type is also shown for an attribute in a class. The editing field only shows the attribute's name to edit.
This could have the effect that the text in the editing field is not shown at all in the diagram.
Leaving Editing Mode
Once you have changed the text in the editing field you normally save your changes by hitting the[Enter] key. If your text has more than one line e.g. for comments, pressing Enter will only add a soft return and won't save it. You can save changes to texts with more than one line with [Ctrl]+[Enter]. This key combination also works for texts with one line.
The text is also saved if you click with the mouse in the diagram outside of the editing field.
Attention
Changes are discarded if you click outside of the diagram. This normally has the effect that the editing field is no longer the focal point. This could mean that changes are discarded without security prompt.
Editing Field Position
The editing field is normally shown centrally above the text to be edited. The editing field is always fully shown. If the diagram is moved so that the text would be partially or completely hidden, the editing field is automatically moved so it is completely visible.
The editing field always tries to show the text exactly as it was saved. If the text is wrapped in the diagram due to lack of space, these wraps are not shown in the editing field. The editing field does show hard returns if these are possible in the text.
