Packagecom.yworks.yfiles.layout.orthogonal
Classpublic class OrthogonalGroupLayouter
InheritanceOrthogonalGroupLayouter Inheritance CanonicMultiStageLayouter Inheritance YObject Inheritance Object

This class provides a layout algorithm which produces orthogonal drawings of hierarchically grouped graphs.

Here is a sample output of the layouter.



Public Properties
 PropertyDefined By
  alignDegreeOneNodes : Boolean
Specifies whether the algorithm should try to align degree-one nodes that have the same neighbour.
OrthogonalGroupLayouter
  componentLayouter : LayoutStage
[override] Note that the component layouter set here should work in such a way that isolated components inside groups should be reported separately.
OrthogonalGroupLayouter
 InheritedcomponentLayouterEnabled : Boolean
Getter: Returns whether or not ComponentLayouter is enabled.
CanonicMultiStageLayouter
  considerNodeLabels : Boolean
Getter: Returns whether or not node labels are taken into account when calculating node positions (thereby preventing possible node/node label or node label/node label overlaps).
OrthogonalGroupLayouter
  edgeLayoutDescriptor : EdgeLayoutDescriptor
Specifies the EdgeLayoutDescriptor instance used for all those edges, that do not have a specific layout descriptor assigned.
OrthogonalGroupLayouter
  grid : int
Specifies the grid distance.
OrthogonalGroupLayouter
 InheritedgroupNodeHider : LayoutStage
Specifies the LayoutStage that is responsible for hiding away grouping information for the layout algorithm.
CanonicMultiStageLayouter
 InheritedhideGroupNodes : Boolean
Specifies whether or not to hide away group nodes before the layout begins.
CanonicMultiStageLayouter
  integratedEdgeLabeling : Boolean
Getter: Returns whether integrated edge labeling is enabled.
OrthogonalGroupLayouter
 InheritedlabelLayouter : LayoutStage
Getter: Returns the algorithm used for placing labels.
CanonicMultiStageLayouter
 InheritedlabelLayouterEnabled : Boolean
Getter: Returns whether or not LabelLayouter is enabled.
CanonicMultiStageLayouter
 InheritedlayoutOrientation : int
Specifies the main layout orientation.
CanonicMultiStageLayouter
  layoutQuality : Number
Getter: Returns the currently set layout quality.
OrthogonalGroupLayouter
  optimizePerceivedBends : Boolean
Specifies whether the algorithm should perform a post processing algorithm to reduce perceived bends in the drawing.
OrthogonalGroupLayouter
 InheritedorientationLayouter : LayoutStage
Specifies the LayoutStage that is responsible for changing the orientation of the computed layout.
CanonicMultiStageLayouter
 InheritedorientationLayouterEnabled : Boolean
Getter: Returns whether or not the OrientationLayouter is enabled.
CanonicMultiStageLayouter
 InheritedparallelEdgeLayouter : LayoutStage
Getter: Returns the LayoutStage responsible for routing parallel edges.
CanonicMultiStageLayouter
 InheritedparallelEdgeLayouterEnabled : Boolean
Getter: Returns whether or not the ParallelEdgeLayouter is enabled.
CanonicMultiStageLayouter
  postprocessingEnabled : Boolean
Specifies if an additional postprocessing step is used that improves compactness and reduces the number of edge bends.
OrthogonalGroupLayouter
 InheritedselfLoopLayouter : LayoutStage
Getter: Returns the LayoutStage used for routing Self-loops.
CanonicMultiStageLayouter
 InheritedselfLoopLayouterEnabled : Boolean
Getter: Returns whether or not the SelfLoopLayouter is enabled.
CanonicMultiStageLayouter
 InheritedsubgraphLayouter : LayoutStage
Specifies the LayoutStage that is responsible for constraining the layout process to a subgraph of the target graph.
CanonicMultiStageLayouter
 InheritedsubgraphLayouterEnabled : Boolean
Getter: Returns whether or not the SubgraphLayouter is enabled.
CanonicMultiStageLayouter
Public Methods
 MethodDefined By
  
OrthogonalGroupLayouter(init:Boolean = true)
Creates a new instance of OrthogonalGroupLayouter
OrthogonalGroupLayouter
 Inherited
Appends a stage to the layout pipeline.
CanonicMultiStageLayouter
 Inherited
Returns a layout for the given layout graph.
CanonicMultiStageLayouter
 Inherited
