简体   繁体   English

Flex / AIR / HTML PDF可编写脚本的查看器

[英]Flex/AIR/HTML PDF scriptable viewer

I've written a PowerPoint-like application in Flash, and now our client would like to view the speaker notes (a PDF file) on a separate screen while using the application. 我已经在Flash中编写了一个类似于PowerPoint的应用程序,现在我们的客户希望在使用该应用程序时在单独的屏幕上查看演讲者备注(PDF文件)。 What I would need is a separate application/html page which can show the PDF and programmatically change page when the master slide changes. 我需要的是一个单独的application / html页面,当主幻灯片更改时,该页面可以显示PDF并以编程方式更改页面。

Is this possible? 这可能吗?

If so, is it easiest to go with a html page + javascript or a Flex/AIR app? 如果是这样,使用html页面+ javascript或Flex / AIR应用程序最简单吗?

It needs to be done without changing the PDF's, since there are 600+ files that need to be viewable. 由于有600多个文件需要查看,因此无需更改PDF即可完成。

You can embed PDF's in adobe AIR using the html renderer. 您可以使用html渲染器将PDF嵌入到Adobe AIR中。 I've never done it myself, but there are some good answers here: How do I display a PDF in Adobe Flex? 我自己从未做过,但是这里有一些很好的答案: 如何在Adobe Flex中显示PDF? .

There is no way to embed directly a PDF into a Flash application (there is no rendering engine in AS for that). 无法将PDF直接嵌入到Flash应用程序中(在AS中没有呈现引擎)。 The Flash/Flex application are using a trick for rendering PDF (a floating HTML frame which does the rendering using Acrobat plugin). Flash / Flex应用程序使用一种技巧来渲染PDF(使用Acrobat插件进行渲染的浮动HTML框架)。 So in your case the HTML/JS approach is the right one, no need for Flash. 因此,在您的情况下,HTML / JS方法是正确的方法,不需要Flash。

I do not know if you can scroll the PDF using the internal JS api, but I suppose you can. 我不知道您是否可以使用内部JS API滚动PDF,但是我想可以。 It is possible to send events from the browser (read this link) so you will need to read the Acrobat SDK documentation in order to find how to scroll pages. 可以从浏览器发送事件(阅读链接),因此您将需要阅读Acrobat SDK文档才能找到如何滚动页面。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM