iPhone - 以编程方式选择语言键盘
我正在编写一些具有多种语言的应用程序。我知道我可以将设备设置为具有国际键盘。
如果有一种方法可以为英语单词选择英语键盘,并为我使用的每种语言选择特定的外语键盘,那就太好了。
有谁知道这是否可能,以及如何实现?
I'm writing some apps that have multiple languages. I know I can set up the devices to have international keyboards.
What would be terrific is if there was a way to select the English keyboard for the english words and the specific foreign keyboard for each language that I use.
Does anyone know if this is possible, and how?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
由用户决定他们始终使用哪些键盘。如果他们启用了多种语言,那么他们可以在不离开视图的情况下在它们之间自由切换,因为为此目的添加了一个额外的按钮。您无法提示用户可能需要哪种语言。
您可以调整的这些属性由 UITextInputTraits 给出协议,这样应该给出您可以指定的内容的完整列表。我相信它们都通过 Interface Builder 和/或 Xcode 4 暴露在相关控件上,所以应该不足为奇。
It's up to the user which keyboards they use at all times. If they have multiple languages enabled then they can switch between them freely without leaving the view, as an extra button is added for the purpose. You can't give a hint as to which language the user is likely to want.
Those properties you can adjust are given by the UITextInputTraits protocol, so that should give a full list of things you can specify. I believe they're all exposed on the relevant controls by Interface Builder and/or Xcode 4, so shouldn't be much of a surprise.
很抱歉让您失望,但您所要求的根本不可能。
I'm sorry to disappoint you, but what you're asking is simply not possible.