Returns a layout for the given graph interface and layout.
CanonicMultiStageLayouter
 Inherited
canLayout(graph:LayoutGraph):Boolean
Tests whether or not the given graph can be laid out by this layouter.
CanonicMultiStageLayouter
  
canLayoutCore(graph:LayoutGraph):Boolean
[override]
OrthogonalGroupLayouter
  
doLayout(graph:LayoutGraph):void
[override]
OrthogonalGroupLayouter
 Inherited
Calculates a layout for the given graph interface and layout.
CanonicMultiStageLayouter
  
[override]
OrthogonalGroupLayouter
 Inherited
Disables all layout stages and performs only the core layouter.
CanonicMultiStageLayouter
 Inherited
equals(o:Object):Boolean
YObject
  
getClass():Class
[override]
OrthogonalGroupLayouter
 Inherited
hashCode():int
YObject
  
[static] Creates a new instance of OrthogonalGroupLayouter
OrthogonalGroupLayouter
 Inherited
Prepends a stage to the layout pipeline.
CanonicMultiStageLayouter
 Inherited
Removes a LayoutStage that has been previously added by the methods appendStage() or prependStage().
CanonicMultiStageLayouter
Protected Methods
 MethodDefined By
 Inherited
checkGroupNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given group node object is zero.
CanonicMultiStageLayouter
 Inherited
checkNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given node object is zero.
CanonicMultiStageLayouter
  
Factory method that creates the default EdgeLayoutDescriptor.
OrthogonalGroupLayouter
 Inherited
CanonicMultiStageLayouter
  
Initializes this object.
OrthogonalGroupLayouter
Public Constants
 ConstantDefined By
  EDGE_LAYOUT_DESCRIPTOR_DPKEY : Object = y.layout.orthogonal.OrthogonalLayouter.EDGE_LAYOUT_DESCRIPTOR_DPKEY
[static] com.yworks.yfiles.base.DataProvider key used to retrieve com.yworks.yfiles.layout.orthogonal.EdgeLayoutDescriptor instances for each edge in the graph.
OrthogonalGroupLayouter
Property Detail
alignDegreeOneNodesproperty
alignDegreeOneNodes:Boolean

Specifies whether the algorithm should try to align degree-one nodes that have the same neighbour. The default is false.


Implementation
    public function get alignDegreeOneNodes():Boolean
    public function set alignDegreeOneNodes(value:Boolean):void
componentLayouterproperty 
componentLayouter:LayoutStage[override]

Note that the component layouter set here should work in such a way that isolated components inside groups should be reported separately. E.g. instances of com.yworks.yfiles.layout.grouping.IsolatedGroupComponentLayouter can be set here. If the component layouter should be customized, the suggested way of doing this is to componentLayouter and cast it to com.yworks.yfiles.layout.ComponentLayouter.


Implementation
    public function get componentLayouter():LayoutStage
    public function set componentLayouter(value:LayoutStage):void

See also

considerNodeLabelsproperty 
considerNodeLabels:Boolean

Getter: Returns whether or not node labels are taken into account when calculating node positions (thereby preventing possible node/node label or node label/node label overlaps). This method is a convenience method checks whether the label layouter (com.yworks.yfiles.layout.CanonicMultiStageLayouter.labelLayouter) is of type com.yworks.yfiles.layout.LabelLayoutTranslator and com.yworks.yfiles.layout.LabelLayoutTranslator.translateNodeLabels returns true. The default is false.

Setter: Specifies whether or not to consider node labels when calculating node positions (thereby preventing possible node/node label or node label/node label overlaps). This method is a convenience method that assures that the label layouter (com.yworks.yfiles.layout.CanonicMultiStageLayouter.labelLayouter) is of type com.yworks.yfiles.layout.LabelLayoutTranslator and com.yworks.yfiles.layout.LabelLayoutTranslator.translateNodeLabels is set to true. Note that setting this option may overwrite the currently set label layouter. Hence, to combine this option with a generic edge labeling algorithm, the generic labeling has to be applied in an additional step after calculating the layout.


Implementation
    public function get considerNodeLabels():Boolean
    public function set considerNodeLabels(value:Boolean):void

Throws
Error — if the current label layouter is not of type com.yworks.yfiles.layout.LabelLayoutTranslator.

See also

edgeLayoutDescriptorproperty 
edgeLayoutDescriptor:EdgeLayoutDescriptor

