Home > Diagrams > Sequence Diagram

Tips and tricks

In a sequence diagram you have many hidden tips and tricks which has been implemented and are not in the documentation.
You can for example use the following tips:
  1. Give a name to your diagram
  2. Change Property name
  3. Have the same Lifeline height
  4. Change the property size
  5. Move a message
  6. Move a frame
  7. Resize an activation bar
  8. Move a creation message up and down
  9. Message straight line
  10. Frame compartments size update
  11. Change the name of the frame
  12. Ok button of the frame is not activated
  13. My Elements are not visible in the diagram
1. Give a name to your diagram

You can change the name of the sequence diagram by typing a new Sequence Diagram name in the File name field.



2. Change Property name

It is possible to change the name of the property in the UML Superstructure Model  by using the properties View and changing the name manually in the Name field. Please note that the Properties view could be shared by few other plugins. EclipseUML can't therefore customize this graphical presentation in order to keep plugin compatibility. It means that you have to select the Name Value and enter directly the new value in the View even if a property wizard would certainly have been more adapted. The respect of plugins compatibility requires sometimes not to be too intrusive.



3. Have the same Lifeline height

EclipseUML will not launch any refresh of the Sequence Diagram in order to keep users graphical presentation. It is therefore sometimes important to manually change the height of each Lifeline using the Sequence Diagram contextual menu > Life Lane Layout.



4. Change the property size

It is possible to manually resize the height and the width of each property by using the mouse.
Click on the property and select one of the black point to resize the shape with the mouse.
You can notice that the Lifeline is sometimes longer than the frame. You can use the Life Line layout to be sure that the Life line is inside the frame.



5. Move a message

You can move a message up and down at any time if the message is not in a frame.
If the message is in the frame then it can't go outside the frame anymore.



6. Move a frame

You can graphically move a frame but don't forget that messages are created inside the frame at the frame or message creation. It means that if you move a frame then the message will remain in the frame in the UML Superstructure of your model but not graphically. We therefore refuse to block the frame move but don't recommend to use this graphical feature. The best is to erase the frame and create a new frame  as soon as  you need to move the frame.
You can resize the frame on the left and the right because the graphical and UML Superstructure model is updated but shouldn't resize it up and down because of the message order. You can also not move inner frames outside the frame of creation. Moving frame outside will layout the diagram and the inner frame will disappear from the frame and be placed in the upper right corner.



7. Resize an activation bar

You can resize activation bar using the mouse. Please note that the activation bar is only a graphical element and is not anymore in UML 2 a UML Superstructure element Model.

8. Move a creation message

You can move a creation message if you select the life line with the mouse.



9. Message straight line

If a message is not straight anymore you can refresh the target connector.
Click on the Message > Straight Message Line


10. Frame compartments size update

If after adding, deleting, moving or changing properties of a message the frame is not anymore as it was at the creation then you can refresh the size of each inner compartment. Click on the frame to open the Frame Properties. You can notice that the Ok button is grey but if you erase and add the same information then the Ok button is now activated. If you click on the Ok button then the size of inner compartments will be refreshed immediately.



11. Change the name of the frame

It is possible to change the name of the frame using the Properties View.
Select the Name Value Field and type the new name.



12. Ok button of the frame is not activated

The Ok button of the frame is not activated if:

13. My Elements are not visible in the diagram

You can have a strange diagram if you resize the main frame such as the image below.
The LifeLine and Activation bars are only visible inside the main frame while messages are always visible.



To see both LifeLine and messages you need to manually resize the main frame using the mouse.
You will then get the following diagram