I have accidentally added a new language in String Catalog by pressing a +
button at the bottom.
However, there is no -
button to remove it(like in Targets for example) and also there is nothing in attributes inspector.
If I select it and press back button on keyboard, it will not show a delete pop-up as it usually does in Xcode. Is there any way to delete it?
2
Answers
Looks like the only way is to go to the
Project settings > Info
and find the language. Press it and then hit the-
button.I encountered the same issue in Xcode 15 and found a solution. To remove an unwanted language localization from the string catalog file, follow these steps:
Go to your project settings by selecting your project in the Project Navigator on the left.
Choose the ‘Info’ tab within your project settings.
Under the ‘Localizations’ section, you’ll find a list of languages. Select the language you want to remove.
Once selected, you’ll notice a ‘-‘ (minus) button at the bottom-left of the language list. Click this button to remove the language from your project’s localizations.
After removing the language in project settings, it’s essential to clean up any localized strings. Navigate to your project’s .String Catalog and make sure to remove all translated string values associated with the keys specific to the language you’re removing. This step is crucial to prevent any lingering localized content.
Finally, rebuild your project by pressing (‘Command + B’) to ensure that the changes take effect.
By following these steps, you can successfully remove unwanted language localizations from your Xcode project.