NSMutableAttributedString

NSMutableAttributedString

#import <UIKit/UIKit.h>

    //价格
NSString *priceStr = @"99元 剁手价66元";
NSMutableAttributedString *priceString = [[NSMutableAttributedString alloc] initWithString:priceStr];
[priceString addAttribute:NSFontAttributeName value:[UIFont systemFontOfSize:12.0f] range:NSMakeRange(, )];
[priceString addAttribute:NSStrikethroughStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:NSMakeRange(, )];
[priceString addAttribute:NSFontAttributeName value:[UIFont systemFontOfSize:14.0f] range:NSMakeRange(, )];
[priceString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithNumber:] range:NSMakeRange(, )];
priceLabel.attributedText = priceString;
05-11 09:02