Is Xcode 5 Asset Catalog backwards compatible with pre-iOS 7?

前端 未结 3 521
太阳男子
太阳男子 2020-12-30 19:17

Xcode 5 introduced Asset Catalog, which seems very cool. However I haven\'t find much information about it. Specifically, I\'m interested whether the usage

相关标签:
3条回答
  • 2020-12-30 19:48

    Yes, it's definitely compatible with iOS6. Not sure about 5.

    However, if you use it with earlier than 7.0 then you are not able to use the resizable images feature of asset catalogs.

    0 讨论(0)
  • 2020-12-30 19:53

    It is unclear if it should be backwards compatible with ios5. I can tell you for sure that it is buggy with ios 5, at least when it comes to app icons asset catalogs for iPad apps.

    If you want to use the assets catalogs to define your app icons for a ios5 compatible iPad app, the icon will appear blury or blank on the iPad (which has ios5). And that is because xcode adds a ^iPad sufix to your icon file names which iOS 5 doesn't know. So when this happens, if the app is a universal app, ios 5 will use a icon which doesn't have a ^iPad suffix (which is actually there for the iPhone version). It will pick the 57x57 version and it will be blurry when resized to 72x72.

    If the app is not an universal app (it is only for iPad), ios 5 on the ipad will find no valid image (since all the icon file names have the ^iPad suffix), resulting in a blank app icon, with a gloss effect on the iPad with ios 5.

    0 讨论(0)
  • 2020-12-30 20:00

    Yes, it is backwards compatible.

    The documentation says:

    Xcode 5 provides different functionality for asset catalogs depending on the deployment target for your project:

    • For all projects, individual images can be loaded using set names.
    • For projects with a deployment target of iOS 7, Xcode compiles your asset catalogs into a runtime binary file format that reduces the download time for your app.

    The new binary file format is only used if your deployment target is set to iOS 7. Otherwise it defaults back to simply putting all of the individual image files into your resources folder, as before.

    0 讨论(0)
提交回复
热议问题