Reputation: 1210
I am developing a media player application in which I want the ProgressBar to be in the semi circle shape.I tried some xml files like Shape,rotate but it doesn't work. What are the possible ways to change the shape of such progress bar??
Upvotes: 0
Views: 3400
Reputation: 40426
res->drawable->progressbackground1.xml
<?xml version="1.0" encoding="utf-8"?>
<animated-rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/progressbar1"
android:pivotX="50%"
android:pivotY="50%" />
res->layout->main.xml
<ProgressBar
android:id="@+id/progressBar1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_marginTop="5dp"
android:indeterminateDrawable="@drawable/progressbackground1" />
res->drawable->progressbar1.png
Upvotes: 1