CFBundleIconFiles Key is not Showing Up in XCode - iphone

I'm having trouble adding multiple icon files to my application's info.plist file. I've read the docs on Apple's site, and I've read many of the articles here on StackOverflow, but something isn't quite right.
When I open my info.plist file and click the "+" button next to the entry for "Icon File", I make an attempt to add an entry for "Icon files" (notice the added "s"). This entry does not come up in the dropdown list, however. And when I switch the view to "Show Raw Keys/Values", only the CFBundleIconFile shows up. The necessary CFBundleIconFiles (again, notice the "s") does not show up in my dropdown list.
Is there a setting in XCode I need to set to get these new values to show up? I'm running 3.2.6 with SDK 4.3.
Thanks!

If I follow correctly, you're having issues with enabling multiple icon files and their respective resolutions? Apart from setting the main one inside your .plist (as you're using XC3, whereas XC4's interface allows for retina and non-retina selections built in) the others simply need to be in the same place as your main Icon.png file.
This might further help you:
iPhone icon size

Related

Xcode puts Default.png in my plist as an Icon file when I assign a Launch Image

When I set a Launch Image, Xcode creates a copy as Default.png and creates an entry in my plist in Icon Files (iOS 5) / Primary Icon / Icon Items --> Item 1 : Default.png
Item 0 : MyIcon.png is the app icon which I have already placed through the Target.
The reason this is a problem is that the launch image then takes precedence over the actual icon and as a result, it shows as the primary icon instead of my actual icon image.
Why is Xcode doing this?
Can I safely delete the Default.png entry from my .plist? (this seems to fix the problem)
Do I need to copy Default.png somewhere else?
Thanks!
There is also an alternate way. Follow this simple step:
Just delete the Default.png file. Select it again in the summary section project's target settings. you can also drag drop it the on the icon of launch image in the summary section.
The answer is that if you are developing and app for iOS 5, there are two different sections for declaring your icons. The Info editor in the Project editor doesn't show the iOS 5 section. You have to load the file in the Property List editor.
Basically for pre-iOS 5 there is 'CFBundleIconFiles', for iOS 5+ it's 'CFBundleIcons'
Make sure that these have the same icon files names in them.

iPhone how to submit an app with a non-glossy retina display icon?

I noticed that all of my attempts at a retina display 114x114 application icon image automatically have a gradient shadow overlaid on top of them. My icon already has transparency over a black background, and the second gradient shadow makes the background look less black
I noticed that quite a few apps have their icons appear "flat", having no shadow. Is there some flag that I can set in my project to request this semi-circular shadow effect to not be applied to the icon?
Updated:
Xcode 4.2 iOS 5.0 as deployment target.
Only 1 deployment target.
For some reason the suggested solutions do not seem to work.
I have The property added to the target. I see the boolean of YES for both the raw UIPrerendered icon and the "icon already includes gloss effects". I've replaced the icon files and tried different icons. I've uninstalled the app from the development device and reinstalled it. I did a clean. The gloss effect is still there. What am I forgetting?
Update 2: After 45 minutes of messing and losing my sanity, I noticed that there's another Dictionary in the Plist:
Icon files(iOS5). Within that is a Primary Icon Dictionary,
within that is another declaration of "Icon already includes gloss effect". That one is set to NO. Setting that one to YES removes gloss, and makes my icon look awesome :) My guess is that as I migrated the project to iOS5, that key was added
PS. While on the topic of icons, I built an icon maker app for iPhone that allows me to vary the intensity of the gloss effect, as well as include/exclude some icon elements from the gloss. I still have to tell xCode that my icon is "pre-rendered", but I control the gloss effect.
In your Info.plist for your target add the following attribute.
After 45 minutes of messing and losing my sanity, I noticed that there's another Dictionary in the Plist:
Icon files(iOS5). Within that is a Primary Icon Dictionary,
within that is another declaration of "Icon already includes gloss effect". That one is set to NO. Setting that one to YES removes gloss, and makes my icon look awesome :) My guess is that as I migrated the project to iOS5, that key was added
on ios5 (and higher) just go on Targets-->Summary-->App Icons und check on "Prerendered" - glossy effect is then away
Follow the Alex Stone answer and then you need do the below steps if you are using assests catalog to remove gloss effect
To remove the gloss:
Go to the project files navigator in Xcode.
Click on the asset catalog file (Images.xcassets)
Bring up the attributes panel (typically, the far right) when viewing the asset catalog
Click the box labeled 'iOS icon is pre-rendered'
Performing these steps adds the following toward the end of the file Contents.json inside the asset catalog folder:
"properties" : {
"pre-rendered" : true
}
Set the following flag in your info.plist to TRUE.
UIPrerenderedIcon (Icon already includes gloss effects)
If you don't have it, just add it to your info.plist. Use "Show raw keys/values" to show the name of the attribute.
You need to go to the SUMMARY tab for your project and check the "Prerendered" checkbox next to the icons themselves. Boom, Bob's your Uncle. So they say. Nudge nudge, wink, wink, know-what-I-mean ? See Screenshot

