UILabel 字体下方加下划线
UILabel *knowKankan = [[UILabel alloc] initWithFrame:CGRectMake(0, MAINHEIGHT - 78 , MAINWIDTH, 22)];
knowKankan.textAlignment = NSTextAlignmentCenter;
knowKankan.textColor = [UIColor whiteColor];
knowKankan.font = [UIFont systemFontOfSize:16];
NSMutableAttributedString *content = [[NSMutableAttributedString alloc]initWithString:[NSString stringWithFormat:@"了解看看"]];
NSRange contentRange = {0,[content length]};
[content addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:contentRange];
knowKankan.attributedText = content;
knowKankan.textAlignment = NSTextAlignmentCenter;
knowKankan.textColor = [UIColor whiteColor];
knowKankan.font = [UIFont systemFontOfSize:16];
NSMutableAttributedString *content = [[NSMutableAttributedString alloc]initWithString:[NSString stringWithFormat:@"了解看看"]];
NSRange contentRange = {0,[content length]};
[content addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:contentRange];
knowKankan.attributedText = content;
[imageTwo addSubview:knowKankan]
posted on 2015-12-04 17:25 taiyang2014 阅读(359) 评论(0) 编辑 收藏 举报