Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to set launch screen status bar color to white?

My application's launch screen has a dark background color, so I'd like to set the status bar color to white while it's showing.

This differs from the question asked in How to change status bar style - iOS 12. That solution works for me for view controllers once the application is running but I can't find a way to apply it to the launch screen.

like image 499
escouten Avatar asked Dec 27 '18 05:12

escouten


People also ask

How can I change status bar background color?

Step 1: After opening the android studio and creating a new project with an empty activity. Step 2: Navigate to res/values/colors. xml, and add a color that you want to change for the status bar. Step 3: In your MainActivity, add this code in your onCreate method.

Can we change status bar color in iOS?

You can change the status bar colour just with a single line of code. Just updated the markdown for iOS 13 and below.

How do I change the color of my status bar in Swift?

Open your info. plist and set UIViewControllerBasedStatusBarAppearance to false . In the first function in AppDelegate. swift , which contains didFinishLaunchingWithOptions , set the color you want.


1 Answers

For that you have to change Status Bar Style to Light from "General" tab under project target.

An image showing how to do the instructions.

How to set in the entire app

Above only change the status bar color of launch screen to white & rest of controller have black color. If you wanted to change the entire project status bar color to white then add below too :

On you project plist file:

  1. Status bar style: UIStatusBarStyleLightContent
  2. View controller-based status bar appearance: NO
  3. Status bar is initially hidden: NO
like image 65
Khushbu Avatar answered Sep 27 '22 21:09

Khushbu