BasicLabelFormatter

public final class BasicLabelFormatter implements LabelFormatter


A simple implementation of the LabelFormatter interface, that limits the number displayed inside a discrete slider's bubble to three digits, and a single-character suffix that denotes magnitude (e.g.: 1.5K, 2.2M, 1.3B, 2T).

Summary

Public constructors

Public methods

String
getFormattedValue(float value)

Inherited Constants

From com.google.android.material.slider.LabelFormatter
static final int
static final int
static final int
static final int

Public constructors

BasicLabelFormatter

public BasicLabelFormatter()

Public methods

getFormattedValue

public String getFormattedValue(float value)