您的位置:首页 > 移动开发 > IOS开发

iOS7修改NavigationItem上的标题名字大小颜色

2015-06-26 14:12 363 查看
self.navigationController.navigationBar.titleTextAttributes = [NSDictionarydictionaryWithObjectsAndKeys:[UIFontsystemFontOfSize:10.0f],NSFontAttributeName,
nil];

self.nav = [[[NavViewController alloc] initWithRootViewController:self.viewController] autorelease];

[self.nav.navigationBar setBackgroundImage:[UIImage imageNamed:@"navbg"] forBarMetrics:UIBarMetricsDefault];

NSDictionary *dict = [NSDictionary dictionaryWithObjectsAndKeys:[UIColor whiteColor],UITextAttributeTextColor,[UIColor blackColor],UITextAttributeTextShadowColor,[UIFont boldSystemFontOfSize:20.0],UITextAttributeFont,CGSizeMake(0,
-1.0),UITextAttributeTextShadowOffset, nil];


self.nav.navigationBar.titleTextAttributes = dict;
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: