Package | com.yworks.yfiles.layout.router |
Class | public class OrthogonalSegmentDistributionStage |
Inheritance | OrthogonalSegmentDistributionStage AbstractLayoutStage YObject Object |
See also
Property | Defined By | ||
---|---|---|---|
affectedEdgesDpKey : Object
Specifies the DataProvider key, which determines the edges, that shall be distributed by the algorithm. | OrthogonalSegmentDistributionStage | ||
coreLayouter : Layouter
Specifies the core layouter. | AbstractLayoutStage | ||
gridEnabled : Boolean
Specifies whether grid distribution is enabled or not. | OrthogonalSegmentDistributionStage | ||
gridOffsetX : Number [read-only]
Returns the grid offset in x direction. | OrthogonalSegmentDistributionStage | ||
gridOffsetY : Number [read-only]
Returns the grid offset in y direction. | OrthogonalSegmentDistributionStage | ||
gridWidth : Number
Specifies the grid width that shall be used if grid distribution is enabled. | OrthogonalSegmentDistributionStage | ||
gridWidthAdjustable : Boolean
Specifies whether or not the algorithm is allowed to reduce the grid width, if segments cannot be distributed using the previously given grid width. | OrthogonalSegmentDistributionStage | ||
lockFirstAndLastSegment : Boolean
Getter:
Returns whether the first and last segment of an edge (connected to source or target), will be distributed. | OrthogonalSegmentDistributionStage | ||
preferredDistance : Number
Specifies the preferred distance, segments shall have to each other and to the channel's border. | OrthogonalSegmentDistributionStage | ||
preferredDistanceAdjustable : Boolean
Determines what happens if the preferred distance can not be kept, because there is not enough space for the segments to be distributed in that distance. | OrthogonalSegmentDistributionStage |
Method | Defined By | ||
---|---|---|---|
OrthogonalSegmentDistributionStage(init:Boolean = true) | OrthogonalSegmentDistributionStage | ||
canLayout(graph:LayoutGraph):Boolean [override] | OrthogonalSegmentDistributionStage | ||
doLayout(graph:LayoutGraph):void [override] | OrthogonalSegmentDistributionStage | ||
equals(o:Object):Boolean | YObject | ||
getClass():Class [override] | OrthogonalSegmentDistributionStage | ||
hashCode():int | YObject | ||
[static] | OrthogonalSegmentDistributionStage | ||
setGridOffset(offsetX:Number, offsetY:Number):void
Can be used to set the grid origin. | OrthogonalSegmentDistributionStage |
Method | Defined By | ||
---|---|---|---|
canLayoutCore(graph:LayoutGraph):Boolean
Queries the core layouter whether or not the given graph can be laid out. | AbstractLayoutStage | ||
doLayoutCore(graph:LayoutGraph):void
Invokes the layout routine of the core layouter. | AbstractLayoutStage | ||
initAbstractLayoutStage1():void | AbstractLayoutStage | ||
initAbstractLayoutStage2(core:Layouter):void | AbstractLayoutStage | ||
Initializes this object. | OrthogonalSegmentDistributionStage |
Constant | Defined By | ||
---|---|---|---|
AFFECTED_EDGES : Object = y.layout.router.OrthogonalSegmentDistributionStage.AFFECTED_EDGES [static]
DataProvider key that can be used to determine which edges the distribution stage will route. | OrthogonalSegmentDistributionStage |
affectedEdgesDpKey | property |
affectedEdgesDpKey:Object
Specifies the DataProvider key, which determines the edges, that shall be distributed by the algorithm.
By default, AFFECTED_EDGES is used.
public function get affectedEdgesDpKey():Object
public function set affectedEdgesDpKey(value:Object):void
See also
gridEnabled | property |
gridEnabled:Boolean
Specifies whether grid distribution is enabled or not. If so, all segments will be distributed onto the grid. By default grid distribution is not enabled.
public function get gridEnabled():Boolean
public function set gridEnabled(value:Boolean):void
gridOffsetX | property |
gridOffsetX:Number
[read-only] Returns the grid offset in x direction. by default this will be 0.
public function get gridOffsetX():Number
gridOffsetY | property |
gridOffsetY:Number
[read-only] Returns the grid offset in y direction. by default this will be 0.
public function get gridOffsetY():Number
gridWidth | property |
gridWidth:Number
Specifies the grid width that shall be used if grid distribution is enabled. By default the grid width is 10.0.
public function get gridWidth():Number
public function set gridWidth(value:Number):void
gridWidthAdjustable | property |
gridWidthAdjustable:Boolean
Specifies whether or not the algorithm is allowed to reduce the grid width, if segments cannot be distributed using the previously given grid width. The algorithm will divide the given grid width by 2 as long as the segments will not fit and thus will lead to nicer results than taking some other value. Note: The grid width will only be adjusted for segments that cannot keep the originally set grid width.
By default, the algorithm is allowed to reduce the grid width.
public function get gridWidthAdjustable():Boolean
public function set gridWidthAdjustable(value:Boolean):void
lockFirstAndLastSegment | property |
lockFirstAndLastSegment:Boolean
Getter:
Returns whether the first and last segment of an edge (connected to source or target), will be distributed.
Defaults to false
, i.e. first and last segments are not locked.
false
, i.e. first and last segments are not locked.
public function get lockFirstAndLastSegment():Boolean
public function set lockFirstAndLastSegment(value:Boolean):void
preferredDistance | property |
preferredDistance:Number
Specifies the preferred distance, segments shall have to each other and to the channel's border.
Default value is 10.0
.
Note: if preferredDistanceAdjustable is set to true
(which is the default), the preferred distance might be adjusted so that the maximum possible distance near the given value will be taken. This happens if the channel is not big enough to fit in all segments with the desired preferred distance.
public function get preferredDistance():Number
public function set preferredDistance(value:Number):void
See also
preferredDistanceAdjustable | property |
preferredDistanceAdjustable:Boolean
Determines what happens if the preferred distance can not be kept, because there is not enough space for the segments to be distributed in that distance.
If set to true
the algorithm is allowed to reduce the distance to the next best value, that is possible. If set to false
the algorithm will not at all distribute those segments. By default the setting is true
and therefore segments will be distributed. Note: Preferred distances will not be kept for segments connecting to nodes (first and last segment of an edge). The segments are distributed equidistant all along the node side, thus may lead to bigger distances between segments.
public function get preferredDistanceAdjustable():Boolean
public function set preferredDistanceAdjustable(value:Boolean):void
OrthogonalSegmentDistributionStage | () | Constructor |
public function OrthogonalSegmentDistributionStage(init:Boolean = true)
Parameters
init:Boolean (default = true ) — An internally used switch to help handle proper instance initialization in inheritance chains where classes can have multiple constructor-like factory methods.
This parameter can safely be ignored/omitted when calling the constructor.
|
canLayout | () | method |
override public function canLayout(graph:LayoutGraph):Boolean
Parameters
graph:LayoutGraph |
Boolean |
doLayout | () | method |
getClass | () | method |
override public function getClass():Class
ReturnsClass |
initOrthogonalSegmentDistributionStage | () | method |
protected final function initOrthogonalSegmentDistributionStage():void
Initializes this object. See the documentation of the corresponding factory method newOrthogonalSegmentDistributionStage()
for details.
See also
newOrthogonalSegmentDistributionStage | () | method |
public static function newOrthogonalSegmentDistributionStage():OrthogonalSegmentDistributionStage
ReturnsOrthogonalSegmentDistributionStage |
setGridOffset | () | method |
public function setGridOffset(offsetX:Number, offsetY:Number):void
Can be used to set the grid origin. By default the offset is (0, 0), so there is no offset.
Parameters
offsetX:Number — the offset in x direction.
| |
offsetY:Number — the offset in y direction
|
AFFECTED_EDGES | Constant |
public static const AFFECTED_EDGES:Object = y.layout.router.OrthogonalSegmentDistributionStage.AFFECTED_EDGES
DataProvider key that can be used to determine which edges the distribution stage will route.