BaseProgressIndicatorSpec

public abstract class BaseProgressIndicatorSpec
extends Object

java.lang.Object
   ↳ com.google.android.material.progressindicator.BaseProgressIndicatorSpec


This class contains the parameters shared between linear type and circular type. The parameters reflect the attributes defined in R.styleable.BaseProgressIndicator.

Summary

Fields

public int hideAnimationBehavior

The animation behavior to hide the indicator and track.

public int[] indicatorColors

The color array used in the indicator.

public int indicatorTrackGapSize

The size of the gap between the indicator and the rest of the track.

public int showAnimationBehavior

The animation behavior to show the indicator and track.

public int trackColor

The color used in the track.

public int trackCornerRadius

When this is greater than 0, the corners of both the track and the indicator will be rounded with this radius.

public int trackThickness

The thickness of the track and indicator.

Protected constructors

BaseProgressIndicatorSpec(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes)

Instantiates BaseProgressIndicatorSpec.

Public methods

boolean isHideAnimationEnabled()
boolean isShowAnimationEnabled()

Inherited methods

Fields

hideAnimationBehavior

public int hideAnimationBehavior

The animation behavior to hide the indicator and track.

indicatorColors

public int[] indicatorColors

The color array used in the indicator. In determinate mode, only the first item will be used.

indicatorTrackGapSize

public int indicatorTrackGapSize

The size of the gap between the indicator and the rest of the track.

showAnimationBehavior

public int showAnimationBehavior

The animation behavior to show the indicator and track.

trackColor

public int trackColor

The color used in the track. If not defined, it will be set to the indicatorColors and apply the first disable alpha value from the theme.

trackCornerRadius

public int trackCornerRadius

When this is greater than 0, the corners of both the track and the indicator will be rounded with this radius. If the radius is greater than half of the track width, an IllegalArgumentException will be thrown during initialization.

trackThickness

public int trackThickness

The thickness of the track and indicator.

Protected constructors

BaseProgressIndicatorSpec

protected BaseProgressIndicatorSpec (Context context, 
                AttributeSet attrs, 
                int defStyleAttr, 
                int defStyleRes)

Instantiates BaseProgressIndicatorSpec.

If attributes are missing, the values defined in the default style R.style.Widget_MaterialComponents_ProgressIndicator will be loaded.

Parameters
context Context: Current themed context.

attrs AttributeSet: Component's attributes set.

defStyleAttr int

defStyleRes int

Public methods

isHideAnimationEnabled

public boolean isHideAnimationEnabled ()

Returns
boolean

isShowAnimationEnabled

public boolean isShowAnimationEnabled ()

Returns
boolean