1、修改app默认的status bar style为light content
a、到info.plist文件中添加View controller-based status bar appearanceboolean 并将其设置为NO
b、点击target-》General-》Deployment Info-》status bar style设置为light
2、单独页面修改status bar style
在特定的viewcontroller中实现 -(UIStatusBarStyle)preferredStatusBarStyle ;
eg:
-(UIStatusBarStyle)preferredStatusBarStyle {
return UIStatusBarStyleDefault;
}
3、代码修改全局的status bar style :[[UIApplication sharedApplication]setStatusBarStyle:UIStatusBarStyleLightContent];
ps:-(UIStatusBarStyle)preferredStatusBarStyle方法优先于setStatusBarStyle方法