Class OrganicLayouterOptionsGroup
java.lang.Object
com.nomagic.magicdraw.core.options.OptionsGroup
com.nomagic.magicdraw.core.options.AbstractPropertyOptionsGroup
com.nomagic.magicdraw.core.options.AbstractDiagramLayouterOptionsGroup
com.nomagic.magicdraw.core.options.OrganicLayouterOptionsGroup
- All Implemented Interfaces:
Cloneable
Organic Layouter options group.
-
Field Summary
Fields inherited from class com.nomagic.magicdraw.core.options.AbstractDiagramLayouterOptionsGroup
ALIGNMENT_BOTTOM, ALIGNMENT_CENTER, ALIGNMENT_TOP, LAYOUT_LABEL_CONSIDERATION, LAYOUT_LABEL_CONSIDERATION_FULL, LAYOUT_LABEL_CONSIDERATION_NONE, LAYOUT_LABEL_CONSIDERATION_PARTIAL, MAX_INT_VALUE, SHAPE_ALIGNMENT
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addProperty
(Property property) Adds property to this group.double
Get Gravity Factor property value.int
Get Link Attraction property value.double
Get Packages Shape Compactness property value.int
Get the preferred length of all paths.int
Get Shape Repulsion.protected void
boolean
Checks Activate Tree Beautifier.boolean
Check Layout Only Top Level property value.boolean
Checks The obay Shape Size.void
setActivateTreeBeautifier
(boolean b) Set Activate Tree Beautifier.void
setGravityFactor
(double d) Set Gravity Factor property value.void
setLayoutOnlyTopLevel
(boolean b) Set Layout Only Top Level property value in order to keeps the relative position of symbols inside packages and performs the top level layout.void
setLinkAttraction
(int a) Set Link Attraction property value.void
setObeyShapeSize
(boolean b) Set The obey Shape Size.void
setPackageShapeCompactness
(double d) Set Packages Shape Compactness property value.void
setPreferredLinkLength
(int len) Set the preferred length of all paths.void
setShapeRepulsion
(int a) Set Shape Repulsion.Methods inherited from class com.nomagic.magicdraw.core.options.AbstractDiagramLayouterOptionsGroup
getCopy, getMakePreferredLayoutSize, getOptimizeLabelOrientations, isMoveToFreeSpace, setDefaultValues, setMakePreferredLayoutSize, setMoveToFreeSpace, setOptimizeLabelOrientations
Methods inherited from class com.nomagic.magicdraw.core.options.AbstractPropertyOptionsGroup
addInvisibleProperty, addProperty, addProperty, getOptions, getProperty, getVisibleOptions, removeProperty, setOptions, setPropertiesInvisible, setPropertyInvisible
Methods inherited from class com.nomagic.magicdraw.core.options.OptionsGroup
getGroupIcon, getIcon, getName
-
Field Details
-
ID
- See Also:
-
-
Constructor Details
-
OrganicLayouterOptionsGroup
public OrganicLayouterOptionsGroup()
-
-
Method Details
-
initCommonDefaultValues
protected void initCommonDefaultValues()- Overrides:
initCommonDefaultValues
in classAbstractDiagramLayouterOptionsGroup
-
setPreferredLinkLength
public void setPreferredLinkLength(int len) Set the preferred length of all paths. The layouter tries to arrange the shapes in such a way that paths have the determined path length.- Parameters:
len
- The given value.
-
getPreferredLinkLength
public int getPreferredLinkLength()Get the preferred length of all paths. The layouter tries to arrange the shapes in such a way that paths have the determined path length.- Returns:
- Int value.
-
setObeyShapeSize
public void setObeyShapeSize(boolean b) Set The obey Shape Size. If True, the distance between two shapes is calculated with respect to shapes' size.- Parameters:
b
- boolean.
-
isObeyShapeSize
public boolean isObeyShapeSize()Checks The obay Shape Size. If True, the distance between two shapes is calculated with respect to shapes' size.- Returns:
- true if should obey shape size, false otherwise
-
setActivateTreeBeautifier
public void setActivateTreeBeautifier(boolean b) Set Activate Tree Beautifier. If True, optimizes tree-like substructures of the diagram. Optimization process might ignore some layout options.- Parameters:
b
- boolean
-
isActivateTreeBeautifier
public boolean isActivateTreeBeautifier()Checks Activate Tree Beautifier. If True, optimizes tree-like substructures of the diagram. Optimization process might ignore some layout options.- Returns:
- boolean
-
setLayoutOnlyTopLevel
public void setLayoutOnlyTopLevel(boolean b) Set Layout Only Top Level property value in order to keeps the relative position of symbols inside packages and performs the top level layout.- Parameters:
b
- boolean.
-
isLayoutOnlyTopLevel
public boolean isLayoutOnlyTopLevel()Check Layout Only Top Level property value. It indicates position of symbols inside packages is on the top level layout.- Returns:
- true if only top level of the diagram should be layouted, false otherwise
-
setGravityFactor
public void setGravityFactor(double d) Set Gravity Factor property value. This value regulates the tendency of the shapes to be placed near the center of the diagram. The greater factor is the closer shapes are placed to the center of diagram. Negative values lead to huge layouts.- Parameters:
d
- double.
-
getGravityFactor
public double getGravityFactor()Get Gravity Factor property value. This value regulates the tendency of the shapes to be placed near the center of the diagram. The greater factor is the closer shapes are placed to the center of diagram. Negative values lead to huge layouts.- Returns:
- double
-
setPackageShapeCompactness
public void setPackageShapeCompactness(double d) Set Packages Shape Compactness property value. This value control the compactness of package shape. Larger values lead to more compact package shapes but paths between packages may be longer and shapes inside packages tend to get clutched together at the center of the package.- Parameters:
d
- double.
-
getPackageShapeCompactness
public double getPackageShapeCompactness()Get Packages Shape Compactness property value. This value control the compactness of package shape. Larger values lead to more compact package shapes but paths between packages may be longer and shapes inside packages tend to get clutched together at the center of the package.- Returns:
- double
-
setLinkAttraction
public void setLinkAttraction(int a) Set Link Attraction property value. Higher values makes Layouter obey the given preferred path length.- Parameters:
a
- int.
-
getLinkAttraction
public int getLinkAttraction()Get Link Attraction property value. Higher values makes Layouter obey the given preferred path length.- Returns:
- int.
-
setShapeRepulsion
public void setShapeRepulsion(int a) Set Shape Repulsion. Higher values result in greater shape distances.- Parameters:
a
- the shape repulsion value to set
-
getShapeRepulsion
public int getShapeRepulsion()Get Shape Repulsion. Higher values result in greater shape distances.- Returns:
- int.
-
addProperty
Description copied from class:AbstractPropertyOptionsGroup
Adds property to this group. DescriptionID will be reset. To add property with description useAbstractPropertyOptionsGroup.addProperty(Property, String)
method.- Overrides:
addProperty
in classAbstractPropertyOptionsGroup
- Parameters:
property
- property to be added.
-