Packagecom.yworks.yfiles.layout.tree
Classpublic class GenericTreeLayouter_SubtreeShape
InheritanceGenericTreeLayouter_SubtreeShape Inheritance YObject Inheritance Object

Instances of this class are used to represent the shape of subtrees during the layout.



Public Properties
 PropertyDefined By
  bounds : Rectangle2D
[read-only] Returns the current bounds of this SubtreeShape
GenericTreeLayouter_SubtreeShape
  connectorDirection : int
[read-only] Returns the direction byte constant as defined in this class, that indicates the direction of the last connecting edge segment.
GenericTreeLayouter_SubtreeShape
  connectorX : Number
[read-only] Returns the current x coordinate of the connection point where the layout algorithm should connect the ingoing edge to.
GenericTreeLayouter_SubtreeShape
  connectorY : Number
[read-only] Returns the current y coordinate of the connection point where the layout algorithm should connect the ingoing edge to.
GenericTreeLayouter_SubtreeShape
  coreBounds : Rectangle2DDouble
[read-only] Yields the bounds of the com.yworks.yfiles.layout.NodeLayout of the root node.
GenericTreeLayouter_SubtreeShape
  maxX : Number
[read-only] Returns the current maximum x coordinate of this shape.
GenericTreeLayouter_SubtreeShape
  maxY : Number
[read-only] Returns the current maximum y coordinate of this shape.
GenericTreeLayouter_SubtreeShape
  minX : Number
[read-only] Returns the current minimal x coordinate of this shape.
GenericTreeLayouter_SubtreeShape
  minY : Number
[read-only] Returns the current minimal y coordinate of this shape.
GenericTreeLayouter_SubtreeShape
  originX : Number
[read-only] Returns the current x coordinate of the origin of this shape.
GenericTreeLayouter_SubtreeShape
  originY : Number
[read-only] Returns the current y coordinate of the origin of this shape.
GenericTreeLayouter_SubtreeShape
Public Methods
 MethodDefined By
  
GenericTreeLayouter_SubtreeShape
  
addBoundsToShape(x:Number, y:Number, width:Number, height:Number):void
Adds a rectangular shape to the current shape.
GenericTreeLayouter_SubtreeShape
  
Helper method that takes all edge segments of the given Edge instance and updates the shape bounds with that information.
GenericTreeLayouter_SubtreeShape
  
addLineSegment(x1:Number, y1:Number, x2:Number, y2:Number):void
Convenience method that updates the shape to respect the given line segment.
GenericTreeLayouter_SubtreeShape
  
addTargetPoint(x:Number, y:Number):void
Adds another point to the connecting edge (away from the target node).
GenericTreeLayouter_SubtreeShape
  
Appends all target points that have previously been added to this shape to the given EdgeLayout instance.
GenericTreeLayouter_SubtreeShape
  
Copies this instance to another shape, applying a modification matrix.
GenericTreeLayouter_SubtreeShape
  
Creates a clone of this instance, modifying it using the provided matrix.
GenericTreeLayouter_SubtreeShape
 Inherited
equals(o:Object):Boolean
YObject
  
Returns the BorderLine instance for the given direction.
GenericTreeLayouter_SubtreeShape
  
getClass():Class
[override]
GenericTreeLayouter_SubtreeShape
 Inherited
hashCode():int
YObject
  
Merges the given SubtreeShape with this shape's bounds.
GenericTreeLayouter_SubtreeShape
  
move(dx:Number, dy:Number):void
Moves this shape and its connector by the given offsets.
GenericTreeLayouter_SubtreeShape
  
toString():String
GenericTreeLayouter_SubtreeShape
  
Adds the line segments of the connector shape to the bounds and borderlines of this SubTreeShape
GenericTreeLayouter_SubtreeShape
Public Constants
 ConstantDefined By
  BORDERLINE_EAST : int = 1
[static] Side constant used by getBorderLine().
GenericTreeLayouter_SubtreeShape
  BORDERLINE_NORTH : int = 0
[static] Side constant used by getBorderLine().
GenericTreeLayouter_SubtreeShape
  BORDERLINE_SOUTH : int = 2
[static] Side constant used by getBorderLine().
GenericTreeLayouter_SubtreeShape
  BORDERLINE_WEST : int = 3
[static] Side constant used by getBorderLine().
GenericTreeLayouter_SubtreeShape
  DIRECTION_EAST : int = 2
[static] Direction constant used by connectorDirection.
GenericTreeLayouter_SubtreeShape
  DIRECTION_NORTH : int = 1
[static] Direction constant used by connectorDirection.
GenericTreeLayouter_SubtreeShape
  DIRECTION_SOUTH : int = 4
[static] Direction constant used by connectorDirection.
GenericTreeLayouter_SubtreeShape
  DIRECTION_WEST : int = 8
[static] Direction constant used by connectorDirection.
GenericTreeLayouter_SubtreeShape
Property Detail
boundsproperty
bounds:Rectangle2D  [read-only]

Returns the current bounds of this SubtreeShape


Implementation
    public function get bounds():Rectangle2D
connectorDirectionproperty 
connectorDirection:int  [read-only]

Returns the direction byte constant as defined in this class, that indicates the direction of the last connecting edge segment.


Implementation
    public function get connectorDirection():int

See also

connectorXproperty 
connectorX:Number  [read-only]

Returns the current x coordinate of the connection point where the layout algorithm should connect the ingoing edge to.


Implementation
    public function get connectorX():Number
connectorYproperty 
connectorY:Number  [read-only]

Returns the current y coordinate of the connection point where the layout algorithm should connect the ingoing edge to.


Implementation
    public function get connectorY():Number
