Skip to main content

PaneComponent

PaneComponent API

PaneComponent.doActivate
PaneComponent.doActivate(): void

Method that activates the canvas bounds container and recalculates the zoom Y of the scale model.

Returns
void
PaneComponent.toY
PaneComponent.toY(price: number): number

Parameters
price: number
Returns
number
PaneComponent.createGridComponent
PaneComponent.createGridComponent(uuid: string, scale: ScaleModel, yAxisState: YAxisConfig, yAxisLabelsGetter: () => NumericAxisLabel[], yAxisBaselineGetter: () => number): GridComponent

Creates a new GridComponent instance with the provided parameters.

Parameters
uuid: string
- The unique identifier of the pane.
scale: ScaleModel
- The scale model used to calculate the scale of the grid.
yAxisState: YAxisConfig
- y Axis Config
yAxisLabelsGetter: () => NumericAxisLabel[]
yAxisBaselineGetter: () => number
Returns
GridComponent
PaneComponent.createYPanHandler
PaneComponent.createYPanHandler(uuid: string, scale: ScaleModel): [Unsubscriber, DragNDropYComponent]

Creates a handler for Y-axis panning of the chart.

Parameters
uuid: string
- The unique identifier of the chart pane.
scale: ScaleModel
- The scale model of the chart.
Returns
[Unsubscriber, DragNDropYComponent]
PaneComponent.addCursors
PaneComponent.addCursors(extentIdx: number, yAxisComponent: YAxisComponent): Unsubscriber

Parameters
extentIdx: number
yAxisComponent: YAxisComponent
Returns
Unsubscriber
PaneComponent.createExtentComponent
PaneComponent.createExtentComponent(options: AtLeastOne<YExtentCreationOptions, keyof YExtentCreationOptions>): YExtentComponent

Parameters
options: AtLeastOne<YExtentCreationOptions, keyof YExtentCreationOptions>
Returns
YExtentComponent
PaneComponent.removeExtentComponents
PaneComponent.removeExtentComponents(extentComponents: YExtentComponent[]): void

Parameters
extentComponents: YExtentComponent[]
Returns
void
PaneComponent.moveDataSeriesToNewExtentComponent
PaneComponent.moveDataSeriesToNewExtentComponent(dataSeries: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>[], initialPane: PaneComponent, initialExtent: YExtentComponent, align: YAxisAlign): void

Create new pane extent and attach data series to it

Parameters
dataSeries: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>[]
initialPane: PaneComponent
initialExtent: YExtentComponent
align: YAxisAlign
Returns
void
PaneComponent.moveDataSeriesToExistingExtentComponent
PaneComponent.moveDataSeriesToExistingExtentComponent(dataSeries: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>[], initialPane: PaneComponent, initialExtent: YExtentComponent, extentComponent: YExtentComponent, isForceKeepExtent: boolean): void

Attach data series to existing y axis extent

Parameters
dataSeries: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>[]
initialPane: PaneComponent
initialExtent: YExtentComponent
extentComponent: YExtentComponent
isForceKeepExtent: boolean
Returns
void
PaneComponent.updateView
PaneComponent.updateView(): void

This method updates the view by calling the doAutoScale method of the scaleModel and firing the Draw event using the eventBus.

Returns
void
PaneComponent.mergeYExtents
PaneComponent.mergeYExtents(): void

Merges all the y-axis extents on the pane into one.

Returns
void
PaneComponent.getBounds
PaneComponent.getBounds(): Bounds

Returns the bounds of the pane component.

Returns
Bounds
PaneComponent.createDataSeries
PaneComponent.createDataSeries(): DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>

Creates a new DataSeriesModel object.

Returns
DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>
PaneComponent.addDataSeries
PaneComponent.addDataSeries(series: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>): void

Adds a new data series to the chart.

Parameters
series: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>
- The data series to be added.
Returns
void
PaneComponent.removeDataSeries
PaneComponent.removeDataSeries(series: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>): void

Removes a data series from the chart.

Parameters
series: DataSeriesModel<DataSeriesPoint, VisualSeriesPoint, DataSeriesConfig>
- The data series to be removed.
Returns
void
PaneComponent.getAxisType
PaneComponent.getAxisType(): PriceAxisType

Returns the type of the y-axis component for the current pane.

Returns
PriceAxisType
PaneComponent.moveUp
PaneComponent.moveUp(): void

Moves the canvas bounds container up by calling the movePaneUp method with the uuid of the current object.

Returns
void
PaneComponent.moveDown
PaneComponent.moveDown(): void

Moves the canvas bounds container down by calling the movePaneDown method with the uuid of the current object.

Returns
void
PaneComponent.canMoveUp
PaneComponent.canMoveUp(): boolean

Checks if the current pane can move up.

Returns
boolean
PaneComponent.canMoveDown
PaneComponent.canMoveDown(): boolean

Checks if the current pane can move down.

Returns
boolean
PaneComponent.setPaneValueFormatters
PaneComponent.setPaneValueFormatters(formatters: YExtentFormatters): void

Sets the pane value formatters for the current instance.

Parameters
formatters: YExtentFormatters
- The pane value formatters to be set.
Returns
void
PaneComponent.regularValueFromY
PaneComponent.regularValueFromY(y: number): number

Returns the regular value from Y coordinate.

Parameters
y: number
- The Y coordinate.
Returns
number
;