2

I recently localized my app and followed through several tutorials on setting up localization.

In my target build info settings, I have both English and Spanish set up with Base Internationalization checked. Build settings

I have my Localizable.strings file in my project which contain both English and Spanish translations.

Localizable Strings

And I have two storyboards - one for English and one for spanish..for both iPhone/iPad. Auto Layout is enabled and I have English and Spanish checked in the storyboard settings. storyboards storyboard settings

When I edit the scheme to run it through the debugger as Spanish - translations work perfectly. I have my iOS device and simulator language set to Spanish and the correct region that all my files are associated with. Although when its not running through Xcode, the app will only be in English, regardless of whether or not the device settings are set to Spanish.

I've deleted the app, cleaned, rebuilt, and re-deployed to both simulator and iOS device. There is still no change. Does anyone know of anything else that I might be missing? Any help would be greatly appreciated.

T S
  • 83
  • 5
  • What exact version of Xcode are you using? Xcode 6 had this bug through several releases. – Michael Teper Jun 02 '15 at 17:13
  • I am running 6.3.2 - the latest update – T S Jun 02 '15 at 17:43
  • It's possible they still haven't fixed the Simulator. Does it behave correctly on a device? – Michael Teper Jun 02 '15 at 17:45
  • It behaves exactly the same on a device. Works when running with Xcode forcing the scheme to use Spanish, but does not work when it is running directly on the device without the debugger hooked up. Tested it on iPhone 5S, iPhone 6 iPod, and iPad Mini. – T S Jun 02 '15 at 17:48
  • Probably a red herring, but I notice that in your screenshot you don't have a Spanish localization of Localizable.strings. – Michael Teper Jun 02 '15 at 20:57
  • Ah yeah, the whole file name is not visible since I had the project navigator a little narrow but its there. – T S Jun 02 '15 at 21:15

1 Answers1

3

After visiting the iOS Dev forms, I found my answer.

My problem was that my localization was set to Spanish (United States) while iOS only supports plain ol' Spanish and Spanish (Mexico). Why they make that option available in Xcode if its not supported? I'm not quite sure...

So, I added the plain ol' Spanish localization to my build info and had to transfer all of my storyboard files, image files, and strings to the new plain ol' Spanish files. Works like a charm now!

T S
  • 83
  • 5