Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Papyrus/Papyrus User Guide/Toolbars/Alignment"

(Hierarchy)
(Hierarchy)
Line 52: Line 52:
 
=== Hierarchy ===
 
=== Hierarchy ===
 
In this section, some examples of alignment in case of hierarchy between objects (parent / children).
 
In this section, some examples of alignment in case of hierarchy between objects (parent / children).
# Example A: Only the parent is aligned [[File:Hierarchy _Align1_before.JPG]]  
+
#Example A: Only the parent is aligned  
:As shown in the result screenshot below , only the parent (the Package) has been aligned. [[File:Hierarchy _Align1_after.JPG]]
+
::[[File:Hierarchy _Align1_before.JPG]]  
# Example B: Alignment inside the Container bounds is available
+
::As shown in the result screenshot below , only the parent (the Package) has been aligned.  
 +
::[[File:Hierarchy _Align1_after.JPG]]
 +
#Example B: Alignment inside the Container bounds is available
 
::[[File:Hierarchy _Align2_before.JPG]]  
 
::[[File:Hierarchy _Align2_before.JPG]]  
 
::In the align options list, only the ones that keep the objects inside his container are enable.
 
::In the align options list, only the ones that keep the objects inside his container are enable.

Revision as of 11:28, 28 August 2014

Alignment Tool

Introduction

Alignment Tool is availbale in the Papyrus toolbar:
Alignment Toolbar.JPG
Alignment allows to align the different objects of the model based on a reference object. The reference object is basically the last object selected (primary selection) and can be identified with the handles color:

Normal Selection
Primary Selection


To implement Alignment, some rules have been defined.

General Rules

Alignement Types

The Alignment Tools allows 6 types of alignmeent:

  • Horizontaly
    • Left
    • Center
    • Right
  • Verticaly
    • Top
    • Middle
    • Bottom


These types can be disable if the alignment is not possible. Here is the different rules on which the alignment is based:

  1. The alignment is available only if the selected object can be moved on the reference
  2. When an object and one or several children should be aligned on a third object, only the parent is aligned
  3. An object can only be aligned inside of its container's bounds.(In order to avoid scrollbar and invisible objects)
  4. An object cannot be aligned on one of its children.


Using of Alignment Tool

Here under, some examples of using of alignment tool.

General Case

Basically, alignment is used in order to make the model easier to be read and more aesthetical. To align objects:

  1. Select the object to be aligned
  2. Clic on the align toolAlign button.JPG button
  3. Choose the proper type of alignment
General Align1 before.JPG
General Align1 after.JPG
The refrence object is here the right one.

In this second example, the object (the Class ) is aligned on his parent (the Package): The unauthorized alignment appears disable (in grey)

General Align2 before.JPG
General Align2 after.JPG

Hierarchy

In this section, some examples of alignment in case of hierarchy between objects (parent / children).

  1. Example A: Only the parent is aligned
Hierarchy Align1 before.JPG
As shown in the result screenshot below , only the parent (the Package) has been aligned.
Hierarchy Align1 after.JPG
  1. Example B: Alignment inside the Container bounds is available
Hierarchy Align2 before.JPG
In the align options list, only the ones that keep the objects inside his container are enable.
Hierarchy Align2 after.JPG

Labels

Edges

Limitation

Back to the top