Type Definitions
DefArrange
type Holds different options as an object of {dir, dx, dy, align. compact} type to auto-arrange the elements using the Arrange method, for defArrange field of Surface.Options object.
Type:
- object
Properties:
Name | Type | Description |
---|---|---|
dir |
number | Specifies the direction to auto-arrange the elements. Specifies a numeric value as follows:
Currently, any other value has no effect. Example:1, arrange vertically the elements |
dx |
number | Specifies the distance between two auto-arranged elements on horizontal axis. You can use the dx field to increase or decrease the distance of the arranged elements (36, by default) |
dx |
number | Specifies the distance between two auto-arranged elements on vertical axis. You can use the dx field to increase or decrease the distance of the arranged elements (36, by default) |
align |
number | Specifies the alignment of the elements relative to incoming/outgoing elements during the Arrange operation. Indicates a numeric value as follows:
|
compact |
boolean | Compacts the layout during the Arrange method (true, by default) |
DisplayLinkType
Defines the {type, dir, width, color, arrow, arrowSize, style, startPos, endPos} type for collapsedLink, link, linkStartFrom, linkEndTo and linkUnselected fields of Surface.Options object.
Type:
- object
Properties:
Name | Type | Description |
---|---|---|
type |
exontrol.LinkTypeEnum | Specifies the type of the link.
The exontrol.LinkTypeEnum supports the following values:
null {null}, indicates the default type of link, which is similar with rectangular-link but more symmetrical (equivalent of -1) |
dir |
number | The dir field specifies whether the link's direction is shown or hidden.
The dir field can be any of the following values:
null {null}, shows the direction/arrow where the link ends (equivalent of 2) |
width |
number | The width field defines the size/width of the link. Example: null {null}, indicates links of 1-pixel wide |
color |
string | The color field specifies the color to show the link (defines the color of the link as a CSS color format). Example: null {null}, indicates a black link |
arrow |
string | The arrow field indicates the arrow's color (if it is missing or not specified the arrow is shown using the link's color). Example: null {null}, indicates that the link's color defines the color of the link's arrow |
arrowSize |
number | The arrowSize field indicates the arrow's size (if it is missing or not specified the arrow's size is defined by link's width). Example: null {null}, indicates that the link's width defines the size of the link's arrow |
arrowShape |
object | The arrowShape field defines the custom-shape to draw the link's arrow, as an object of exontrol.Def.Shape type. Example: null {null}, indicates that the link's arrow is shown by default as a triangle oriented to point the direction |
style |
null | number | Array.<number> | The style field defines the style of the link. Could be any of the following:
null {null}, defines a solid grid-lines |
startPos |
null | number | string | The startPos field defines the in-element's corners, the link can start from. Could be any of the following:
null {null}, equivalent of ["TC","ML","BC","MR"], specifies that the link starts from the in-element's closest point to out-element |
endPos |
null | number | string | The endPos field defines the out-element's corners, the link can end into. Could be any of the following:
null {null}, equivalent of ["TC","ML","BC","MR"], specifies that the link ends into the out-element's closest point to in-element |