//16进制色值转换
#define UIColorFromHex(hex) [UIColor colorWithRed:((float)((hex & 0xFF0000) >> 16))/255.0 green:((float)((hex & 0xFF00) >> 8))/255.0 blue:((float)(hex & 0xFF))/255.0 alpha:1.0]
//代码的如下
qiResultsLab.textColor = UIColorFromHex(0xFF7777);
时间: 2024-10-07 07:05:23