zoukankan      html  css  js  c++  java
  • 转 UINavigationController标题文字颜色

    iOS 5 以后 UINavigationController 可以 改变UINavigationBar导航条标题颜色和字体

    [self.navigationController.navigationBar setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:
                                                                         [UIColor colorWithRed:0 green:0.7 blue:0.8 alpha:1], UITextAttributeTextColor,
                                                                         [UIColor colorWithRed:0 green:0.7 blue:0.8 alpha:1], UITextAttributeTextShadowColor,
                                                                         [NSValue valueWithUIOffset:UIOffsetMake(0, 0)], UITextAttributeTextShadowOffset,
                                                                         [UIFont fontWithName:@"Arial-Bold" size:0.0], UITextAttributeFont,
                                                                         nil]];

    其中 UITextAttributeTextColor和UITextAttributeFont 属性是文字颜色和字体

  • 相关阅读:
    数据产品—数据仓库
    数据产品-开篇
    os.walk()
    pytest入门
    XML 文件处理
    字符编码
    消息队列
    Pycharm
    AWS入门
    Python配置模块:configparser参数含义
  • 原文地址:https://www.cnblogs.com/anyezhuixing/p/4129020.html
Copyright © 2011-2022 走看看