是否可以NSAttributedString
仅将 2 放入一个标签中?
例如:
NSString *a = [car valueForKey:@"name"];
NSString *b = [car valueForKey:@"version"];
NSAttributedString *title;
title = [[NSAttributedString alloc] initWithString:a attributes:@{ NSFontAttributeName : [UIFont fontWithName:@"Noteworthy-Bold" size:36], NSUnderlineStyleAttributeName : @1 , NSStrokeColorAttributeName : [UIColor blackColor]}]; //1
NSAttributedString *title2;
title2 = [[NSAttributedString alloc] initWithString:b attributes:@{ NSFontAttributeName : [UIFont fontWithName:@"Noteworthy-Bold" size:36], NSUnderlineStyleAttributeName : @0 , NSStrokeColorAttributeName : [UIColor blackColor]}]; //2
cell.textLabel.attributedText = //what should I write here?