- (void)drawRect:(CGRect)rect { CGContextRef context = UIGraphicsGetCurrentContext(); // ӨΛඳը CGContextSetFillColor(context,CGColorGetComponents(self.ellips eColor.CGColor)); NSInteger padding = 20; CGRect frame = self.bounds; frame.origin = CGPointMake(padding, frame.size.height * 0.7); frame.size = CGSizeMake(frame.size.width - padding * 2, frame.size.height * 0.2); CGContextFillEllipseInRect(context, frame); }