I'm trying to draw a indeterminate (circular) progress bar that is white and then fades into purple.
This is my ProgressBar:
<ProgressBar
android:id="@+id/mainProgressBar"
style="@style/Widget.AppCompat.ProgressBar"
android:layout_width="@dimen/progressbar_size"
android:layout_height="@dimen/progressbar_size"
android:layout_gravity="center" />
Then I paint it white:
mainProgressBar.getIndeterminateDrawable().setColorFilter(getResources().getColor(R.color.white), PorterDuff.Mode.SRC_ATOP);
Do I need add another ColorFilter? Set a style or theme on the progressbar? No idea what to do here.