public class RingRefresh
extends java.lang.Object
| 构造器和说明 |
|---|
RingRefresh() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
draw(android.graphics.Canvas c,
android.graphics.RectF bounds)
Draw the progress spinner
|
int |
getAlpha() |
double |
getCenterRadius() |
float |
getEndTrim() |
float |
getInsets() |
float |
getRotation() |
float |
getStartingEndTrim() |
float |
getStartingRotation() |
float |
getStartingStartTrim() |
float |
getStartTrim() |
float |
getStrokeWidth() |
void |
resetOriginals()
Reset the progress spinner to default rotation, start and end angles.
|
void |
setAlpha(int alpha) |
void |
setArrowDimensions(float width,
float height)
Set the dimensions of the arrowhead.
|
void |
setArrowScale(float scale) |
void |
setCenterRadius(double centerRadius) |
void |
setColor(int color) |
void |
setColorFilter(android.graphics.ColorFilter filter) |
void |
setEndTrim(float endTrim) |
void |
setInsets(int width,
int height) |
void |
setRotation(float rotation) |
void |
setShowArrow(boolean show) |
void |
setStartTrim(float startTrim) |
void |
setStrokeWidth(float strokeWidth) |
void |
storeOriginals()
If the start / end trim are offset to begin with, store them so that
animation starts from that offset.
|
public void setArrowDimensions(float width,
float height)
width - Width of the hypotenuse of the arrow headheight - Height of the arrow pointpublic void draw(android.graphics.Canvas c,
android.graphics.RectF bounds)
public void setColorFilter(android.graphics.ColorFilter filter)
public void setAlpha(int alpha)
alpha - Set the alpha of the progress spinner and associated arrowhead.public int getAlpha()
public void setStrokeWidth(float strokeWidth)
strokeWidth - Set the stroke width of the progress spinner in pixels.public float getStrokeWidth()
public void setStartTrim(float startTrim)
public float getStartTrim()
public float getStartingStartTrim()
public float getStartingEndTrim()
public void setEndTrim(float endTrim)
public float getEndTrim()
public void setRotation(float rotation)
public float getRotation()
public void setInsets(int width,
int height)
public float getInsets()
public void setCenterRadius(double centerRadius)
centerRadius - Inner radius in px of the circle the progress
spinner arc traces.public double getCenterRadius()
public void setShowArrow(boolean show)
show - Set to true to show the arrow head on the progress spinner.public void setArrowScale(float scale)
scale - Set the scale of the arrowhead for the spinner.public float getStartingRotation()
public void storeOriginals()
public void resetOriginals()
public void setColor(int color)