UITextView的一些设置
作者:
小黄人写代码 | 来源:发表于
2015-06-09 11:41 被阅读258次允许数据监测
[textView setDataDetectorTypes:UIDataDetectorTypeAll];
设置行高
UITextView *textView = [[UITextView alloc] init];
NSMutableParagraphStyle *paragraphStyle = [[NSMutableParagraphStyle alloc] init];
paragraphStyle.lineSpacing = 27;
NSDictionary *attributesDict = @{
NSParagraphStyleAttributeName : paragraphStyle,
NSFontAttributeName : [UIFont fontWithName:@"STHeitiSC-Light" size:17],
NSForegroundColorAttributeName : [UIColor whiteColor]
};
textView.attributedText = [[NSAttributedString alloc] initWithString:@"xxx" attributes:attributesDict];
本文标题:UITextView的一些设置
本文链接:https://www.haomeiwen.com/subject/kqhjqttx.html
网友评论