TriangleMatrixMixin
Auto-generated from the @jbrowse/mobx-state-tree model in the source. See the developer guide for concepts. Built into JBrowse core. View source.
A matrix drawn as a triangle over the view's axis (Hi-C, LD): the fetched payload (rpcData), the canvas box (canvasWidth, matrixHeight under the matrixTop hook), the rotate-and-squash transform and its inverse (cellToScreen, screenToCell), the frame the marks read (triangleFrame), the one-cell region map and canvas-wide block the mark backend draws (matrixRegions, matrixBlocks), and the heightMode slot. Composes after TrackHeightMixin, GlobalFetchMixin and LegendMixin
Volatiles
| Member | Description |
|---|---|
rpcDataD | null |
Getters
| Member | Description |
|---|---|
heightMode"fit" | "fixed" |
|
matrixTopnumber |
Overridable hook (default 0): px reserved above the matrix. |
depthFractionnumber |
Overridable hook (default 1): the share of the full triangle's depth the payload reaches, which a banded matrix sets below 1 so fit mode stretches its strip over the display. |
canvasWidthnumber |
The canvas spans the scrolled content, boundary padding included. |
viewTransform{ viewScale: number; viewOffsetX: number; } |
|
matrixRegionsReadonlyMap<number, D> |
The one payload under key 0, absent until the fetch lands. An empty matrix keeps the key: the cleared canvas is its picture. |
matrixHeightnumber |
|
matrixBlocksRenderBlock[] |
|
yScalarnumber |
The squash takes the content's base, without the boundary padding a scroll past either end adds. |
| triangleTransform |
|
triangleFrameTriangleFrame |
Methods
| Member | Description |
|---|---|
cellToScreen(x: number, y: number) => { x: number; y: number; } |
Pre-rotation cell coordinates to display px. |
screenToCell(x: number, y: number) => { x: number; y: number; } |
The exact inverse of cellToScreen. |
Actions
| Member | Description |
|---|---|
setRpcData(data: D) => void |
|
setHeightMode(mode: "fit" | "fixed") => void |