NSMutableDictionary*dic = [NSMutableDictionary dictionary];
dic[NSForegroundColorAttributeName] = [UIColorlight GrayColor];//字体颜色
dic[NSFontAttributeName] = [UIFont systemFontOfSize:12];//字体大小
NSMutableAttributedString *att = [[NSMutableAttributedString alloc] initWithString:@"(未设定)" attributes:dic];//内容
UILabel *myLabel = [[UILabel alloc] initWithFrame:CGRectMake(0,0,80,90)];//自定的UILabel
myLabel.attributedText = att;
网友评论