自定义导航条的颜色
来源:互联网 发布:汇付数据 编辑:程序博客网 时间:2024/05/21 10:36
自定义导航条的样式
- (void)setupNavigationBarStyle { UINavigationBar *appearance = [UINavigationBar appearance]; if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7.0) { // 设置导航条背景颜色,在iOS7才这么用 [appearance setBarTintColor:[UIColor colorWithRed:0.291 green:0.607 blue:1.000 alpha:1.000]]; // 设置导航条的返回按钮或者系统按钮的文字颜色,在iOS7才这么用 [appearance setTintColor:[UIColor whiteColor]]; // 设置导航条的title文字颜色,在iOS7才这么用 [appearance setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys: [UIColor whiteColor], NSForegroundColorAttributeName, [UIFont systemFontOfSize:17], NSFontAttributeName, nil]]; } else { // 设置导航条的背景颜色,在iOS7以下才这么用 [appearance setTintColor:[UIColor colorWithRed:0.291 green:0.607 blue:1.000 alpha:1.000]]; }}
0 0
- 自定义导航条的颜色
- 【代码笔记】iOS-自定义导航条颜色
- 导航条的颜色设置
- iOS 导航条透明(以及自定义颜色)的方法,去掉导航条底部黑线,随着tableView滚动设置导航条变色
- 【Bootstrap】修改导航条颜色的方法
- ios修改导航条title的颜色
- 设置导航条标题的颜色
- 更改 UIImagePickerController 导航条文字的颜色
- iOS导航条颜色色差的问题
- 设置导航条和状态栏的颜色
- 【Bootstrap】修改导航条颜色的方法
- 【Bootstrap】修改导航条颜色的方法
- 设置自定义导航条/TabBar及字体颜色
- swift3自定义导航条(二)颜色处理
- ios5 自定义导航条的问题
- 自定义导航条的viewpager+fragment
- ios5自定义导航条
- 自定义导航条1
- Android 常用文件路径
- [leetcode] Longest Common Prefix
- Hibernate的一级和二级缓存
- 在Centos下用alternative命令切换各个版本的jdk的方法
- CentOS 6.6 安装Erlang
- 自定义导航条的颜色
- java 发送短信sms实现接口
- 【GLSL教程】(一)图形流水线
- java FTPClient 文件上传内容为空
- Java_集合操作_反转集合
- android 双卡双待 发送短信
- USACO2.4.3 Cow Tours (cowtour)
- 【GLSL教程】(二)在OpenGL中使用GLSL
- DB2 - Instance