|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mindfusion.diagramming.AbstractLayout
com.mindfusion.diagramming.OneWayLayout
public class OneWayLayout
Implements a one-way graph layout algorithm. The one-way layout ensures that links enter into nodes from the same general direction and exit them from the opposite side. If the graph contains cycles, some links bend around the nodes to keep the enter/exit direction consistent. The algorithm aims to minimize the number of such links.
Constructor Summary | |
---|---|
OneWayLayout()
Initializes a new instance of the OneWayLayout class
with the default settings. |
Method Summary | |
---|---|
boolean |
arrange(Diagram diagram,
DiagramItemList items)
Applies the layout to the specified diagram. |
protected XDimension2D.Double |
getDefaultMarginValue()
Gets the default value of the Margins property. |
float |
getNodeDistance()
Gets the minimum spacing between adjacent nodes in the final layout. |
int |
getOrientation()
Gets the orientation of the arranged graph. |
boolean |
getRoundedLinks()
Gets a value indicating whether the layout should smooth link bends. |
void |
setNodeDistance(float value)
Sets the minimum spacing between adjacent nodes in the final layout. |
void |
setOrientation(int value)
Sets the orientation of the arranged graph. |
void |
setRoundedLinks(boolean value)
Sets a value indicating whether the layout should smooth link bends. |
Methods inherited from class com.mindfusion.diagramming.AbstractLayout |
---|
arrange, getAnchoring, getKeepGroupLayout, getLayoutLink, getLayoutNode, getMargins, getMultipleGraphsPlacement, getProgress, removeMidleSegmentPoint, setAnchoring, setKeepGroupLayout, setLayoutLink, setLayoutNode, setMargins, setMultipleGraphsPlacement, setProgress |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public OneWayLayout()
OneWayLayout
class
with the default settings.
Method Detail |
---|
public boolean arrange(Diagram diagram, DiagramItemList items)
arrange
in class AbstractLayout
diagram
- The Diagram that should be arranged.items
- A collection of nodes and links from diagram that define
the subgraph to arrange.
protected XDimension2D.Double getDefaultMarginValue()
Margins
property.
public boolean getRoundedLinks()
public void setRoundedLinks(boolean value)
public int getOrientation()
Orientation
constants.public void setOrientation(int value)
value
- One of the Orientation
constants.public float getNodeDistance()
public void setNodeDistance(float value)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |