更改Xcode项目的单一语言 [英] Change Single Language of Xcode Project
问题描述
如何在不进行本地化的情况下更改项目使用的默认语言? 如果我希望我的应用使用日语或意大利语怎么办?仅使用日语或意大利语文字就足够了吗?如何更改iTunes上显示的日语或意大利语语言?
How do you change the default language used by your project without doing localization? What if I want my app to be in Japanese or Italian? Is it enough to just use Japanese or Italian texts? How do I change the language displayed on iTunes to say that it's in Japanese or Italian?
推荐答案
通常,假定您放置在主文件夹中的资源位于 iTunes Connect 中设置的Default language
中. >添加或编辑应用程序时.设置位于Application
页面上,如果添加后未正确设置,请单击页面顶部的Edit
以便使用下拉菜单进行更改.
Generally, the resources that you put in the main folder are assumed to be in the Default language
, which is set in iTunes Connect when you add or edit the application. The setting is on the Application
page and if it's not correctly set after adding it, click the Edit
at the top of the page to be able to change it with the drop-down menu.
如果要完全本地化,则需要确保更改localization native
语言,您需要更改与Localization native development region
相对应的Info.plist
中的键(又名en.lproj
,则应为en
).如果特定资源缺少其他本地化版本之一,则将使用此语言.这些天的建议指向使用该语言的2个字母的版本(即,用en
代替English
,用jp
代替Japanese
等)作为最佳实践.
If you're going to localize at all, you'll want to make sure to change the localization native
language, you'll need to change the key in the Info.plist
corresponding to Localization native development region
(a.k.a. CFBundleDevelopmentRegion
in raw form) to match the language you are using for the raw files. The value of the tag should match the original localization language directory base (so en
if you have an english lproj directory named en.lproj
). This language will be used in the event that one of the other localizations is missing for the specific resource. Recommendations these days point to using the 2-letter version of the language (i.e. en
instead of English
, jp
instead of Japanese
, etc) as best-practice.
如果要构建仅日语的应用程序,则可以将所有资源放在顶层.如果要使用日语和任何其他语言,则应将特定于语言的日语资源放在jp.lproj
中,并将CFBundleDevelopmentRegion
设置为jp
.任何未本地化的资源(标准图像等)都可以存储在主应用程序文件夹中.
If you're building a Japanese-only app, you could just put all the resources in the top level. If you're going to have Japanese and any other language, you should put the language-specific Japanese resources in jp.lproj
and set the CFBundleDevelopmentRegion
to jp
. Any unlocalized resources (standard images, etc.) can be stored in the main application folder.
顺便说一句,在OS X中也有相同的通用规则,除了我上面提到的主应用程序文件夹"外,这些文件都在 Resources 文件夹中.
By the way, same general rules in OS X as well, except that wherever I mentioned "main application folder" above, the files would be within the Resources folder.
这篇关于更改Xcode项目的单一语言的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!