iPhone App Icon in Binary

I understand many different sized icons for my app are required for App Store Submission according to Apple's Documentation. However, I am unsure on how to include them? Do I just add them as Icon.png to the Binary?
This is much easier to handle in xcode4 if you have it, just click on your project (should be at the top of the project navigator window) then go to the summary tab, and you can select the icons from there. Then when you build your app, they will be included in the binary
You include them in your project and reference them from your info.plist file under the icon files section.
Here is an updated list of the filenames and sizes you can add: http://www.weston-fl.com/blog/?p=840/

Why is app icon white?

Some recent version of iOS caused my app icon to turn white. I've gone through everything in regards to images and can't find the issue. I'm running Xcode 3.2.5 with sdk 4.2. I do have an entry for "Icon files" in Info.plist with 5 keys:
Item 0 myapp.png
Item 1 myapp#2x.png
Item 2 myapp-72.png
Item 3 myapp-Small-50.png
Item 4 myapp-Small.png
Item 5 myapp-Small#2x.png
All the above have proper dimensions.
I see the image in 'Copy Bundle Resources' and also in the .app file for the simulator version. It is properly reference by name in 'Icon files', Item 0. It is not named Default.png since it is referenced by name in Item 0.
Any suggestions?
You just need those 3 Files:
Icon.png
Icon#2x.png
Icon-iPad.png
Put the names into the Info.plist under Icon Files.
EDIT: Clean your target if it still won't work!
That is what helped me (project summary - app icons are ok, iOS simulator - app icons are ok, iPhone device - blank icon).
Just reconnect your icons to project by dragging them from project navigator to App icon section in project summary.
When does it turn white? If you upgrade an app when it's running, sometimes it appears with a white icon in the "task" bar. This applies to apps you're developing and those download from iTunes. The fix is usually just to kill the app and restart.
That's the simplest answer, but I suspect might not be the solution.
Does the case of the file names in your Info.plist match the actual file names? The Simulator is not case sensitive but the iOS is.
You might also like to make a completely clean build. Don't just do a "Clean" in Xcode, instead manually clear out your build folder.
Finally, when the iPhone 4 first came out I had some issues with the order of the icons referenced in the Info.plist. I never saw white icons (usually just the non-Retina version) but this may be something worth playing with if nothing else works.
The icon file name may be too long if it is a custom file name. This is just a guess, and I hate guessing, but this appears to have been the problem I just had.
I have four targets using the same code but with different icons. I named the icons differently based on the app name, so I could store them in the same directory.
For example:
Icon.png
Icon_second.png
Icon_alternate.png
Icon_second_alternate.png (or Icon_secondalternate.png in case underscores were an issue)
This nomenclature was used for all of the icon names (there's 8 icon files to support iPhone, iPad, retina, etc).
The last one was giving me a problem. Despite a hundred clean/rebuilds, deleting the schema entirely and creating a new one, fruitless efforts, it suddenly occurred to me to try renaming it.
You should be able to name the icons differently, as I still use the first three versions. They are listed in the plist file and render in the project summary, and on the simulator, just fine. The last one rendered in the summary as well. However, I think the length of the file name was too long for the simulator. There must be a length limit. I renamed the fourth one to use the standard Icon.png naming but added it to the fourth target only (images are stored in a separate folder).
CONCLUSION: If you have more than one target for your app, use the standard naming system for all of your icons but add them to separate folders, and then when adding to Xcode just set the build target appropriately.
If you still have the default icon entry (even blank), this can happen, remove that entry in info.plist.
Also, Default.png would be your splash screen.
Load the icons into the Preview application, and make sure they are really png format (and not just named such) by doing a "Save As..." specifying PNG format in the save dialog. Do a Get Info to check the sizes. Make sure the case of all letters in the name match your plist entries.
I had the same problem recently - the Icons I was using were created in GIMP. When I opened them in Photoshop on the development Mac it complained about an ICC color profile. After re-saving the PNGs in Photoshop the Icons worked like a treat.
P.s. I just repeated my steps in creating the images in GIMP, but when saving unticked every extra option that GIMP - by default - was trying to add into the image when saving it. The icons worked perfectly this time around.
If you believe your icon configuration is correct, then you may simply be seeing a bug in Xcode.
As a workaround…
"Clean" your project. Choose Xcode > Product > Clean.
Delete the app from your simulator, or even reset the Simulator by choosing iOS Simulator > Reset Content and Settings.
Quit both the iOS Simulator and XCode apps, then restart them.

How to disable highlighting of the app icon?

How can I disable the highlighting that appears on my icon while it's being displayed on the home page of iPhone?
Thanks.
The easiest way is to check the Prerendered check box on your target's Summary tab:
Alternatively, set the value of Icon files (iOS 5) > Primary Icon > Icon already includes gloss effects to YES in your application's Info.plist.
In new xcode 4 all you need is to add a new entry and search the following in list:
"Icon already includes gloss effects"
Example:
Thanks
I tried this several times and became slightly frustrated because it wasn't working. Turns out I already had this option set to NO and hidden under Icon files.
Hopefully this helps someone else.
In Xcode 5 this setting changed place. In order to access it select your xcassets, select the app icon entry and, in the attributes inspector, select the iOS icon is pre-rendered checkbox.
From the iPhone HIG:
Note: If you choose, you can prevent iPhone OS from adding the shine to your icon. To do this, you need to add the UIPrerenderedIcon key to your application’s Info.plist file (read iPhone Application Programming Guide to learn about this file).
Your icon should still measure 57 x 57 pixels, regardless of whether you take advantage of the added shine.
Open your Info.plist file, can also be named ProjectName-Info.plist, and add a new line. The Key-column is a drop down list, click it and scroll through a quite large set of keys in human readable form that are possible to set.
The one you are looking for is called "Icon already includes gloss and bevel effects", that is the human readable form. Writing UIPrerenderedIcon, also works.
Adding this flag will also disable the automatic addition of gloss and bevel in Tunes Store, and on the App Store.
UIPrerenderedIcon is the setting that you want to set.
Actually, it is probably a good idea to read through all of the Info.plist options you can set. It may save you from trying to replicate some functionality that is provided by default.
The "Friendly" version of this key is now displayed by XCode 4 as "Icon already includes gloss effects" in case anyone else has trouble finding it.
Set UIPrerenderedIcon to true in your Info.plist.
From Xcode 4.3 there is a checkbox called "Prerendered" next to the icon in the Target/Summary configuration. Check that and the shine will be not added. For me "Icon already includes gloss effects" did not work.
With Xcode 4.3.2, you can also use the Key Icon already includes gloss effects and set it's value to YES. This removed the glossy shine for me from my app icon.