【发布时间】:2017-03-24 01:32:30
【问题描述】:
我正在努力让渐变层与我的按钮对齐。我希望有人能很快帮助我,这样我的按钮就不会那么糟糕了。
这是我正在使用的:
UIButton *tmpBtn = [[UIButton alloc] initWithFrame:theFrame];
[tmpBtn setTintColor:buttonColor];
[tmpBtn setBackgroundColor:buttonColor];
tmpBtn.layer.cornerRadius = 10;
tmpBtn.layer.borderWidth = 1;
tmpBtn.layer.borderColor = [UIColor blackColor].CGColor;
(buttonColor 被传递到方法中,现在它只是一种颜色)
感谢您的帮助!
【问题讨论】:
标签: ios objective-c uibutton