Class: SelectionBox

SelectionBox()

new SelectionBox()

This class is used to create a selection box which is used by visual unit for brushing and selection in the canvas.
Source:

Methods

(static) defaultConfig() → {Object}

It returns the default configuration needed by selectionbox.
Source:
Returns:
Default configuration of the selection box.
Type
Object

(static) defaultConfig() → {Object}

It returns the default configuration needed by selectionbox.
Source:
Returns:
Default configuration of the selection box.
Type
Object

apply(dimension, conf, unitWidth, unitHeight)

Draws the selectionbox with the specified dimensions.
Parameters:
Name Type Description
dimension Object Dimensions of the selection box.
Properties
Name Type Description
x1 number Starting x position
x2 number Ending x position
y1 number Starting y position
y2 number Ending y position
conf Object Configuration needed to draw the selection box
unitWidth number Width of the visual unit.
unitHeight number Height of the visual unit.
Source:

SelectionBox()

new SelectionBox()

This class is used to create a selection box which is used by visual unit for brushing and selection in the canvas.
Source:

Methods

(static) defaultConfig() → {Object}

It returns the default configuration needed by selectionbox.
Source:
Returns:
Default configuration of the selection box.
Type
Object

(static) defaultConfig() → {Object}

It returns the default configuration needed by selectionbox.
Source:
Returns:
Default configuration of the selection box.
Type
Object

apply(dimension, conf, unitWidth, unitHeight)

Draws the selectionbox with the specified dimensions.
Parameters:
Name Type Description
dimension Object Dimensions of the selection box.
Properties
Name Type Description
x1 number Starting x position
x2 number Ending x position
y1 number Starting y position
y2 number Ending y position
conf Object Configuration needed to draw the selection box
unitWidth number Width of the visual unit.
unitHeight number Height of the visual unit.
Source: