NSMutableAttributedString *attriStr = [[NSMutableAttributedString alloc] initWithString:str];
[attriStr addAttribute:NSForegroundColorAttributeName value:[UIColor redColor] range:NSMakeRange(str.length-1,1)];
[attriStr addAttribute:NSFontAttributeName value:[UIFont systemFontOfSize:14] range:NSMakeRange(str.length-1,1)];
cell.price.attributedText = attriStr;
转载于:https://www.cnblogs.com/zzzili/p/6662478.html