How can I change automatically the display name of an application? On apple developer I have found this:
create a folder for every language (es, de, pt etc.)
in each folder you must create a file “InfoPlist.strings”
InfoPlist.strings must have this lines for Englisch language
CFBundleDisplayName = “Thanks app”;
CFBundleName = “ThanksApp”;
and this for Spanish language
CFBundleDisplayName = “Gracias app”;
CFBundleName = “ThanksApp”;
Add this line in the Application/Contents/Info.plist file
Application has localized display name = YES
But the application display name in the finder is always the same English name. A Finder restart doesn’t solve the problem.
[quote=197764:@Horst Jehle]How can I change automatically the display name of an application? On apple developer I have found this:
create a folder for every language (es, de, pt etc.)
in each folder you must create a file “InfoPlist.strings”
InfoPlist.strings must have this lines for Englisch language
CFBundleDisplayName = “Thanks app”;
CFBundleName = “ThanksApp”;
and this for Spanish language
CFBundleDisplayName = “Gracias app”;
CFBundleName = “ThanksApp”;
Add this line in the Application/Contents/Info.plist file
Application has localized display name = YES
But the application display name in the finder is always the same English name. A Finder restart doesn’t solve the problem.[/quote]
This should work. If you inspect an Apple application (e.g. Photo) you will see it’s done in this way.
Just, the name of the folders have “.lproj” extension and they must reside into the Resources folder of the bundle.
Now I have my app in the Dock and in the finder in English, German and Dutch language, but when I open the app, the app name in the apple.menu item is always “Contract Manager”. How can I resolve this?
For example the app “Chess” shows “Schach” in the German language.
If anyone will also support different display names for the application, you can use this script on the build for Mac OS X:
Dim appName As String = CurrentBuildAppName
appName = ReplaceAll(appName, " ", "\ ") // Escape spaces for the command line
Dim appPath As String = CurrentBuildLocation + “/” + appName + “.app”
// Application Display Name in different Languages
command = "/usr/bin/defaults write " + appPath + “/Contents/Info ““Application has localized display name”” YES”
Call DoShellCommand(command)
Dim command As String
// German Display Name
command = “/bin/echo 'CFBundleDisplayName = ““Vertrags Manager””; '>>” + appPath + “/Contents/Resources/de.lproj/InfoPlist.strings”
Call DoShellCommand(command)
command = “/bin/echo 'CFBundleName = ““Contract Manager””; '>>” + appPath + “/Contents/Resources/de.lproj/InfoPlist.strings”
Call DoShellCommand(command)
Doesn’t Apple change the visible name of some system apps when changing localization? For instance, the english Calendar becomes Kalendar. Or Activity Monitor becomes Aktivittsanzeige. This is even done in Finder.
First thank you to all who are engaged with my question. Now I have the complete solution. The important think is to also change the CFBundleName for every language. So you must only use this script in the build for Mac OS X:
Dim appName As String = CurrentBuildAppName
appName = ReplaceAll(appName, " ", "\ ") // Escape spaces for the command line
Dim appPath As String = CurrentBuildLocation + “/” + appName + “.app”
// Application Display Name in different Languages
command = "/usr/bin/defaults write " + appPath + “/Contents/Info ““Application has localized display name”” YES”
Call DoShellCommand(command)
Dim command As String
// German Display Name
command = “/bin/echo 'CFBundleDisplayName = ““Vertrags Manager””; '>>” + appPath + “/Contents/Resources/de.lproj/InfoPlist.strings”
Call DoShellCommand(command)
command = “/bin/echo 'CFBundleName = ““Vertrags Manager””; '>>” + appPath + “/Contents/Resources/de.lproj/InfoPlist.strings”
Call DoShellCommand(command)