coreBoundsproperty 
coreBounds:Rectangle2DDouble  [read-only]

Yields the bounds of the com.yworks.yfiles.layout.NodeLayout of the root node.


Implementation
    public function get coreBounds():Rectangle2DDouble

See also

maxXproperty 
maxX:Number  [read-only]

Returns the current maximum x coordinate of this shape.


Implementation
    public function get maxX():Number
maxYproperty 
maxY:Number  [read-only]

Returns the current maximum y coordinate of this shape.


Implementation
    public function get maxY():Number
minXproperty 
minX:Number  [read-only]

Returns the current minimal x coordinate of this shape.


Implementation
    public function get minX():Number
minYproperty 
minY:Number  [read-only]

Returns the current minimal y coordinate of this shape.


Implementation
    public function get minY():Number
originXproperty 
originX:Number  [read-only]

Returns the current x coordinate of the origin of this shape. The origin is defined as the upper left corner of the NodeLayout of the local root of this shape.


Implementation
    public function get originX():Number
originYproperty 
originY:Number  [read-only]

Returns the current y coordinate of the origin of this shape. The origin is defined as the upper left corner of the NodeLayout of the local root of this shape.


Implementation
    public function get originY():Number
Constructor Detail
GenericTreeLayouter_SubtreeShape()Constructor
public function GenericTreeLayouter_SubtreeShape(init:Boolean = true)



Parameters
init:Boolean (default = true)
Method Detail
addBoundsToShape()method
public function addBoundsToShape(x:Number, y:Number, width:Number, height:Number):void

Adds a rectangular shape to the current shape.

Parameters

x:Number
 
y:Number
 
width:Number
 
height:Number

addEdgeSegments()method 
public function addEdgeSegments(lg:LayoutGraph, e:Edge):void

Helper method that takes all edge segments of the given Edge instance and updates the shape bounds with that information.

Parameters

lg:LayoutGraph — the LayoutGraph that contains the edge
 
e:Edge — the edge whose path will be used to update the shape

addLineSegment()method 
public function addLineSegment(x1:Number, y1:Number, x2:Number, y2:Number):void

Convenience method that updates the shape to respect the given line segment.

Parameters

x1:Number
 
y1:Number
 
x2:Number
 
y2:Number

addTargetPoint()method 
public function addTargetPoint(x:Number, y:Number):void

Adds another point to the connecting edge (away from the target node).

Parameters

x:Number — the current x coordinate of the point
 
y:Number — the current x coordinate of the point

appendTargetPoints()method 
public function appendTargetPoints(el:EdgeLayout):void

Appends all target points that have previously been added to this shape to the given EdgeLayout instance. Used by NodePlacer instances for the final edge connections.

Parameters

el:EdgeLayout — the EdgeLayout that will be modified

assignValuesTo()method 
public function assignValuesTo(toShape:GenericTreeLayouter_SubtreeShape, modificationMatrix:AbstractRotatableNodePlacer_Matrix):void

Copies this instance to another shape, applying a modification matrix.

Parameters

toShape:GenericTreeLayouter_SubtreeShape
 
modificationMatrix:AbstractRotatableNodePlacer_Matrix

createCopy()method 
public function createCopy(matrix:AbstractRotatableNodePlacer_Matrix):GenericTreeLayouter_SubtreeShape

Creates a clone of this instance, modifying it using the provided matrix.

Parameters

matrix:AbstractRotatableNodePlacer_Matrix

Returns
GenericTreeLayouter_SubtreeShape
getBorderLine()method 
public function getBorderLine(index:int):BorderLine

Returns the BorderLine instance for the given direction.

Parameters

index:int — the direction index where BORDERLINE_NORTH is north, BORDERLINE_EAST is east, BORDERLINE_SOUTH is south, and BORDERLINE_WEST is west.

Returns
BorderLine — the current com.yworks.yfiles.geom.BorderLine instance

See also

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

Returns
Class
mergeWith()method 
public function mergeWith(other:GenericTreeLayouter_SubtreeShape):void

Merges the given SubtreeShape with this shape's bounds.

Parameters

other:GenericTreeLayouter_SubtreeShape — the shape to be merged with this shape

move()method 
public function move(dx:Number, dy:Number):void

Moves this shape and its connector by the given offsets. This is a cheap operation and does not depend on the size or complexity of the shape or connector.

Parameters

dx:Number — the delta x offset this shape will be moved by
 
dy:Number — the delta y offset this shape will be moved by

toString()method 
public function toString():String

Returns
String
updateConnectorShape()method 
public function updateConnectorShape():void

Adds the line segments of the connector shape to the bounds and borderlines of this SubTreeShape

Constant Detail
BORDERLINE_EASTConstant
public static const BORDERLINE_EAST:int = 1

Side constant used by getBorderLine().

See also

BORDERLINE_NORTHConstant 
public static const BORDERLINE_NORTH:int = 0

Side constant used by getBorderLine().

See also

BORDERLINE_SOUTHConstant 
public static const BORDERLINE_SOUTH:int = 2

Side constant used by getBorderLine().

See also

BORDERLINE_WESTConstant 
public static const BORDERLINE_WEST:int = 3

Side constant used by getBorderLine().

See also

DIRECTION_EASTConstant 
public static const DIRECTION_EAST:int = 2

Direction constant used by connectorDirection.

See also

DIRECTION_NORTHConstant 
public static const DIRECTION_NORTH:int = 1

Direction constant used by connectorDirection.

See also

DIRECTION_SOUTHConstant 
public static const DIRECTION_SOUTH:int = 4

Direction constant used by connectorDirection.

See also

DIRECTION_WESTConstant 
public static const DIRECTION_WEST:int = 8

Direction constant used by connectorDirection.

See also