阅读背景:

label上显示多样式文字

来源:互联网 
UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, SCREEN_WIDTH, SCREEN_HIGHT)];
            label.numberOfLines = 0;
            NSString *htmlString = [Collect replaceNull:[response objectForKey:@"message"]];
            NSAttributedString *attributedString = [[NSAttributedString alloc] initWithData:[htmlString dataUsingEncoding:NSUnicodeStringEncoding] options:@{ NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType } documentAttributes:nil error:nil];
            label.attributedText = attributedString;
            [label sizeToFit];
            [self.view addSubview:label];UILabel *label = [[UILabel alloc] initWithFrame



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: