Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can I use this DACircularProgress with three color gradient #53

Open
jaysonjh opened this issue May 12, 2015 · 3 comments
Open

can I use this DACircularProgress with three color gradient #53

jaysonjh opened this issue May 12, 2015 · 3 comments

Comments

@jaysonjh
Copy link

Can I use this DACircularProgress with three color gradient?i want DACircularProgress can support more color to fill the Progress;but i did not know how to do.
home_mid_bg

@cuongtv51
Copy link
Contributor

I have just add some gradient for fill progress, you can see at https://github.com/cuongtv51/DACircularProgress/tree/gradient_branch
it not work with 'roundedCorners' property, i will fix it later,
Hope this help you.

@jaysonjh
Copy link
Author

but i need roundedCorners. I try to use BezierPath to draw a image like this:
CGContextSaveGState(ctx);
UIBezierPath* aPath = [UIBezierPath bezierPathWithArcCenter:center
radius:outerRadius
startAngle:startAngle
endAngle:endAngle
clockwise:YES];
aPath.lineWidth = 20.f;
aPath.lineCapStyle = kCGLineCapRound;
aPath.lineJoinStyle = kCGLineCapRound;
[aPath addClip];

// //Draw the image, clipped to the path:
//CGContextDrawImage(ctx, self.bounds, [[UIImage imageNamed:@"ic_progress_coin"] CGImage]);
[[UIImage imageNamed:@"ic_progress_coin"] drawInRect:self.bounds];
CGContextRestoreGState(ctx);

but no roundedCorners effect

@Sergozh
Copy link

Sergozh commented Jul 8, 2015

Hello! Any changes with rounded corners? Bcs its 8th July but no any updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants