new VisualMatrix()
This class used to create column / row matrix for GridLayout
Classes
Members
(static, constant) exports.combineMatrices
Creates a single matrix from two matrices
- Source:
Methods
(static) calculateDepth(widthMeasures, heightMeasures) → {number}
Calculates the depth of the tree that can be viewed
Parameters:
Name | Type | Description |
---|---|---|
widthMeasures |
Array | array of widths |
heightMeasures |
Array | array of heights |
Returns:
depth of the tree
- Type
- number
(static) createViewPortMatrix(depth) → {Array.<Object>}
Creates the viewport that can be viewed together
Parameters:
Name | Type | Description |
---|---|---|
depth |
number | maxDepth that can be viewed in the viewport |
Returns:
Set of matrices that can be viewed
- Type
- Array.<Object>
(static) getCellDimensions(options) → {Object}
Dispatch the calculated cell dimensions to all the cells
Parameters:
Name | Type | Description |
---|---|---|
options |
Object | cell dimension information |
Returns:
row and column heights / widths
- Type
- Object
(static) getLogicalSpace() → {Object}
Returns the space taken by visual matrix
Returns:
space taken by the matrix
- Type
- Object
(static) getViewableData() → {Array}
Returns the matrix that can be viewed in the current viewport
Returns:
Set of matrices that can be viewed
- Type
- Array
(static) getViewableSpaces() → {Object}
Gets the viewable measures for the current viewable matrix
Returns:
Set of viewable measures
- Type
- Object
(static) populateMaxMeasures(measures, matrixTree, measure, depthopt)
Populate the max measures in the array
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
measures |
Array | array to be filled with max measures | ||
matrixTree |
Object | matrix tree of visual matrix | ||
measure |
number | width or height | ||
depth |
number |
<optional> |
0 | depth of the tree that to be calculated |
(static) redistribute(viewableMatrix, width, height) → {Object}
Redistributes the provied space to all cells
Parameters:
Name | Type | Description |
---|---|---|
viewableMatrix |
* | current viewport matrix |
width |
* | provied width |
height |
* | provied height |
Returns:
current viewports matrixes with measures
- Type
- Object
(static) redistributeColumnWise(options)
Distibutes the given space column wisely
Parameters:
Name | Type | Description |
---|---|---|
options |
Object | Redistribution information |
(static) redistributeRowWise(options)
Distibutes the given space row wisely
Parameters:
Name | Type | Description |
---|---|---|
options |
Object | Redistribution information |
(static) setAvailableSpace(width, height)
Sets the provied space to the visual matrix
Parameters:
Name | Type | Description |
---|---|---|
width |
number | width provided |
height |
number | height provided |
(static) setLogicalSpace() → {Object}
Computes the logical space taken by the entire matrixTree
Returns:
Logical space taken
- Type
- Object