导航栏设置成透明

2016-01-26  本文已影响1140人  天亮説晚安
//设置导航模拟全透明导航[self.navigationController.navigationBar setBackgroundImage:[UIImage imageNamed:@"transparent.png"] forBarMetrics:UIBarMetricsDefault];
self.navigationController.navigationBar.barStyle = UIBarStyleBlackTranslucent;
self.navigationController.navigationBar.translucent = YES;
//去掉导航下面的一条白线
self.navigationController.navigationBar.clipsToBounds = YES;
self.automaticallyAdjustsScrollViewInsets = NO;
//修改navgationBar的字体的颜色
[self.navigationController.navigationBar setTitleTextAttributes:[NSDictionary dictionaryWithObjectsAndKeys:[UIColor whiteColor], NSForegroundColorAttributeName,nil]];
上一篇 下一篇

猜你喜欢

热点阅读