Johan Nordberg
Johan Nordberg

Reputation: 3777

Xcode: Export to XLIFF for specific language and not "base"

I've localized my Xcode project, both Storyboard and several strings files. I have used Base Localization for development and also maintained a real Swedish texts in strings files. That all works just fine.

But, now that I will localize to more languages I would like to use Swedish as the source for my xliff exports but I only get texts from the base localization.

Is it possible to create a xliff file from a specific language?

Upvotes: 0

Views: 720

Answers (1)

Gutty1
Gutty1

Reputation: 535

Yes, and is very easy to do it. Once you defined a new localization language for your project and marked all your storyboards, XIB's and also the Localized.strings file to support that language, you just need to select your project root and then from the Editor menu, select the option: Export for localization

You should be able to export all your localizations for all the languages you support localization (the default includes: existing translations) and if you select base language, it will be for your base language (usually English)

if you don't see any other language besides Swedish there, it means you didn't add properly the new language to the project. You should check in your project localizations the number of files per language (should match the number of storyboards + XIB's + Localized.strings files)

Once the XLIFF file is translated, to import it back, from the same menu select the option: Import localizations to import your translations. Xcode will take care of sync back all your strings to the respective files.

Upvotes: 1

Related Questions