Pascal Widdershoven

Colored UIProgressView

A little while ago, I found myself in the position of needing a UIProgressView in a color different then the default blue. I was suprised to find out that the UIProgressView class does not support setting a tintcolor. So I decided to subclass UIProgressView and draw my own ProgressView with support for setting a tintcolor.

The result became 'PDColoredProgressView'.

PDColoredProgressView

Implementing the PDColoredProgressView is as easy as:

PDColoredProgressView *progressView = [[PDColoredProgressView alloc] initWithProgressViewStyle: UIProgressViewStyleDefault];
[progressView setTintColor: [UIColor redColor]]; //or any other color you like
[self.view addSubview: progressView];

PDColoredProgressView is free for anyone to use, both commerically and non-commerically, and available for download on the right. A demo app and some documentation are included.

However, if you'd decide to use it in one of your projects, a thank-you in the comments here and/or a linkback to my website from your app's about screen or support page would be greatly appreciated.

You can find the code on Github and a direct download as tar or zip.

If you like this subclass and intent to use it in your software, please consider a donation. Thanks.