Line

open class Line(fill: LineCartesianLayer.LineFill, val stroke: LineCartesianLayer.LineStroke = LineStroke.Continuous(), areaFill: LineCartesianLayer.AreaFill? = fill.getDefaultAreaFill(), 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.

Constructors

Link copied to clipboard
constructor(fill: LineCartesianLayer.LineFill, stroke: LineCartesianLayer.LineStroke = LineStroke.Continuous(), areaFill: LineCartesianLayer.AreaFill? = fill.getDefaultAreaFill(), pointProvider: LineCartesianLayer.PointProvider? = null, pointConnector: LineCartesianLayer.PointConnector = PointConnector.cubic(), dataLabel: TextComponent? = null, dataLabelVerticalPosition: VerticalPosition = VerticalPosition.Top, dataLabelValueFormatter: CartesianValueFormatter = CartesianValueFormatter.decimal(), dataLabelRotationDegrees: Float = 0.0f)

Properties

Link copied to clipboard

used for the data labels.

Link copied to clipboard

the data-label rotation (in degrees).

Link copied to clipboard

formats the data-label values.

Link copied to clipboard

the vertical position of the data labels relative to the points.

Link copied to clipboard

connects the line’s points, thus defining its shape.

Link copied to clipboard
Link copied to clipboard

defines the style of the stroke.

Functions

Link copied to clipboard
fun draw(context: CartesianDrawingContext, path: Path, lineCanvas: Canvas, fillCanvas: Canvas, verticalAxisPosition: Axis.Position.Vertical?)

Draws the line.