LineCartesianLayer

open class LineCartesianLayer(var lineProvider: LineCartesianLayer.LineProvider, var pointSpacingDp: Float = Defaults.POINT_SPACING, var rangeProvider: CartesianLayerRangeProvider = CartesianLayerRangeProvider.auto(), var verticalAxisPosition: Axis.Position.Vertical? = null, var drawingModelInterpolator: CartesianLayerDrawingModelInterpolator<LineCartesianLayerDrawingModel.PointInfo, LineCartesianLayerDrawingModel> = CartesianLayerDrawingModelInterpolator.default()) : BaseCartesianLayer<LineCartesianLayerModel>

Draws the content of line charts.

Constructors

Link copied to clipboard
constructor(lineProvider: LineCartesianLayer.LineProvider, pointSpacingDp: Float = Defaults.POINT_SPACING, rangeProvider: CartesianLayerRangeProvider = CartesianLayerRangeProvider.auto(), verticalAxisPosition: Axis.Position.Vertical? = null, drawingModelInterpolator: CartesianLayerDrawingModelInterpolator<LineCartesianLayerDrawingModel.PointInfo, LineCartesianLayerDrawingModel> = CartesianLayerDrawingModelInterpolator.default())

Types

Link copied to clipboard
interface AreaFill

Draws a LineCartesianLayer line’s area fill.

Link copied to clipboard
object Companion

Provides access to Line and Point factory functions.

Link copied to clipboard
open class Line(fill: LineCartesianLayer.LineFill, val thicknessDp: Float = Defaults.LINE_SPEC_THICKNESS_DP, areaFill: LineCartesianLayer.AreaFill? = fill.getDefaultAreaFill(), cap: Paint.Cap = Paint.Cap.ROUND, val pointProvider: LineCartesianLayer.PointProvider? = null, val pointConnector: LineCartesianLayer.PointConnector = PointConnector.cubic(), val dataLabel: TextComponent? = null, val dataLabelVerticalPosition: VerticalPosition = VerticalPosition.Top, val dataLabelValueFormatter: CartesianValueFormatter = CartesianValueFormatter.decimal(), val dataLabelRotationDegrees: Float = 0.0f)

Defines the appearance of a line in a line chart.

Link copied to clipboard
interface LineFill

Draws a LineCartesianLayer line’s fill.

Link copied to clipboard
fun interface LineProvider

Provides Lines to LineCartesianLayers.

Link copied to clipboard
data class Point(component: Component, val sizeDp: Float = Defaults.POINT_SIZE)

Defines a point style.

Link copied to clipboard
fun interface PointConnector

Connects a LineCartesianLayer line’s points, thus defining its shape.

Link copied to clipboard
interface PointProvider

Provides Points to LineCartesianLayers.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

the point spacing (in dp).

Link copied to clipboard

overrides the x and y ranges.

Link copied to clipboard

the position of the VerticalAxis with which the LineCartesianLayer should be associated. Use this for independent CartesianLayer scaling.

Functions

Link copied to clipboard

Prepares the CartesianLayer for a difference animation.

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

Carries out the pending difference animation.

Link copied to clipboard

Updates horizontalDimensions to match this CartesianLayer’s dimensions.

Link copied to clipboard
open override fun updateInsets(context: CartesianMeasuringContext, horizontalDimensions: HorizontalDimensions, model: LineCartesianLayerModel, insets: Insets)

Ensures that there are sufficient insets.

Link copied to clipboard

Updates ranges in accordance with model.