查找 iOS 中所有可用语言的列表 [英] Looking for a list of all available languages in iOS
问题描述
我似乎无法找到任何给定 iOS 版本中可用的所有语言选项的完整列表.我正在考虑我的应用本地化选项,并希望能够比较不同 iOS 版本中可用的语言选项.
I don't seem to be able to find a comprehensive list of all language options available in any given iOS version. I am considering my options for app localization and would like to be able to compare available language options in different iOS releases.
有人可以告诉我如何以编程方式创建这样的列表吗?
Could someone please tell me how I could create such a list programatically?
我认为这样我可以为任何可用的 iOS 版本生成列表并比较结果.
I think this way I could generate the list for any available iOS version and compare the results.
推荐答案
没有明确的发布列表(据我所知),原因很简单,即使在次要版本更新中,语言环境列表也可能会发生变化.
There is no definite published list (as far as I know), for the simple reason that the locales list might change even in minor version updates.
您最接近此类列表的是 iPhone 技术规范的语言支持部分:
- iPhone 4
- iPhone 3GS
- iPhone 3G
- iPhone 2 实际上缺少此部分
The closes you get to such list is the Language Support section of the iPhone technical specs:
- iPhone 4
- iPhone 3GS
- iPhone 3G
- iPhone 2 is actually missing this section
如果您想要特定iOS 版本 支持的语言和区域设置的最终列表,您应该编写一个使用NSLocale::availableLocaleIdentifiers
获取列表,NSLocale::componentsFromLocaleIdentifier:
提取规范代码(或相应的CFLocale
).
If you want the definitive list of languages and locales supported by specific iOS version, you should write a simple program that uses NSLocale::availableLocaleIdentifiers
to obtain the list, and NSLocale::componentsFromLocaleIdentifier:
to extract the canonical codes (or the corresponding CFLocale
).
这篇关于查找 iOS 中所有可用语言的列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!