Packagecom.kapit.diagram.ui
Classpublic class DiagramLinkOrthogonalUI
InheritanceDiagramLinkOrthogonalUI Inheritance DiagramLinkUI Inheritance DiagramObjectUI Inheritance mx.core.UIComponent



Public Properties
 PropertyDefined by
 Inheritedinnerheight : Number
The inner height of this component.
DiagramObjectUI
 Inheritedinnerleft : Number
The inner left position (X coordinate).
DiagramObjectUI
 Inheritedinnertop : Number
The inner top position (Y coordinate).
DiagramObjectUI
 Inheritedinnerwidth : Number
The inner width of this component.
DiagramObjectUI
 Inheritedlocked : Boolean
Locked property that defines if the UI is locked, meaning it can't be inactivated.
DiagramObjectUI
 Inheritedouterheight : Number
The outer height of this component.
DiagramObjectUI
 Inheritedouterwidth : Number
The outer width of this component.
DiagramObjectUI
 Inheritedsource : DiagramObject
Source property that defines the Diagram Object to which this DiagramObjectUI is linked.
DiagramObjectUI
Protected Properties
 PropertyDefined by
 Inherited_activated : Boolean = false
Activation status of the DiagramObjectUI.
DiagramObjectUI
 Inherited_annotatebutton : AnnotateButton = null
DiagramLinkUI
 Inherited_cssinitialized : Boolean
[static]
DiagramLinkUI
 Inherited_curpointidx : int = -1
Current point index.
DiagramLinkUI
 Inherited_curuihandler : Function = null
Used UI Handler (dependant to cursor selection).
DiagramLinkUI
  _delhandlers : Array
Array of handlers used for deleting some link elements
DiagramLinkOrthogonalUI
 Inherited_dlink : DiagramLink = null
Diagram Link to which this DiagramLinkUI is linked.
DiagramLinkUI
 Inherited_knobfill : Number
[static] Knob fill style property (color number).
DiagramLinkUI
 Inherited_knobfillopacity : Number
[static] Knob fill opacity style property (color number).
DiagramLinkUI
 Inherited_knoblinecolor : Number
[static] Knob line color style property (color number).
DiagramLinkUI
 Inherited_knoblineopacity : Number
[static] Knob line opacity style property (percentage number).
DiagramLinkUI
 Inherited_knoblinewidth : Number
[static] Knob line width style property.
DiagramLinkUI
 Inherited_selectedstyleselector : String = "null"
[static] Selected style selector String representation.
DiagramLinkUI
 Inheritedselectedstyleselector : String
[static] The selected style selector.
DiagramLinkUI
 Inherited_selidx : int = -1
Selected point index.
DiagramLinkUI
 Inherited_selknobfill : Number
[static] Selected Knob fill style property (color number).
DiagramLinkUI
 Inherited_selknobfillopacity : Number
[static] Selected Knob fill opacity style property (color number).
DiagramLinkUI
 Inherited_selknoblinecolor : Number
[static] Selected Knob line color style property (color number).
DiagramLinkUI
 Inherited_selknoblineopacity : Number
[static] Selected Knob line opacity style property (percentage number).
DiagramLinkUI
 Inherited_selknoblinewidth : Number
[static] Selected Knob line width style property.
DiagramLinkUI
 Inherited_source : DiagramObject = null
The Diagram Object to which this DiagramObjectUI is linked.
DiagramObjectUI
 Inherited_styleselector : String = "null"
[static] "Not Selected Knob" style selector String representation.
DiagramLinkUI
 Inheritedstyleselector : String
[static] The style sector used in this DiagramLinkUI.
DiagramLinkUI
  _uihandlers : Array
Array of handlers used for editing some link elements
DiagramLinkOrthogonalUI
Public Methods
 MethodDefined by
  
DiagramLinkOrthogonalUI
 Inherited
activate(a:Boolean):void
Activates or deactivates this DiagramObjectUI by adding or removing action and mouse listeners to the source Diagram Object View.
DiagramObjectUI
 Inherited
clear():void
DiagramLinkUI
 Inherited
Clears selection by updating the selection index (no selection).
DiagramLinkUI
 Inherited
draw():void
Draws this DiagramLinkUI elements respecting the control points and line styling.
DiagramLinkUI
  
execute(k:int, event:MouseEvent = null):void
Executes a link modification/transformation (inserting and moving knobs (articulations) and anchors) operation given a mouse event and an index telling selected point, link modification type and required UI handlers.
DiagramLinkOrthogonalUI
 Inherited
fitToObject(dlink:DiagramObject = null):void
Updates this DiagramLinkUI position in order to fit its container or its correspondant DiagramLink.
DiagramLinkUI
  
hitTest(m:Point):int
Determines the Diagram hit type given a point (cursor hit position) meaning determining what the cursor hits.
DiagramLinkOrthogonalUI
 Inherited
Redraws this DiagramObjectUI and its children when library styles and assets change given a SVGAssetLibraryEvent.
DiagramObjectUI
 Inherited
