I am working on xcode4 and created a Settings.bundle
for my project. I can edit the Root.plist
file in xcode4 but it is not possible to edit the Root.strings
file. It isn't even displayed in the editor.
I can not expand the en.lproj
folder as you see in the picture.
But when I do right-click, open in external editor it gives me:
Double click on Root.strings
gives me:
I tried it several times, creating a new window-based application project and creating a new Settings.bundle. I always can not localize it. Any ideas?
In XCode 4.2 you have to follow this steps (just a modification of Xcode 3.2.2 and localization of Settings.bundle)
EDIT: Apple fixed, once again, the wrong bug. Their change rendered my workaround useless. It just doesn't work anymore, you can't add files to the Settings.bundle.
Please refer to the answer of Javi for a method that seems to work.
I hope you like ugly workarounds.
New File
I hope this works for you, for me it does.
And if you haven't done it please report the bug at bugreport.apple.com
I'll install the new release now, let's see if this is fixed. Edit: Not fixed.
EDIT: I don't know If I understood your second question correctly. But when you add a localization to the file that appears outside of the bundle it adds a localization folder to the settings.bundle
After adding spanish localization to Root.strings
:
The actual file is in the foo.lproj folder, it just doesn't show them in the xcode sidebar. If you check the location in the file system you'll see they are inside the settings bundle.
Yesterday I checked with a english and german file and it worked correctly in the simulator. I guess it's just a wrong sidebar layout. The underlying locations and the handling of the files seems correct.
For me it worked to change the File Type (in the File Inspector) of the Folder "en.lproj" from "Default / Directory" to "Directory". Magic.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With