| Package | org.un.flex.graphLayout.layout |
| Class | public class BaseLayoutDrawing |
| Subclasses | ConcentricRadialLayoutDrawing, HierarchicalLayoutDrawing, ParentCenteredDrawingModel, PhylloTreeDrawingModel |
| Property | Defined by | ||
|---|---|---|---|
| centeredLayout : Boolean
Specifies if the center offset should be applied
or not.
| BaseLayoutDrawing | ||
| centerOffset : Point
Access to the offset of the center of the layout.
| BaseLayoutDrawing | ||
| originOffset : Point
Access to the offset of the origin of the layout.
| BaseLayoutDrawing | ||
| Method | Defined by | ||
|---|---|---|---|
|
The constructor just initializes the internal data structures.
| BaseLayoutDrawing | ||
|
getAbsCartCoordinates(n:INode):Point
Access the absolute cartesian coordinates of the given node.
| BaseLayoutDrawing | ||
|
getPolarPhi(n:INode):Number
access the polar angle part of the
target coordinates of the given node.
| BaseLayoutDrawing | ||
|
access the polar radius part of the
target coordinates of the given node.
| BaseLayoutDrawing | ||
|
getRelCartCoordinates(n:INode):Point
Access the cartesian coordinates of the given node.
| BaseLayoutDrawing | ||
|
invalidateNodeData():void
invalidate all node data sets
| BaseLayoutDrawing | ||
|
nodeDataValid(n:INode):Boolean
indicates if the data set for a given node is
currently valid.
| BaseLayoutDrawing | ||
|
setCartCoordinates(n:INode, p:Point):void
Set the target coordinates for node n according to the
calculated layout in cartesian (i.e.
| BaseLayoutDrawing | ||
|
setPolarCoordinates(n:INode, polarR:Number, polarPhi:Number):void
Set the target coordinates for node n according to the
calculated layout in Polar form.
| BaseLayoutDrawing | ||
| centeredLayout | property |
centeredLayout:Boolean [read-write]Specifies if the center offset should be applied or not.
This property can be used as the source for data binding.
Implementation public function get centeredLayout():Boolean
public function set centeredLayout(value:Boolean):void
| centerOffset | property |
centerOffset:Point [read-write]Access to the offset of the center of the layout. The actual origin is the upper left corner of the canvas. But the calculation of this layout is done around circles around the origin. So we want to move the origin into the center of the canvas, This is what the center offset actually does.
This property can be used as the source for data binding.
Implementation public function get centerOffset():Point
public function set centerOffset(value:Point):void
| originOffset | property |
originOffset:Point [read-write]Access to the offset of the origin of the layout. The actual origin is the upper left corner of the canvas. But that changes if we scroll the canvas around, so we have to keep track of this offset.
This property can be used as the source for data binding.
Implementation public function get originOffset():Point
public function set originOffset(value:Point):void
| BaseLayoutDrawing | () | constructor |
public function BaseLayoutDrawing()The constructor just initializes the internal data structures.
| getAbsCartCoordinates | () | method |
public function getAbsCartCoordinates(n:INode):PointAccess the absolute cartesian coordinates of the given node. These are the absolute coordinates with the origin offset already applied.
Parametersn:INode — The node which target coordinates are required.
|
Point — A Point object that contains the required absolute coordinates.
|
| getPolarPhi | () | method |
public function getPolarPhi(n:INode):Numberaccess the polar angle part of the target coordinates of the given node. These are relative coordinates (subject to origin offset).
Parametersn:INode — The node which target coordinate is required.
|
Number — The angle part of n's target coordinates (in polar).
|
| getPolarR | () | method |
public function getPolarR(n:INode):Numberaccess the polar radius part of the target coordinates of the given node. These are relative coordinates (subject to origin offset).
Parametersn:INode — The node which target coordinate is required.
|
Number — The radius part of n's target coordinates (in polar).
|
| getRelCartCoordinates | () | method |
public function getRelCartCoordinates(n:INode):PointAccess the cartesian coordinates of the given node. These are relative coordinates (subject to origin offset).
Parametersn:INode — The node which target coordinates are required.
|
Point — A Point object that contains the required coordinates.
|
| invalidateNodeData | () | method |
public function invalidateNodeData():voidinvalidate all node data sets
| nodeDataValid | () | method |
public function nodeDataValid(n:INode):Booleanindicates if the data set for a given node is currently valid. WARNING: may not be implemented properly and may not even be needed
Parametersn:INode — The node for which dataset the validity should be tested.
|
Boolean — If the dataset for node n is valid.
|
| setCartCoordinates | () | method |
public function setCartCoordinates(n:INode, p:Point):voidSet the target coordinates for node n according to the calculated layout in cartesian (i.e. x and y) form. Consider these are "relative" coordinates, which will finally be adjusted by the origin offset.
Parametersn:INode — The node to set its coordinates.
|
|
p:Point — The point object representing the target coordinates.
|
| setPolarCoordinates | () | method |
public function setPolarCoordinates(n:INode, polarR:Number, polarPhi:Number):voidSet the target coordinates for node n according to the calculated layout in Polar form. Consider these are "relative" coordinates, which will finally be adjusted by the origin offset.
Parametersn:INode — The node to set its coordinates.
|
|
polarR:Number — The radius (length) part of the polar coordinates.
|
|
polarPhi:Number — The angle part of the polar coordinates (in degrees).
|
— error if any part of the coordinates is NaN (not a number).
|