About Document Interaction
Explains how to provide item previews and how to register to open specific file types
Previewing a Document or Presenting Options
Use a document interaction controller (an instance of the UIDocumentInteractionController class) to provide users with options for working with files that your application doesn’t directly support, such iWork documents, PDF files, image files, and so on. A document interaction controller can modally present a file preview, and can present a menu containing various options for using the file—such as for opening it in another application or printing the file using AirPrint.
Relevant article: Previewing and Opening Files
Registering Your Support of File Types
If your app can open specific file types, you can register that capability in your Xcode project’s Info.plist file. When another application asks the system for help opening an item of those types, your application will be included in the options menu presented to the user.
Relevant article: Registering the File Types Your App Supports
Opening Files From Other Apps
The system may ask your app to open a specific file and present it to the user. This typically occurs because another app encountered a file of a type that you have registered to support. In this scenario, the system provides your app with a URL to the file and brings your app to the foreground.
Relevant article: Opening Supported File Types
Displaying and Printing Quick Look Previews
To gain even more control over file previews, you can use the Quick Look framework directly. You can choose the style of animation to use when presenting a preview, and can preview a list of items as well as a single item. A Quick Look preview controller also provides built-in AirPrint printing of supported file types.
Relevant article: Using the Quick Look Framework
Next
Copyright © 2010 Apple Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2010-11-15