作者:飞翔1 | 来源:互联网 | 2023-01-02 14:14
IamtryingtodeterminethebestapproachonAndroidforsupportingmultiplelanguages.Iunderstan
I am trying to determine the best approach on Android for supporting multiple languages. I understand how resource folders work, and how they get selected when the activity loads and/or has a configuration change. I also have seen a technique of creating a new locale, assigning it as the default, and broadcasting a config change. This works. But I get the impression from this thread (https://groups.google.com/forum/?fromgroups=#!topic/android-developers/_ZGOTHwzl-w) and the answers from the google framework team this way of doing things is not recommended / supported. So my questions are:
我正在尝试确定Android上支持多种语言的最佳方法。我了解资源文件夹的工作方式,以及在活动加载和/或配置更改时如何选择它们。我还看到了一种创建新语言环境,将其指定为默认语言并广播配置更改的技术。这很有效。但是我从这个帖子(https://groups.google.com/forum/?fromgroups=#!topic/android-developers/_ZGOTHwzl-w)得到的印象和谷歌框架团队的回答这种做法是不推荐/支持。所以我的问题是:
What is the recommended way to support multi languages on the fly without sending the user to the OS menus for language selection?
在不将用户发送到操作系统菜单进行语言选择的情况下,建议何种方式支持多语言?
Same question for keyboard input.
键盘输入的问题相同。
Finally, I see on my Motorola Xoom when I ask the Locale class for supported languages an impressive list. For instance, ja-JP, which I've tested and seen allows me to display Japanese chars. However there is no SIP for this language on the device. Can I download new keyboards to my platform in these cases? It just seems odd to me that the platform would support displaying many more languages than it could input.
最后,当我向Locale类询问支持的语言时,我在我的Motorola Xoom上看到了令人印象深刻的列表。例如,我测试过的ja-JP允许我显示日语字符。但是,设备上没有此语言的SIP。在这些情况下,我可以将新键盘下载到我的平台吗?我觉得该平台支持显示的语言多于输入的语言,这似乎很奇怪。
1 个解决方案