Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Support of iOS 5.0 icons with XCode 5

I'm using the new asset catalog AppIcon to set the right icons for iOS 5 (in theory), 6 and 7. Unfortunately, when installing the application on my iPad 1 (with iOS 5.1.1), the displayed icon is not the right one (it's upscaled from another one, certainly the 57x57 one).

I saw that after creating the asset catalog, 2 empty entries are added in the Info.plist file:

  • Icon files (iOS 5)
  • CFBundleIcons~ipad

I've read a lot of "solutions", but nothing worked for me :(

One of the solution was to add these entries in the plist (and add the corresponding icons in the project):

<key>CFBundleIcons</key>
<dict>
    <key>CFBundlePrimaryIcon</key>
    <dict>
        <key>CFBundleIconFiles</key>
        <array>
            <string>Icon.png</string>
            <string>[email protected]</string>
            <string>Icon-72.png</string>
            <string>[email protected]</string>
        </array>
        <key>UIPrerenderedIcon</key>
        <true/>
    </dict>
</dict>
<key>CFBundleIcons~ipad</key>
<dict>
    <key>CFBundlePrimaryIcon</key>
    <dict>
        <key>CFBundleIconFiles</key>
        <array>
            <string>Icon-Small</string>
            <string>Icon-Small-50</string>
            <string>[email protected]</string>
            <string>Icon-72.png</string>
        </array>
        <key>UIPrerenderedIcon</key>
        <true/>
    </dict>
</dict>

But it's not working at all.

I'm using XCode 5.0 (5A1413).

Any help would be really appreciated.

like image 417
Alx Avatar asked Oct 07 '13 08:10

Alx


People also ask

How to set the iOS app icon in Xcode?

Method one is just used to set app icon in the iOS simulator, if you want to set the iOS app icon when the app is published to the Apple app store, you should follow the below steps. When you create an Xcode project use one template such as Single View App, there is an assets catalog file created in the project file list.

What versions of iOS are supported by Xcode?

OS: The iOS, iPadOS, macOS, tvOS, and watchOS versions supported by this version of Xcode for developing, installing, and debugging applications. Simulator: Versions of iOS, tvOS, and watchOS simulators supported for development by this version of Xcode.

What is the size of the iOS 11 icon?

Note: the icon size of iOS 11 must be 120*120 pixels. In the Xcode project, right-click the info.plist file and select Add Files to “project name” menu item.

What's new in Xcode 6?

On June 2, 2014 at the Worldwide Developers Conference, Apple announced version 6 of Xcode. One of the most notable features was support for Swift, an all-new programming language developed by Apple. Xcode 6 also included features like Playgrounds and live debugging tools.


1 Answers

I finally found a working solution. I don't use anymore the asset catalog. And I put these lines in my info.plist file:

<key>CFBundleIconFile</key>
<string>Icon-57.png</string>
<key>CFBundleIconFiles</key>
<array>
    <string>Icon-72.png</string>
    <string>[email protected]</string>
    <string>Icon-57.png</string>
    <string>[email protected]</string>
    <string>[email protected]</string>
    <string>Icon-60.png</string>
    <string>[email protected]</string>
    <string>Icon-76.png</string>
    <string>[email protected]</string>
    <string>Icon-29.png</string>
    <string>[email protected]</string>
    <string>Icon-50.png</string>
    <string>[email protected]</string>
    <string>Icon-40.png</string>
</array>
<key>CFBundleIcons</key>
<dict>
    <key>CFBundlePrimaryIcon</key>
    <dict>
        <key>CFBundleIconFiles</key>
        <array>
            <string>[email protected]</string>
            <string>Icon-57.png</string>
            <string>Icon-72.png</string>
        </array>
        <key>UIPrerenderedIcon</key>
        <true/>
    </dict>
</dict>

It's working like a charm now :)

like image 187
Alx Avatar answered Oct 03 '22 03:10

Alx