Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode: Application name in OS X cannot be localized?

I have an project named "Multi-Camera Supervisor". I make the "MainMenu.xib" file localized. Here are the menu bar in localized nib file of Xcode:

Xib file for English:

Xib file for Japanese:


But when I ran my application in Xcode, The first item doesn't work. Here are the menu bars when my application ran:

Running menu bar for English:

Running menu bar for Japanese


You can see that the application name was still "Multi-Camera Supervisor" and NOT LOCALIZED.
Meanwhile, the application name appeared in Dock icon was not localized either.
How should I solve this? How can I localize the application name not only in main menu but also in Dock?

like image 808
Andrew Chang Avatar asked Feb 15 '23 20:02

Andrew Chang


1 Answers

Make sure you add a LSHasLocalizedDisplayName key with a boolean value of YES to the app's Info.plist. I believe that key is necessary to make sure the localized CFBundleDisplayName and CFBundleName values are used for the menu.

like image 104
NSGod Avatar answered Feb 24 '23 11:02

NSGod