I have a circular progressbar that is a countdown. The countdown starts at the top of the circular progressbar that's is fine, but go to the left doing the countdown. That I want is the rotation of the countdown go to the right, like the clockwise.
My circle_progress_foreground.xml:
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item android:id="@android:id/progress">
<shape
android:innerRadiusRatio="3"
android:shape="ring"
android:thicknessRatio="30"
android:useLevel="true">
<gradient
android:startColor="@color/circle_progress_two"
android:endColor="@color/circle_progress"
android:type="sweep" />
</shape>
</item>
</layer-list>
The progressbar in my layout
<ProgressBar
android:id="@+id/progressbar"
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="280dip"
android:layout_height="290dip"
android:indeterminate="false"
android:progressDrawable="@drawable/circle_progress_foreground"
android:background="@drawable/circle_shape"
android:max="100"
android:rotation="-90"
android:layout_alignParentTop="true"
android:layout_alignLeft="@+id/progressBar"
android:layout_alignStart="@+id/progressBar"
android:layout_centerHorizontal="false"
android:layout_centerInParent="false"
android:layout_centerVertical="false" />
The code in my class:
mProgressBar = (ProgressBar) findViewById(R.id.progressbar);