iOS设置字符串指定位置的颜色和字体

来源:互联网 发布:东盛安防监控软件 编辑:程序博客网 时间:2024/05/21 17:05

            NSMutableAttributedString * pointMut = [[NSMutableAttributedStringalloc] initWithString:point];

            [pointMut setAttributes:@{NSForegroundColorAttributeName:oragineColorGlk1,NSFontAttributeName:[UIFontsystemFontOfSize:12]}range:NSMakeRange(7, strPoint0.length)];

            [pointMut setAttributes:@{NSForegroundColorAttributeName:oragineColorGlk1,NSFontAttributeName:[UIFontsystemFontOfSize:12]}range:NSMakeRange(point.length - huiJiFen.length, [huiJiFenlength])];

            temCell.jifenLabel.textColor =BackColorGrayGlk2;

            temCell.jifenLabel.attributedText = pointMut;


在iOS 7.1版本之后,通过itms-service安装应用时,要求itms-service协议后面的url的值即plist文件的地址必须为https地址,且设备必须信任此https服务器的SSL证书。关于这个问题,可参考另一篇博客


itms-services://?action=download-manifest&url=https://www.hybunion.com/download/ios/neicemerchant.plist

0 0