MarkerComponent
open class MarkerComponent(val label: TextComponent, val indicator: Component?, val guideline: LineComponent?) : Marker
The default implementation of the Marker interface.
Parameters
label
the TextComponent used to draw the label.
indicator
an optional indicator drawn at a given point belonging to the data entry.
guideline
an optional line drawn from the bottom of the chart to the bottom edge of the label.
Properties
Link copied to clipboard
Link copied to clipboard
The indicator size (in dp).
Link copied to clipboard
Link copied to clipboard
The MarkerLabelFormatter for this marker.
Link copied to clipboard
An optional lambda function that allows for applying the color associated with a given data entry to a Component.
Functions
Link copied to clipboard
open override fun draw(context: DrawContext, bounds: RectF, markedEntries: List<Marker.EntryModel>, chartValuesProvider: ChartValuesProvider)
Draws the marker.
Link copied to clipboard
open override fun getInsets(context: MeasureContext, 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 Chart is the largest of the insets requested for the edge.