unlink():void
Unlinks and removes the Diagram Object UI from its parent (usually used when deleting Diagram Objects).
DiagramObjectUI
 Inherited
update():void
DiagramObjectUI
Protected Methods
 MethodDefined by
 Inherited
Defining Diagram Object UI behaviour and children status while a given action is running (after detecting an ActionManagerEvent).
DiagramObjectUI
 Inherited
Defining Diagram Object UI behaviour and children status when a given action stops running (after detecting an ActionManagerEvent).
DiagramObjectUI
 Inherited
annotateHandler(event:MouseEvent):void
DiagramLinkUI
 Inherited
DiagramLinkUI
 Inherited
DiagramLinkUI
 Inherited
cssInitialize():Boolean
[static] Initialises SVG libraries (icons and graphics) and sets new style properties (CSS).
DiagramLinkUI
  
delKnobHandler(event:KeyboardEvent):void
Delete a standard knob from this DiagramLinkUI and updates point selection and control points array.
DiagramLinkOrthogonalUI
  
delSourceAnchorHandler(event:KeyboardEvent):void
Delete a source anchor from this DiagramLinkUI and updates point selection and control points array.
DiagramLinkOrthogonalUI
  
delSourceKnobHandler(event:KeyboardEvent):void
DiagramLinkOrthogonalUI
  
delTargetAnchorHandler(event:KeyboardEvent):void
Delete a target anchor from this DiagramLinkUI and updates point selection and control points array.
DiagramLinkOrthogonalUI
  
delTargetKnobHandler(event:KeyboardEvent):void
Delete a target knob from this DiagramLinkUI and updates point selection and control points array.
DiagramLinkOrthogonalUI
  
insertKnobs(event:MouseEvent):void
Inserts new knobs in this Diagram link UI for more user customization abilities and easier manipulation.
DiagramLinkOrthogonalUI
  
keyUpHandler(event:KeyboardEvent):void
Activates adequate delete handlers according to a keyboard event (Delete or Backspace) and to the selected point (point context).
DiagramLinkOrthogonalUI
  
knobHandler(event:MouseEvent):void
Handles any knob (except knob linked to source or target Diagram UIs) manipulation and updates user modifications in the correspondant DiagramLink (knob position update in the diagram drawing).
DiagramLinkOrthogonalUI
 Inherited
mouseDownHandler(event:MouseEvent):void
Detects a mouse down event and executes a defined action set in the execute method according to hitTest result.
DiagramObjectUI
 Inherited
mouseMoveHandler(event:MouseEvent):void
Applies link modification/transformation operations while moving the cursor according to selected UI handler (defined by the execute method).
DiagramLinkUI
 Inherited
mouseUpHandler(event:MouseEvent):void
Finalizes the link modification or transformation operation after a mouse up event and removes all listeners.
DiagramLinkUI
  
segHandler(event:MouseEvent):void
Handles any segment (except segments linked to source or target Diagram UIs) manipulation and updates user modifications in the correspondant DiagramLink (master and target anchors updates).
DiagramLinkOrthogonalUI
 Inherited
DiagramLinkUI
  
sourceAnchorHandler(event:MouseEvent):void
Handles source anchor manipulation and updates user modifications in the correspondant DiagramLink (master anchor point update).
DiagramLinkOrthogonalUI
  
sourceKnobHandler(event:MouseEvent):void
Handles source knob (linked to a source Diagram UI)manipulation and updates user modifications in the correspondant DiagramLink (master anchor point update).
DiagramLinkOrthogonalUI
  
sourceSegHandler(event:MouseEvent):void
Handles source link segment started from the source manipulation and updates user modifications in the correspondant DiagramLink(master anchor point update).
DiagramLinkOrthogonalUI
  
sourceTargetKnobHandler(event:MouseEvent):void
Handles source target knob manipulation and updates user modifications in the correspondant DiagramLink (master and target anchors updates).
DiagramLinkOrthogonalUI
 Inherited
[static] Changes the currently used CSS style when an SVGAssetLibraryEvent is triggered.
DiagramLinkUI
  
targetAnchorHandler(event:MouseEvent):void
Handles target anchor (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchors updates).
DiagramLinkOrthogonalUI
  
targetKnobHandler(event:MouseEvent):void
Handles target Knob (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchor update).
DiagramLinkOrthogonalUI
  
targetSegHandler(event:MouseEvent):void
Handles target segment (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchors updates).
DiagramLinkOrthogonalUI
Public Constants
 ConstantDefined by
 InheritedKNOBSIZE : Number = 8
[static] Square side of the Knob.
DiagramLinkUI
Property detail
_delhandlersproperty
protected var _delhandlers:Array

Array of handlers used for deleting some link elements

_uihandlersproperty 
protected var _uihandlers:Array

Array of handlers used for editing some link elements

