不支持 Xcode iOS 8 键盘类型 [英] Xcode iOS 8 Keyboard types not supported
问题描述
我的 .swift
类中有一个 UITextField
Ctrl 拖动为 @Outlet
.现在在 viewDidLoad
我使用这个代码
I have a UITextField
Ctrl-dragged as an @Outlet
in my .swift
class.
Now in viewDidLoad
i'm using this code
self.myTextField.keyboardType = UIKeyboardType.DecimalPad
当我在模拟器上启动我的应用程序并点击 UITextField
我得到这个日志
When i launch my app on simulator and click on the UITextField
i got this log
Can't find keyplane that supports type 8 for keyboard
iPhone-Portrait-DecimalPad;
using 2617181025_Portrait_iPhone-Simple-Pad_Default
我没有崩溃或其他问题,但没有显示键盘.我也尝试从 Storyboard
设置它,但它是一样的.
I have no crash or something but the keyboard is not displayed. I also tried to set it from Storyboard
but it's the same.
我还注意到,每当我点击 any UITextField
时,键盘都不会显示(但默认键盘不会显示日志)
I also noticed that whenever i click on any UITextField
the keyboard is never displayed (but no log is shown for the default keyboard)
我使用的是 Xcode-Beta 3 有没有人遇到过这个问题?
I'm using Xcode-Beta 3 anyone faced this issue?
推荐答案
我在更新到最新的 Xcode Beta 后也遇到了这个问题.模拟器上的设置已刷新,因此正在检测笔记本电脑(外部)键盘.如果您只需按:
I too had this problem after updating to the latest Xcode Beta. The settings on the simulator are refreshed, so the laptop (external) keyboard was being detected. If you simply press:
iOS 模拟器 -> 硬件 -> 键盘 -> 连接硬件键盘iOS Simulator -> Hardware -> Keyboard -> Connect Hardware Keyboard然后软键盘将再次显示.
then the software keyboard will be displayed once again.
这篇关于不支持 Xcode iOS 8 键盘类型的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!