[英]How can I make the font size of the status bar of my old app to match the system status bar in iOS 10?
I have an app developed for iOS 7, and since then I keep updating it for every iOS update till the current iOS 10 version. 我有一个专为iOS 7开发的应用程序,从那时起,我一直在每次更新iOS iOS 10之前都对其进行更新。
I have found that the font size of status bar in my app is slightly larger than that of the system status bar and other newer apps, which make it look dated (Please see the first picture below). 我发现我的应用程序中状态栏的字体大小比系统状态栏和其他较新的应用程序的字体大小略大,这使它看起来过时了(请参阅下面的第一张图片)。
How can I make the status bar of my app looks the same as other newer apps (second picture below)? 如何使我的应用程序的状态栏看起来与其他较新的应用程序相同(下面的第二张图片)?
UIApplication.shared.statusBarStyle = .lightContent
Inside every view controller use this code for auto color support in status bar 在每个视图控制器内部,使用此代码在状态栏中提供自动颜色支持
override var preferredStatusBarStyle: UIStatusBarStyle { return .lightContent } 覆盖var preferredStatusBarStyle:UIStatusBarStyle {return .lightContent}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.