CartesianLayer

Visualizes data on a Cartesian plane. CartesianLayers are combined and drawn by CartesianCharts.

Inheritors

Properties

Link copied to clipboard
abstract val bounds: RectF

The bounds of the abstract component.

Link copied to clipboard

Functions

Link copied to clipboard
abstract fun draw(context: CartesianDrawContext, model: T)

Draws the CartesianLayer.

Link copied to clipboard
open fun getHorizontalInsets(context: CartesianMeasureContext, availableHeight: Float, outInsets: HorizontalInsets)

Called during the measurement phase, after getInsets. Only horizontal insets can be requested from this function. Unless the available height is of interest, getInsets can be used to set all insets. The final inset for a given edge of the associated CartesianChart is the largest of the insets requested for the edge.

Link copied to clipboard
open fun getInsets(context: CartesianMeasureContext, outInsets: Insets, horizontalDimensions: HorizontalDimensions)

Called during the measurement phase, before getHorizontalInsets. Both horizontal and vertical insets can be requested from this function. The final inset for a given edge of the associated CartesianChart is the largest of the insets requested for the edge.

Link copied to clipboard
abstract fun prepareForTransformation(model: T?, extraStore: MutableExtraStore, chartValues: ChartValues)

Prepares the CartesianLayer for a difference animation.

Link copied to clipboard
open fun setBounds(bounds: RectF)

Sets the coordinates of the bounds to the provided bounds.

open fun setBounds(left: Number, top: Number, right: Number, bottom: Number)

Sets the coordinates of the bounds to the provided values.

Link copied to clipboard
abstract suspend fun transform(extraStore: MutableExtraStore, fraction: Float)

Carries out the pending difference animation.

Link copied to clipboard
abstract fun updateChartValues(chartValues: MutableChartValues, model: T)

Updates chartValues in accordance with model.

Link copied to clipboard
abstract fun updateHorizontalDimensions(context: CartesianMeasureContext, horizontalDimensions: MutableHorizontalDimensions, model: T)

Updates horizontalDimensions to match this CartesianLayer’s dimensions.