摘要: #import <Foundation/Foundation.h>@interface UnderlineUILabel : UILabel{}@end#import "UnderlineUILabel.h"#import<QuartzCore/QuartzCore.h>@implementation UnderlineUILabel-(id)initWithFrame:(CGRect)frame{if(self = [super initWithFrame:frame]){}return self;}-(void)drawRect:(CGRect) 阅读全文
posted @ 2012-12-28 16:43 GreyWolf 阅读(162) 评论(0) 推荐(0) 编辑
摘要: - (void)drawRect:(CGRect)rect{CGContextRef ctx = UIGraphicsGetCurrentContext();const CGFloat* colors = CGColorGetComponents(self.textColor.CGColor);CGContextSetRGBStrokeColor(ctx, colors[0], colors[1], colors[2], 1.0); // RGBACGContextSetLineWidth(ctx, 1.0f);CGSize tmpSize = [self.text sizeWithFont: 阅读全文
posted @ 2012-12-28 11:27 GreyWolf 阅读(169) 评论(0) 推荐(0) 编辑