//改变相应字符串的颜色
(void)ChangeTextColorByLabel:(UILabel *)label
font:(CGFloat)font
model:(NSString *)text{
//label 需要操作的Label
//font 该字符的字号
NSMutableAttributedString *noteString = [[NSMutableAttributedString alloc] initWithString:label.text];
NSRange stringRange = NSMakeRange(3, text.length);
//该字符串的位置
[noteString addAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:font], NSForegroundColorAttributeName:[UIColor blackColor]} range:stringRange];
[label setAttributedText: noteString];
}
//button-
(void)rcs_changButtonTitleColorAndFontWithText:(NSString *)titleText
button:(UIButton *)button{NSMutableAttributedString *str = [[NSMutableAttributedString alloc] initWithString:[NSString stringWithFormat:@"%@",titleText]];
[str addAttribute:NSFontAttributeName value:[UIFont fontWithName:@"Arial-BoldItalicMT" size:18.0] range:NSMakeRange(0,1)];
[str addAttribute:NSForegroundColorAttributeName value:[UIColor greenColor] range:NSMakeRange(0,1)];
//
[button setAttributedTitle:str forState:UIControlStateNormal];
}