Packagecom.yworks.yfiles.layout
Classpublic class DefaultNodeLayout
InheritanceDefaultNodeLayout Inheritance YObject Inheritance Object
Implements NodeLayout

This class is a default implementation of the NodeLayout interface.



Public Properties
 PropertyDefined By
  height : Number
[read-only]
DefaultNodeLayout
  width : Number
[read-only]
DefaultNodeLayout
  x : Number
[read-only]
DefaultNodeLayout
  y : Number
[read-only]
DefaultNodeLayout
Protected Properties
 PropertyDefined By
  h : Number
Holds the height of the node layout bounds.
DefaultNodeLayout
  w : Number
Holds the width of the node layout bounds.
DefaultNodeLayout
  _x : Number
Holds the minimal x-coordinates of the node layout bounds.
DefaultNodeLayout
  _y : Number
Holds the minimal y-coordinates of the node layout bounds.
DefaultNodeLayout
Public Methods
 MethodDefined By
  
DefaultNodeLayout(init:Boolean = true)
Creates a new instance of DefaultNodeLayout.
DefaultNodeLayout
 Inherited
equals(o:Object):Boolean
YObject
  
getClass():Class
[override]
DefaultNodeLayout
 Inherited
hashCode():int
YObject
  
[static] Creates a new instance of DefaultNodeLayout.
DefaultNodeLayout
  
[static] Creates a new instance of DefaultNodeLayout as copy of another instance of NodeLayout.
DefaultNodeLayout
  
[static] Creates a new instance of DefaultNodeLayout.
DefaultNodeLayout
  
newDefaultNodeLayout4(x:Number, y:Number, width:Number, height:Number):DefaultNodeLayout
[static] Creates a new instance of DefaultNodeLayout.
DefaultNodeLayout
  
setCenter(x:Number, y:Number):void
Sets the center coordinates of the node.
DefaultNodeLayout
  
setLocation(x:Number, y:Number):void
DefaultNodeLayout
  
setSize(width:Number, height:Number):void
DefaultNodeLayout
Protected Methods
 MethodDefined By
  
Initializes this object.
DefaultNodeLayout
  
Initializes this object.
DefaultNodeLayout
  
Initializes this object.
DefaultNodeLayout
  
initDefaultNodeLayout4(x:Number, y:Number, width:Number, height:Number):void
Initializes this object.
DefaultNodeLayout
Property Detail
_xproperty
protected var _x:Number

Holds the minimal x-coordinates of the node layout bounds.

_yproperty 
protected var _y:Number

Holds the minimal y-coordinates of the node layout bounds.

hproperty 
protected var h:Number

Holds the height of the node layout bounds.

heightproperty 
height:Number  [read-only]


Implementation
    public function get height():Number
wproperty 
protected var w:Number

Holds the width of the node layout bounds.

widthproperty 
width:Number  [read-only]


Implementation
    public function get width():Number
xproperty 
x:Number  [read-only]


Implementation
    public function get x():Number
yproperty 
y:Number  [read-only]


Implementation
    public function get y():Number
Constructor Detail
DefaultNodeLayout()Constructor
public function DefaultNodeLayout(init:Boolean = true)

Creates a new instance of DefaultNodeLayout.

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
getClass()method
override public function getClass():Class

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

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

See also

initDefaultNodeLayout2()method 
protected final function initDefaultNodeLayout2(layout:NodeLayout):void

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

Parameters

layout:NodeLayout

See also

initDefaultNodeLayout3()method 
protected final function initDefaultNodeLayout3(location:YPoint, size:YDimension):void

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

Parameters

location:YPoint
 
size:YDimension

See also

initDefaultNodeLayout4()method 
protected final function initDefaultNodeLayout4(x:Number, y:Number, width:Number, height:Number):void

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

Parameters

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

See also

newDefaultNodeLayout1()method 
public static function newDefaultNodeLayout1():DefaultNodeLayout

Creates a new instance of DefaultNodeLayout.

Returns
DefaultNodeLayout
newDefaultNodeLayout2()method 
public static function newDefaultNodeLayout2(layout:NodeLayout):DefaultNodeLayout

Creates a new instance of DefaultNodeLayout as copy of another instance of NodeLayout.

Parameters

layout:NodeLayout — another instance of NodeLayout.

Returns
DefaultNodeLayout
newDefaultNodeLayout3()method 
public static function newDefaultNodeLayout3(location:YPoint, size:YDimension):DefaultNodeLayout

Creates a new instance of DefaultNodeLayout.

Parameters

location:YPoint — the upper-left corner coordinate of the node layout.
 
size:YDimension — the size of the node layout.

Returns
DefaultNodeLayout
newDefaultNodeLayout4()method 
public static function newDefaultNodeLayout4(x:Number, y:Number, width:Number, height:Number):DefaultNodeLayout

Creates a new instance of DefaultNodeLayout.

Parameters

x:Number — the x-coordinate of the upper left corner of the node.
 
y:Number — the y-coordinate of the upper left corner of the node.
 
width:Number — the width of the node.
 
height:Number — the height of the node.

Returns
DefaultNodeLayout
setCenter()method 
public function setCenter(x:Number, y:Number):void

Sets the center coordinates of the node.

Parameters

x:Number — the x-coordinates of the center.
 
y:Number — the y-coordinates of the center

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

Parameters

x:Number
 
y:Number

setSize()method 
public function setSize(width:Number, height:Number):void

Parameters

width:Number
 
height:Number