现在的位置: 首页 > 综合 > 正文

UITextField 的常用总结

2013年09月19日 ⁄ 综合 ⁄ 共 412字 ⁄ 字号 评论关闭

1.UITextField的初始化和设置

1 textField
= [[UITextField alloc] initWithFrame:CGRectMake(120.0f, 80.0f, 150.0f, 30.0f)];
2 [textField
setBorderStyle:UITextBorderStyleRoundedRect]; 
//外框类型
3 textField.placeholder
= @
"password"//默认显示的字
4 textField.secureTextEntry
YES//密码
5 textField.autocorrectionType
= UITextAutocorrectionTypeNo;
6 textField.autocapitalizationType
= UITextAutocapitalizationTypeNone;
7 textField.returnKeyType
= UIReturnKeyDone;

抱歉!评论已关闭.