Java android.widget ProgressBar fields, constructors, methods, implement or subclass

Example usage for Java android.widget ProgressBar fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for android.widget ProgressBar.

The text is from its open source code.

Subclass

android.widget.ProgressBar has subclasses.
Click this link to see all its subclasses.

Constructor

Method

ViewPropertyAnimatoranimate()
This method returns a ViewPropertyAnimator object, which can be used to animate specific properties on this View.
voidclearAnimation()
Cancels any animations for this view.
ContextgetContext()
Returns the context the view is running in, through which it can access the current theme, resources, etc.
DrawablegetIndeterminateDrawable()

Get the drawable used to draw the progress bar in indeterminate mode.

intgetMax()

Return the upper limit of this progress bar's range.

intgetMeasuredHeight()
Like #getMeasuredHeightAndState() , but only returns the raw height component (that is the result is masked by #MEASURED_SIZE_MASK ).
intgetProgress()

Get the progress bar's current level of progress.

DrawablegetProgressDrawable()

Get the drawable used to draw the progress bar in progress mode.

ResourcesgetResources()
Returns the resources associated with this view.
ObjectgetTag()
Returns this view's tag.
intgetVisibility()
Returns the visibility status for this view.
intgetWidth()
Return the width of your view.
voidincrementProgressBy(int diff)

Increase the progress bar's progress by the specified amount.

booleanrequestFocus()
Call this to try to give focus to a specific view or to one of its descendants.
voidsetAlpha(@FloatRange(from = 0.0, to = 1.0) float alpha)
Sets the opacity of the view to a value from 0 to 1, where 0 means the view is completely transparent and 1 means the view is completely opaque.
voidsetEnabled(boolean enabled)
Set the enabled state of this view.
voidsetId(@IdRes int id)
Sets the identifier for this view.
voidsetIndeterminate(boolean indeterminate)

Change the indeterminate mode for this progress bar.

voidsetIndeterminateDrawable(Drawable d)
Define the drawable used to draw the progress bar in indeterminate mode.
voidsetIndeterminateTintList(@Nullable ColorStateList tint)
Applies a tint to the indeterminate drawable.
voidsetLayoutParams(ViewGroup.LayoutParams params)
Set the layout parameters associated with this view.
voidsetMax(int max)

Set the upper range of the progress bar max.

voidsetOnClickListener(@Nullable OnClickListener l)
Register a callback to be invoked when this view is clicked.
voidsetPadding(int left, int top, int right, int bottom)
Sets the padding.
voidsetProgress(int progress)
Sets the current progress to the specified value.
voidsetProgressDrawable(Drawable d)
Define the drawable used to draw the progress bar in progress mode.
voidsetProgressTintList(@Nullable ColorStateList tint)
Applies a tint to the progress indicator, if one exists, or to the entire progress drawable otherwise.
voidsetScaleY(float scaleY)
Sets the amount that the view is scaled in Y around the pivot point, as a proportion of the view's unscaled width.
voidsetSecondaryProgress(int secondaryProgress)

Set the current secondary progress to the specified value.

voidsetTag(final Object tag)
Sets the tag associated with this view.
voidsetVisibility(@Visibility int visibility)
Set the visibility state of this view.
voidstartAnimation(Animation animation)
Start the specified animation now.