Indeterminate circle progress bar on android is white, despite colorAccent color

Note: This only works from Android 5.0 (Lollipop) and up, as per the original request. For older Android versions you’ll have to replace the ProgressBar’s progressDrawable.

Expanding upon Liam’s answer, I managed to get this working on XML using the indeterminateTint flag.

Apparently to get it to work, you need to set the indeterminate and indeterminateTintMode flags.

The mode is a bit of mystery for me. I tried all of them but only got the expected results with src_in and src_atop. I don’t know what those modes actually do, so if anyone can expand on this I’d be grateful.

In any case this should work:

<ProgressBar
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:indeterminate="true"
    android:indeterminateTint="#F00"
    android:indeterminateTintMode="src_in" />

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)