blackout blackout - 25 days ago 7
Android Question

How to create an arc shaped custom progress bar in Android?

I'm trying to create a progress bar like the following image.

My requirements are:
1. I want to be able to set a progress value to it programmatically.
2. I want to be able to change the colors of the arc - both the background one (grey) and the foreground one (green).

I looked into libraries but found none that do it in this particular shape and style. I am not proficient enough in creating custom drawables to be able to create this by myself. Any help is appreciated!

enter image description here

Answer Source

In addition to the above answer, you can also use CircleProgress which seems to have something that looks exactly like your use case:

enter image description here



Also, if you check the license on this library (bottom of their README), it seems like it's very favorable to using it however you wish.