Xcode – Bundle Name and Bundle Display Name

xcode

Similar question about Bundle Name and Bundle Display Name have been asked, such as:

What's the difference between "bundle display name" and "bundle name" in cocoa application's info plist

but so far I have not read a very good succinct answer on when you need to use them both, when they may be specified differently, and so on.

The documentation seems to suggest that bundle display name is only useful if you have localization and may hurt performance if you specify it when you don't have localization.

Can someone clear these issues once and for all?

Apple's Documentation

CFBundleName (String – iOS, Mac OS X) identifies the short name of the
bundle. This name should be less than 16 characters long and be
suitable for displaying in the menu bar and the application’s Info
window. You can include this key in the InfoPlist.strings file of an
appropriate .lproj subdirectory to provide localized values for it. If
you localize this key, you should also include the key
“CFBundleDisplayName.”

CFBundleDisplayName (String – iOS, Mac OS X) specifies the display name of the bundle. If you support localized names for your bundle,
include this key in both your information property list file and in
the InfoPlist.strings files of your language subdirectories. If you
localize this key, you should also include a localized version of the
CFBundleName key.

If you do not intend to localize your bundle, do not include this key
in your Info.plist file. Inclusion of this key does not affect the
display of the bundle name but does incur a performance penalty to
search for localized versions of this key.

Before displaying a localized name for your bundle, the Finder
compares the value of this key against the actual name of your bundle
in the file system. If the two names match, the Finder proceeds to
display the localized name from the appropriate InfoPlist.strings file
of your bundle. If the names do not match, the Finder displays the
file-system name.

Best Answer

CFBundleDisplayName is for changing the text below the app icon on your device (and simulator). Yes this is supposed to be localized but there's no tangible penalty in performance to editing it or making it say whatever you want.

To edit this, you can change the "Bundle display name under "info" in the project:

Location of the Bundle display name attribute

CFBundleName not a clue. I can't figure out what this changes or why.

Related Topic