public class CircularProgressDrawable
extends android.graphics.drawable.LayerDrawable
Drawable for determinate circular ProgressBar.| 构造器和说明 |
|---|
CircularProgressDrawable(int style,
android.content.Context context)
Create a new
CircularProgressDrawable. |
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
getShowBackground()
Get whether this drawable is showing a background.
|
boolean |
getUseIntrinsicPadding()
Get whether this drawable is using an intrinsic padding.
|
void |
setShowBackground(boolean show)
Set whether this drawable should show a background.
|
void |
setTint(int tintColor)
Specifies tint color for this drawable.
|
void |
setTintList(android.content.res.ColorStateList tint)
Specifies tint color for this drawable as a color state list.
|
void |
setTintMode(android.graphics.PorterDuff.Mode tintMode)
Specifies a tint blending mode for this drawable.
|
void |
setUseIntrinsicPadding(boolean useIntrinsicPadding)
Set whether this drawable should use an intrinsic padding.
|
addLayer, applyTheme, canApplyTheme, draw, findDrawableByLayerId, findIndexByLayerId, getAlpha, getBottomPadding, getChangingConfigurations, getConstantState, getDrawable, getEndPadding, getHotspotBounds, getId, getIntrinsicHeight, getIntrinsicWidth, getLayerGravity, getLayerHeight, getLayerInsetBottom, getLayerInsetEnd, getLayerInsetLeft, getLayerInsetRight, getLayerInsetStart, getLayerInsetTop, getLayerWidth, getLeftPadding, getNumberOfLayers, getOpacity, getOutline, getPadding, getPaddingMode, getRightPadding, getStartPadding, getTopPadding, inflate, invalidateDrawable, isAutoMirrored, isStateful, jumpToCurrentState, mutate, onBoundsChange, onLayoutDirectionChanged, onLevelChange, onStateChange, scheduleDrawable, setAlpha, setAutoMirrored, setColorFilter, setDither, setDrawable, setDrawableByLayerId, setHotspot, setHotspotBounds, setId, setLayerGravity, setLayerHeight, setLayerInset, setLayerInsetBottom, setLayerInsetEnd, setLayerInsetLeft, setLayerInsetRelative, setLayerInsetRight, setLayerInsetStart, setLayerInsetTop, setLayerSize, setLayerWidth, setOpacity, setPadding, setPaddingMode, setPaddingRelative, setVisible, unscheduleDrawableclearColorFilter, copyBounds, copyBounds, createFromPath, createFromResourceStream, createFromResourceStream, createFromStream, createFromXml, createFromXml, createFromXmlInner, createFromXmlInner, getBounds, getCallback, getColorFilter, getCurrent, getDirtyBounds, getLayoutDirection, getLevel, getMinimumHeight, getMinimumWidth, getState, getTransparentRegion, inflate, invalidateSelf, isFilterBitmap, isVisible, resolveOpacity, scheduleSelf, setBounds, setBounds, setCallback, setChangingConfigurations, setColorFilter, setFilterBitmap, setLayoutDirection, setLevel, setState, unscheduleSelfpublic CircularProgressDrawable(int style,
@NonNull
android.content.Context context)
CircularProgressDrawable.context - the Context for retrieving style information.public boolean getShowBackground()
true.getShowBackground 在接口中 ShowBackgroundDrawablepublic void setShowBackground(boolean show)
true.setShowBackground 在接口中 ShowBackgroundDrawableshow - Whether background should be shown.public boolean getUseIntrinsicPadding()
true.getUseIntrinsicPadding 在接口中 IntrinsicPaddingDrawablepublic void setUseIntrinsicPadding(boolean useIntrinsicPadding)
true.setUseIntrinsicPadding 在接口中 IntrinsicPaddingDrawableuseIntrinsicPadding - Whether this drawable should use its intrinsic padding.public void setTint(int tintColor)
A Drawable's drawing content will be blended together with its tint
before it is drawn to the screen. This functions similarly to
Drawable.setColorFilter(int, PorterDuff.Mode).
To clear the tint, pass null to
TintableDrawable.setTintList(ColorStateList).
Note: Setting a color filter via
Drawable.setColorFilter(ColorFilter) or
Drawable.setColorFilter(int, PorterDuff.Mode) overrides tint.
setTint 在接口中 androidx.core.graphics.drawable.TintAwareDrawablesetTint 在接口中 TintableDrawablesetTint 在类中 android.graphics.drawable.DrawabletintColor - Color to use for tinting this drawableTintableDrawable.setTintList(ColorStateList),
TintableDrawable.setTintMode(PorterDuff.Mode)public void setTintList(@Nullable
android.content.res.ColorStateList tint)
A Drawable's drawing content will be blended together with its tint
before it is drawn to the screen. This functions similarly to
Drawable.setColorFilter(int, PorterDuff.Mode).
Note: Setting a color filter via
Drawable.setColorFilter(ColorFilter) or
Drawable.setColorFilter(int, PorterDuff.Mode) overrides tint.
setTintList 在接口中 androidx.core.graphics.drawable.TintAwareDrawablesetTintList 在接口中 TintableDrawablesetTintList 在类中 android.graphics.drawable.LayerDrawabletint - Color state list to use for tinting this drawable, or
null to clear the tintTintableDrawable.setTint(int),
TintableDrawable.setTintMode(PorterDuff.Mode)public void setTintMode(@NonNull
android.graphics.PorterDuff.Mode tintMode)
Defines how this drawable's tint color should be blended into the drawable
before it is drawn to screen. Default tint mode is PorterDuff.Mode#SRC_IN.
Note: Setting a color filter via
Drawable.setColorFilter(ColorFilter) or
Drawable.setColorFilter(int, PorterDuff.Mode) overrides tint.
setTintMode 在接口中 androidx.core.graphics.drawable.TintAwareDrawablesetTintMode 在接口中 TintableDrawablesetTintMode 在类中 android.graphics.drawable.LayerDrawabletintMode - A Porter-Duff blending modeTintableDrawable.setTint(int),
TintableDrawable.setTintList(ColorStateList)