gpt4 book ai didi

ios - 在 iOS 中显示 Powerpoint 演示文稿

转载 作者:行者123 更新时间:2023-12-01 19:03:57 25 4
gpt4 key购买 nike

在我的应用程序中,我有 Dropbox 实现,用户可以从 Dropbox 下载文档并像幻灯片一样一一查看。我的问题是,如果用户下载 .ppt 文件,那么如何在 iPhone 上显示带有所有动画的 powerpoint 演示文稿,而不使用像幻灯片鲨鱼这样的其他应用程序。

最佳答案

唯一的方法是使用 Quick Look Framework .

使用 Quick Look framework提供您无法处理的格式项目的预览,例如 iWork 或 微软办公 .与从 UIDocumentInteractionController 中获得的相比,此框架为您提供了对预览过程的更多控制。类——包括选择预览是在导航 Controller 的上下文中显示还是模态显示(全屏)。该框架中的主要类是 QLPreviewController,它提供了一个用于预览项目的专用 View 。它依赖于 delegate for中介预览 Action ,以及用于提供预览项目的数据源。

iOS 4.2之后,由 Quick Look 预览 Controller 呈现的专用 View 包括一个带有打印项的操作按钮。如果 Controller 可以提供文件的预览,它也可以打印它。没有打印代码供您编写。

要显示 Quick Look 预览 Controller ,您可以使用以下任何选项:

  • 使用 UINavigationController 将其推送到 View 中目的。
  • 以模态方式、全屏方式呈现它,使用presentModalViewController:animated:其父类的方法,UIViewController .
  • 呈现一个文档交互 Controller (如在
    “预览和打开文件。”然后用户可以调用 Quick
    通过从文档中选择“快速查看”来查看预览 Controller
    交互 Controller 的选项菜单。

  • Quick Look 预览 Controller 可以显示以下项目的预览:

    Microsoft Office documents (Office ‘97 and newer)

    iWork documents

    Rich Text Format (RTF) documents

    PDF files

    Images

    Text files whose uniform type identifier (UTI) conforms to the public.text type (see Uniform Type Identifiers Reference)

    Comma-separated value (csv) files

    关于ios - 在 iOS 中显示 Powerpoint 演示文稿,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20988654/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com