I'm creating rounded button for my app with paintcode. The steps I follows are - creating new class derived for UIButton, paste the code generated by paintcode inside (void)drawRect:(CGRect)rect and set button to use my custom class. But I'm doing something wrong because the button doesn't have any shape at all, it's just a label. This is the code I use -
//// Color Declarations
UIColor* strokeColor = [UIColor colorWithRed: 0 green: 0 blue: 0 alpha: 1];
UIColor* fillColor2 = [UIColor colorWithRed: 0.886 green: 0 blue: 0 alpha: 1];
//// Rounded Rectangle Drawing
UIBezierPath* roundedRectanglePath = [UIBezierPath bezierPathWithRoundedRect: CGRectMake(44.5, 45.5, 48, 20) cornerRadius: 4];
[fillColor2 setFill];
[roundedRectanglePath fill];
[strokeColor setStroke];
roundedRectanglePath.lineWidth = 1;
[roundedRectanglePath stroke];