2016-02-24 富文本

cellhelp.backgroundColor=RGB(232, 231,231);

            UILabel *show=[[UILabel alloc]initWithFrame:CGRectMake(15, 10, SCREEN_WIDTH-30, 20)];

            show.font=SYSTEMFONT(14);

 

            

            NSMutableAttributedString *strnn = [[NSMutableAttributedString alloc] initWithString:@"要开启或关闭,您可以通过iPhone的设置-通知-肝胆相照 允许通知 手动设置"];

            

//           [strnn addAttribute:NSForegroundColorAttributeName value:[UIColor blueColor] range:NSMakeRange(30,4)]; //设置字体颜色

            //[UIFont boldSystemFontOfSize:20];  [UIFont fontWithName:@"Arial" size:20.0]

           [strnn addAttribute:NSFontAttributeName value:[UIFont boldSystemFontOfSize:14] range:NSMakeRange(30, 4)]; //设置字体字号和字体类别

 

            

            

            //要开启或关闭,您可以通过iPhone的设-通知-肝胆相照 允许通知(加粗)  手动设置

            show.attributedText=strnn;

            show.numberOfLines=0;

            show.lineBreakMode=NSLineBreakByWordWrapping;

            [show sizeToFit];

            [cellhelp.contentView addSubview:show];

 

posted @ 2016-02-24 13:53  zhen_zhen  阅读(101)  评论(0编辑  收藏  举报