ifish/Ifish/controllers/IfishTabControllers/设备/QianDao/View/QianDaoGongLueViewCell.m

43 lines
2.2 KiB
Objective-C
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//
// QianDaoGongLueViewCell.m
// Ifish
//
// Created by imac on 17/3/6.
// Copyright © 2017年 lianlian. All rights reserved.
//
#import "QianDaoGongLueViewCell.h"
@implementation QianDaoGongLueViewCell
- (void)awakeFromNib {
[super awakeFromNib];
// Initialization code
NSMutableAttributedString * firstString = [[NSMutableAttributedString alloc] initWithString:@"首次签到1金币连续签到每天递增17天后回到1第7天可额外获得一个神秘礼物。"];
NSMutableParagraphStyle * paragraphStyle = [[NSMutableParagraphStyle alloc] init];
[paragraphStyle setLineSpacing:8];
[firstString addAttribute:NSParagraphStyleAttributeName value:paragraphStyle range:NSMakeRange(0, [firstString length])];
[firstString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithRed:225.0/255.0 green:115.0/255.0 blue:92.0/255.0 alpha:1] range:NSMakeRange(17, 2)];
[firstString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithRed:225.0/255.0 green:156.0/255.0 blue:1.0/255.0 alpha:1] range:NSMakeRange(37, 4)];
self.firstLabel.attributedText = firstString;
NSMutableAttributedString * secString = [[NSMutableAttributedString alloc] initWithString:@"*金币兑换比例100金币≈1人民币"];
[secString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithRed:225.0/255.0 green:115.0/255.0 blue:92.0/255.0 alpha:1] range:NSMakeRange(0, 1)];
[secString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithRed:225.0/255.0 green:115.0/255.0 blue:92.0/255.0 alpha:1] range:NSMakeRange(8, 3)];
self.secondLabel.attributedText = secString;
NSMutableAttributedString * thirdString = [[NSMutableAttributedString alloc] initWithString:@"*一切解释权归©爱鱼奇所有"];
[thirdString addAttribute:NSForegroundColorAttributeName value:[UIColor colorWithRed:225.0/255.0 green:115.0/255.0 blue:92.0/255.0 alpha:1] range:NSMakeRange(0, 1)];
self.thirdlabel.attributedText = thirdString;
}
- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
[super setSelected:selected animated:animated];
// Configure the view for the selected state
}
@end