taiyang2014

iPhone4 8.3 系统下字体下方去除下划线

    NSMutableAttributedString *title = [[NSMutableAttributedString alloc] initWithString:@"先去看看"];
   
    NSRange titleRange = {0,[title length]};
    [title addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleNone] range:titleRange];
    _goButton.titleLabel.textColor = LIGHTGRAYTEXT_COLOR;
    _goButton.titleLabel.font = [UIFont systemFontOfSize:12];
    [_goButton setAttributedTitle:title
                         forState:UIControlStateNormal];

posted on 2015-12-04 17:24  taiyang2014  阅读(373)  评论(0编辑  收藏  举报

导航