MaterialSwitch

A class that creates a Material Themed Switch. This class is intended to provide a brand new Switch design and replace the obsolete com.google.android.material.switchmaterial.SwitchMaterial class.

For more information, see the component developer guidance and design guidelines.

Constructors

Link copied to clipboard
constructor(@NonNull context: Context)
constructor(@NonNull context: Context, @Nullable attrs: AttributeSet)
constructor(@NonNull context: Context, @Nullable attrs: AttributeSet, defStyleAttr: Int)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
@get:Px
open var thumbIconSize: Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
open fun invalidate()
Link copied to clipboard
Sets the drawable used for the thumb icon that will be drawn upon the thumb.
Link copied to clipboard
Link copied to clipboard
Set the drawable used for the track decoration that will be drawn upon the track.
Link copied to clipboard