iOS UIButton创建
来源:互联网 发布:手机麦克风变声软件 编辑:程序博客网 时间:2024/06/11 22:32
#pragma mark 创建按钮,登录、注册按钮等
+ (UIButton *)createButtonWithColor:(UIColor *)color Title:(NSString *)title TitleColor:(UIColor *)titleColor HighlightedTitleColor:(UIColor *)highlightedColor Font:(UIFont *)font AndCornerRadius:(CGFloat)cornerRadius
{
UIButton *button = [UIButtonbuttonWithType:UIButtonTypeCustom];
[button setBackgroundColor:color];
[button setTitle:titleforState:UIControlStateNormal];
[button setTitleColor:titleColorforState:UIControlStateNormal];
[button setTitleColor:highlightedColorforState:UIControlStateHighlighted];
[button.titleLabelsetFont:font];
button.layer.cornerRadius = cornerRadius;
return button;
}
//登录按钮loginButton 调用时
- (UIButton *)loginButton
{
if (!_loginButton) {
_loginButton = [UIToolcreateButtonWithColor:RGB(240,84, 84) Title:@"登录"TitleColor:[UIColorwhiteColor]HighlightedTitleColor:RGB(128,128, 128) Font:[UIFontsystemFontOfSize:15]AndCornerRadius:2.0];
[_loginButtonaddTarget:selfaction:@selector(loginButtonClicked)forControlEvents:UIControlEventTouchUpInside];
}
return_loginButton;
}
- IOS -- UIButton 代码创建
- IOS UIButton 代码创建
- iOS UIButton创建
- IOS---使用代码创建UIButton
- 【iOS开发】使用代码创建UIButton
- IOS 学习八 代码创建UIButton
- IOS UI 代码创建UIButton,UITextField,UILabel
- UIButton 创建
- 创建UIButton
- 创建UIButton
- 【IOS】UIButton
- iOS-UIButton
- ios UIButton
- IOS UIButton
- UIButton---iOS
- ios-UIButton
- IOS UIButton
- ios uibutton
- mac上安装pygame
- 统计学习方法:k近邻法
- 大二下三月份月总结
- RxJava2+Retrofit2快速接入指南
- 【jzoj5048】【IQ测试】【数据结构】
- iOS UIButton创建
- c++生成公钥和私钥并对字符串加密和解密
- Tomcat7 的目录结构
- 准确率(Precision查准率)召回率(Recall查全率)和F-Meansure、mAP
- openwrt+Linkit7688+WM8960:WM8960下I2S的REFCLK的时钟输出设置
- CentOS6.0安装与配置Tomcat-7
- Cannot create a secure XMLInputFactory 调用webservice借口时
- 网狐架构及代码讲解
- java实现数组全排列