美文网首页
隐藏导航栏底部横线和颜色

隐藏导航栏底部横线和颜色

作者: Luyc_Han | 来源:发表于2018-04-20 14:36 被阅读15次
 UINavigationBar *navBar = [UINavigationBar appearance];
//    navBar.tintColor = [UIColor clearColor];
    UIView *backgroundView = [self.navigationBar subviews].firstObject;
    UIView *lineView = backgroundView.subviews.firstObject;
    lineView.hidden = YES;
    navBar.barTintColor = [UIColor lm_colorWithHexString:@"ffc400"];
    NSDictionary *dict = @{NSForegroundColorAttributeName : [UIColor hexColor:@"#2B2D2E"]};
    [navBar setTitleTextAttributes:dict];
    navBar.translucent = NO;
    [navBar setShadowImage:[[UIColor hexColor:@"#F4F4F4"] colorNavigationImage]];

相关文章

网友评论

      本文标题:隐藏导航栏底部横线和颜色

      本文链接:https://www.haomeiwen.com/subject/luoakftx.html