Set the status bar to black colour

Viewed 11957

I want to set the colour of the status bar (The small strip on top where the clock and battery is displayed) to black background with white text. How can I do this ?

enter image description here

My approach so far :

I added the following in the info.plist

View controller-based status bar appearance --> NO

and in the viewController

- (UIStatusBarStyle)preferredStatusBarStyle
{
    return UIStatusBarStyleDefault;
}

However, the style does not change. How can I make the status bar black?

5 Answers
Related