导航栏相关设置

2017-05-17  本文已影响11人  JACK_岩

//设置导航栏信号区颜色

配置信息如下图:View controller-based status bar appearance

self.navigationController.navigationBar.barStyle = UIBarStyleBlack;

//设置导航栏背景色(分类方法)

[self.navigationController.navigationBar st_setBackgroundColor:[AppColor colorWithAlphaComponent:1]];

//设置导航栏字体颜色

[self.navigationController.navigationBar  setTitleTextAttributes:@{NSForegroundColorAttributeName:[UIColor whiteColor]}];

//自动布局 距离导航栏的高度

make.top.mas_equalTo(self.mas_topLayoutGuide).mas_offset(20);

上一篇 下一篇

猜你喜欢

热点阅读