Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在 XCode 中创建了一个文本字段,而不是 Interface Builder。在 IB 中,您可以选择不同的键盘类型。你怎么能在 XCode 中做同样的事情?
房产怎么样keyboardType?
keyboardType
1)在xib中,您可以通过单击键盘类型进行更改,如下所示
2)您可以通过编程方式设置 textField.keyboardType = UIKeyboardTypeNumbersAndPunctuation;