Constructor detail
DiagramLinkOrthogonalUI()constructor
public function DiagramLinkOrthogonalUI(dlink:DiagramLink)Parameters
dlink:DiagramLink
Method detail
delKnobHandler()method
protected function delKnobHandler(event:KeyboardEvent):void

Delete a standard knob from this DiagramLinkUI and updates point selection and control points array.

Parameters
event:KeyboardEvent — Detected Keyboard Event.
delSourceAnchorHandler()method 
protected function delSourceAnchorHandler(event:KeyboardEvent):void

Delete a source anchor from this DiagramLinkUI and updates point selection and control points array.

Parameters
event:KeyboardEvent — Detected Keyboard Event.
delSourceKnobHandler()method 
protected function delSourceKnobHandler(event:KeyboardEvent):voidParameters
event:KeyboardEvent
delTargetAnchorHandler()method 
protected function delTargetAnchorHandler(event:KeyboardEvent):void

Delete a target anchor from this DiagramLinkUI and updates point selection and control points array.

Parameters
event:KeyboardEvent — Detected Keyboard Event.
delTargetKnobHandler()method 
protected function delTargetKnobHandler(event:KeyboardEvent):void

Delete a target knob from this DiagramLinkUI and updates point selection and control points array.

Parameters
event:KeyboardEvent — Detected Keyboard Event.
execute()method 
public override function execute(k:int, event:MouseEvent = null):void

Executes a link modification/transformation (inserting and moving knobs (articulations) and anchors) operation given a mouse event and an index telling selected point, link modification type and required UI handlers. Handlers are listed as follows (index in _uihandlers array):

Parameters
k:int — Index (Handler and Control point).
 
event:MouseEvent (default = null) — Detected Mouse Event.
hitTest()method 
public override function hitTest(m:Point):int

Determines the Diagram hit type given a point (cursor hit position) meaning determining what the cursor hits. If the cursor hits a control point, the hitTest function returns an index extracted from the points array (even if horizontal position, odd else). This index if divided (integer division) returns the selected control point.

Parameters
m:Point — Hit point (cursor hit position).

Returns
int — Diagram Hit Type index (Index).
insertKnobs()method 
protected override function insertKnobs(event:MouseEvent):void

Inserts new knobs in this Diagram link UI for more user customization abilities and easier manipulation. It updates also control points array.

Parameters
event:MouseEvent — Detected Mouse Event.
keyUpHandler()method 
protected override function keyUpHandler(event:KeyboardEvent):void

Activates adequate delete handlers according to a keyboard event (Delete or Backspace) and to the selected point (point context). The delete handlers are listed as follows (from the _delhandlers array:

Parameters
event:KeyboardEvent — Detected Keyboard Event.
knobHandler()method 
protected override function knobHandler(event:MouseEvent):void

Handles any knob (except knob linked to source or target Diagram UIs) manipulation and updates user modifications in the correspondant DiagramLink (knob position update in the diagram drawing).

Parameters
event:MouseEvent — Detected Mouse Event.
segHandler()method 
protected function segHandler(event:MouseEvent):void

Handles any segment (except segments linked to source or target Diagram UIs) manipulation and updates user modifications in the correspondant DiagramLink (master and target anchors updates).

Parameters
event:MouseEvent — Detected Mouse Event.
sourceAnchorHandler()method 
protected override function sourceAnchorHandler(event:MouseEvent):void

Handles source anchor manipulation and updates user modifications in the correspondant DiagramLink (master anchor point update).

Parameters
event:MouseEvent — Detected Mouse Event.
sourceKnobHandler()method 
protected function sourceKnobHandler(event:MouseEvent):void

Handles source knob (linked to a source Diagram UI)manipulation and updates user modifications in the correspondant DiagramLink (master anchor point update).

Parameters
event:MouseEvent — Detected Mouse Event.
sourceSegHandler()method 
protected function sourceSegHandler(event:MouseEvent):void

Handles source link segment started from the source manipulation and updates user modifications in the correspondant DiagramLink(master anchor point update).

Parameters
event:MouseEvent — Detected Mouse Event.
sourceTargetKnobHandler()method 
protected function sourceTargetKnobHandler(event:MouseEvent):void

Handles source target knob manipulation and updates user modifications in the correspondant DiagramLink (master and target anchors updates).

Parameters
event:MouseEvent — Detected Mouse Event.
targetAnchorHandler()method 
protected override function targetAnchorHandler(event:MouseEvent):void

Handles target anchor (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchors updates).

Parameters
event:MouseEvent — Detected Mouse Event.
targetKnobHandler()method 
protected function targetKnobHandler(event:MouseEvent):void

Handles target Knob (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchor update).

Parameters
event:MouseEvent — Detected Mouse Event.
targetSegHandler()method 
protected function targetSegHandler(event:MouseEvent):void

Handles target segment (linked to a target Diagram UI) manipulation and updates user modifications in the correspondant DiagramLink (target anchors updates).

Parameters
event:MouseEvent — Detected Mouse Event.