IOS UITextField. placeholder属性这个提示符的大小和颜色
更新:HHH   时间:2023-1-7


用UITextField都知道,默认有个提示,原理是kvc,监听,

textField.placeholder = @"This is textField.placeholder";  

[textField setValue:[UIColor green] forKeyPath:@"_placeholderLabel.textColor"];  

[textField setValue:[UIFont boldSystemFontOfSize:15] forKeyPath:@"_placeholderLabel.font"];  


返回移动开发教程...