I am translating some UDK Games so there are already some directories like German, English and so on in the Config directory of the UDK Game.
Back in 2010, I had a translation project for an UDK Game and I could set the used language / localization in an INI file (maybe DefaultGame.ini or DefaultEngine.in) but dont know where I did this exactly.
So where do I set the used localization in the right INI file so it will not be overwritten by the files, that are created at the runtime of UDK Games normally?
You can set language in DefaultEngine.ini, in section :
[Engine.Engine]
Language=JPN
so now engine will look for localization files inside "\UDKGame\Localization\JPN" folder
Related
I wanted to try to make a fan translation, and I searched for the localization file through umodel, I managed to find it, but the program does not see that there is something in the folder
umodel_problem
I'm trying to translate iOS application into three languages (English, Polish, Serbian). Currently it is in Slovene. But I have problems with localization. I have set localization in Project/Info for all languages. Now I have four Main.strings files for each language. I have inserted the appropriate translations for each language. The translations are for UI elements that are located in Storyboard. Before I ran my application I have edited scheme and set application language to Polish, but it did not translate the UI. It was still in Slovene. Did I forgot something ?
I have an App whose target audience is based in Malaysia and can read and type in Malaysian Language. I have Localizable.strings file in Malaysian language.
There is an option in iOS for "Bahasa Melayu" in Language selection in Settings.app
I want to know which language should I select in Xcode so that my the device chooses the correct Localizable.strings file.
Any other details I should provide?
You have to use the abbreviation ms.lproj for the folder. I heard, all indonesian countries learn bahasa at school and I created also a folder with the same files inside a folder called id.lproj. Maybe you can tell me, if it's right that most people in Indonesia talk bahasa like a basic language.
The folders should look like this
If you insert the localization folder into your project it looks like this:
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?
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.
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.
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.
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.
I'm trying to build my first localized application. I have all the strings in code translated using NSLocalizedString (for use with genstrings tool). Now I'm bumping into ibtool. How does incremental localization work? Regarding to the manual page, I should write something like this:
$ ibtool --previous-file path/to/prev.xib \
--incremental-file path/to/inc.xib --localize-incremental \
--write path/to/new.xib mod.xib
Where do I get the incremental file? To my understanding if I'm using the version control (git/svn), the "old" file is at few commits ago, the incremental file is the diff and path/to/new.xib is newly produced xib file. mod.nib is a mystery to me. Can anyone explain me how this works? Also - how do I start the localization of a xib if no previous versions are available (i.e. doing not incremental, but initial localization)?
I think their choice of terminology, particularly for --incremental-file, is causing confusion. The idea is that you have an old version of your xib in two languages (source and target) and that you have since changed it in your source-language and want to update the target-language version to match.
Let's take an example. You previously had home.xib in English (source language) and got someone to translate it to French (target language). You've since developed a new feature and you now have an updated version of home.xib in English in which you added a UILabel and a UITextField and moved things around. The command you showed can help you get an updated version of home.xib in French so that it has the new UILabel and UITextField and that things are moved around like in English. Note that any textual content that you set in your new UILabel and UITextField will be added in English and will then need to be translated in the French xib (but you can automate this by adding --import-strings-file and providing the translations in one more file).
So if we map the command you showed to this example:
--previous-file path/to/prev.xib specifies the old English xib
--incremental-file path/to/inc.xib specifies the old French xib
--write path/to/new.xib specifies the new French xib that will be created
mod.xib specifies the new English xib
For your other question regarding how you start the process, really it depends how you will localize your xibs. You'll obviously create the new language versions of the xibs (in XCode, you just add a language to the language list of the xib and the localized xibs are created automatically). And then if you localize them in Interface Builder yourself, then you'll simply make the relevant changes (translation of text and any necessary resizing) in the localized xibs. Or you could extract the text in the xibs into .strings files, get them translated, and inject them into the relevant language version of these xibs. For this, again you will use ibtool but with --generate-strings-file for the extract phase and with --import-strings-file for the inject phase.
I wrote a script for git projects which automates the steps necessary (as described in the answer above) to migrate a change to a different language.
Usage:
migrate_changes.sh <target_language> <xib file without ending>
Example:
After you've committed your changes to the english xib file, run the script at the root of your resource folder.
migrate_changes.sh de MyViewController
Source:
#!/bin/sh
LANG_FROM='en'
LANG_TO=$1
XIB_FILE=$2
FROM_FILE=${LANG_FROM}.lproj/${XIB_FILE}.xib
PREV_FILE=${LANG_FROM}.lproj/${XIB_FILE}_old.xib
TO_FILE=${LANG_TO}.lproj/${XIB_FILE}.xib
# checkout old version of xib file
git show `git log -2 --format="%H" $FROM_FILE | tail -n 1`:./$FROM_FILE > $PREV_FILE
# merge changes
ibtool --previous-file $PREV_FILE --incremental-file $TO_FILE --localize-incremental --write $TO_FILE $FROM_FILE
# remove previous version
rm $PREV_FILE