Specifies the EdgeLayoutDescriptor instance used for all those edges, that do not have a specific layout descriptor assigned.


Implementation
    public function get edgeLayoutDescriptor():EdgeLayoutDescriptor
    public function set edgeLayoutDescriptor(value:EdgeLayoutDescriptor):void

Throws
ReferenceError — if the argument is null

See also

gridproperty 
grid:int

Specifies the grid distance.


Implementation
    public function get grid():int
    public function set grid(value:int):void
integratedEdgeLabelingproperty 
integratedEdgeLabeling:Boolean

Getter: Returns whether integrated edge labeling is enabled. This method is a convenience method that checks if the label layouter (com.yworks.yfiles.layout.CanonicMultiStageLayouter.labelLayouter) is of type com.yworks.yfiles.layout.LabelLayoutTranslator and com.yworks.yfiles.layout.LabelLayoutTranslator.translateEdgeLabels returns true. The default is false.

Setter: Specifies whether or not to use integrated edge labeling. This method is a convenience method that assures that the label layouter (com.yworks.yfiles.layout.CanonicMultiStageLayouter.labelLayouter) is of type com.yworks.yfiles.layout.LabelLayoutTranslator and com.yworks.yfiles.layout.LabelLayoutTranslator.translateEdgeLabels is set to true


Implementation
    public function get integratedEdgeLabeling():Boolean
    public function set integratedEdgeLabeling(value:Boolean):void

Throws
Error — if the current label layouter is not of type com.yworks.yfiles.layout.LabelLayoutTranslator.

See also

layoutQualityproperty 
layoutQuality:Number

Getter: Returns the currently set layout quality.

Setter: Sets the desired layout quality. Higher quality means less connection crossings and smaller layout area, but also increased computation time.

By default best layout quality (value 1) is set.


Implementation
    public function get layoutQuality():Number
    public function set layoutQuality(value:Number):void
optimizePerceivedBendsproperty 
optimizePerceivedBends:Boolean

Specifies whether the algorithm should perform a post processing algorithm to reduce perceived bends in the drawing. The default is false.


Implementation
    public function get optimizePerceivedBends():Boolean
    public function set optimizePerceivedBends(value:Boolean):void
postprocessingEnabledproperty 
postprocessingEnabled:Boolean

Specifies if an additional postprocessing step is used that improves compactness and reduces the number of edge bends. The postprocessing is enabled by default.


Implementation
    public function get postprocessingEnabled():Boolean
    public function set postprocessingEnabled(value:Boolean):void
Constructor Detail
OrthogonalGroupLayouter()Constructor
public function OrthogonalGroupLayouter(init:Boolean = true)

Creates a new instance of OrthogonalGroupLayouter

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.
Method Detail
canLayoutCore()method
override public function canLayoutCore(graph:LayoutGraph):Boolean

Parameters

graph:LayoutGraph

Returns
Boolean
createEdgeLayoutDescriptor()method 
protected function createEdgeLayoutDescriptor():EdgeLayoutDescriptor

Factory method that creates the default EdgeLayoutDescriptor. May not return null!

Returns
EdgeLayoutDescriptor — a new EdgeLayoutDescriptor (new EdgeLayoutDescriptor())
doLayout()method 
override public function doLayout(graph:LayoutGraph):void

Parameters

graph:LayoutGraph

doLayoutCore()method 
override public function doLayoutCore(graph:LayoutGraph):void

Parameters

graph:LayoutGraph

getClass()method 
override public function getClass():Class

Returns
Class
initOrthogonalGroupLayouter()method 
protected final function initOrthogonalGroupLayouter():void

Initializes this object. See the documentation of the corresponding factory method newOrthogonalGroupLayouter() for details.

See also

newOrthogonalGroupLayouter()method 
public static function newOrthogonalGroupLayouter():OrthogonalGroupLayouter

Creates a new instance of OrthogonalGroupLayouter

Returns
OrthogonalGroupLayouter
Constant Detail
EDGE_LAYOUT_DESCRIPTOR_DPKEYConstant
public static const EDGE_LAYOUT_DESCRIPTOR_DPKEY:Object = y.layout.orthogonal.OrthogonalLayouter.EDGE_LAYOUT_DESCRIPTOR_DPKEY

com.yworks.yfiles.base.DataProvider key used to retrieve com.yworks.yfiles.layout.orthogonal.EdgeLayoutDescriptor instances for each edge in the graph. Different settings will affect the routing of the edges during the layout.

See also