Android:添加对更多语言支持的最佳方式
我有一个使用所有英文文本构建的应用程序。我想添加对其他语言的更多支持,但担心我的用户不一定关心应用程序现在支持西班牙语或我添加的任何需要更新的新语言。另外,如果我每天都纠正错误的翻译,这对用户来说真的很烦人。
一种想法是调用一个网络服务来提供特定本地的内容,这样如果翻译不好或者你有什么,就可以轻松更改。对此的担忧当然是速度。
那么是否有正确的方法或更好的方法来添加/更改本地化中的值而不强迫人们更新?
I have an application that was build with all the text in English. I would like to add more support for other languages, but am concerned about my users who don't necessarily care about the application now having support for Spanish or whatever new language I have added needing to update. Also, if I am correcting bad translations on a daily basis this would be really annoying to users.
One idea is to make calls to a web service that provides the content for there specific local, which would allow for easy changing if there are bad translations and what have you. The concern with this is of course the speed.
So is there a right way or a better way to add/change values in the localization without forcing people to update?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我理解你的问题。我有一个问题。您认为如果您的应用程序每次(例如打开新活动时)都请求外部服务,那么用户不会感到烦恼吗?
在我看来,你应该添加对一种语言的支持,测试你的翻译的正确性(例如,你可以要求使用你的应用程序的另一个国家的用户检查翻译),然后才在市场上更新你的应用程序。如果所有字符串资源都在 xml 文件中,那么支持多种语言并不是很困难。
因此,我对您的建议是首先将所有字符串资源提取到 strings.xml 文件(默认语言文件夹)中,然后创建几个具有附加语言支持的值文件夹。
I understand your problem. And I have one question. Do you think that it will not be annoying for users if your application requests the external service every time when, for instance, new activity is opened?
To my point of view, you should add support of a language, test the correctness of your translation (for instance, you can ask a user from another country who use your application to check the translation) and only then update your app in the market. If all your string resources are in xml files it is not very difficult to support several languages.
So my proposal for you is at first extract all your string resources into strings.xml file (for default language folder), and then just make several values folders with additional language support.
添加本地化通常(如果您遵循良好实践)只需升级一些 XML 文件即可。因此,即使用户升级,也不会花很长时间,而且他们可能不会从市场上注意到(如果他们使用自动更新)。
查看此内容了解更多详细信息。
Adding localization is usually (if you followed the good practices) a matter of upgrading a few XML files. So even if the users upgrade, it won't take long at all and they will probably not notice (if they use autoupdate) from the market.
Check this out for more details.