设置navigationbar title颜色

来源:互联网 发布:淘宝服装质检 编辑:程序博客网 时间:2024/04/30 21:38

NSShadow *shadow = [[NSShadowalloc] init];

shadow.shadowColor = [UIColorcolorWithRed:0.0green:0.0blue:0.0alpha:0.8];

shadow.shadowOffset =CGSizeMake(0,1);

[self.navigationController.navigationBarsetTitleTextAttributes:[NSDictionarydictionaryWithObjectsAndKeys:

                                                                    [UIColorcolorWithRed:245.0/255.0green:245.0/255.0blue:245.0/255.0alpha:1.0],NSForegroundColorAttributeName,

                                                                    shadow,NSShadowAttributeName,

                                                                     [UIFontfontWithName:@"HelveticaNeue-CondensedBlack"size:21.0],NSFontAttributeName, nil]];

0 0
原创粉丝点击