iPhone / iPad上的PDF超链接 [英] PDF hyperlinks on iPhone/iPad

查看:254
本文介绍了iPhone / iPad上的PDF超链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在寻找Google和SO并且还没有找到我的问题的答案,或者至少是最近的答案。

I've been looking around Google and SO and haven't quite found an answer to my question, or at least a more recent answer.

我有一个PDF中包含超链接/热点,并希望在我自己的iPhone / iPad应用程序中显示PDF文件。当用户点击超链接/热点时,我希望用户被带到链接的适当位置(无论是PDF上的其他页面还是应用程序外的网页)。

I have a PDF with hyperlinks/hotspots in it and would like to display the PDF file in my own iPhone/iPad app. When the user clicks on a hyperlink/hotspot I would like the user to be taken to the appropriate location of the link (whether another page on the PDF or a webpage outside of the app).

我在这里发现了许多这样的问题,但大多数都是在6个月前发现的。虽然这可能不是很久以前的事情,但它有点像新技术以及有人在使用新代码/方法来完成它的可能性。我查看了QuartzDemo示例应用程序并编辑了PDF以获得热点,但它不起作用。也许这个能力存在,但没有实现?

I have found many questions like this on here, but most dated over 6 moths ago. While that might not be so long ago, it kind of is in-spite of newer technologies and the probability of someone comping up with new code/way to do it. I looked into the QuartzDemo sample app and edited the PDF to have a hotspot and it does not work. Maybe the ability is there, but not implemented?

我找到了一款功能强大的应用程序! GoodReader应用程序显示我的PDF并允许点击我的PDF中的热点。但是,我想在我自己的应用程序中实现这一点。

I have found one app that DOES work great! The GoodReader app displays my PDF and allows the clicking of hotspots in my PDF. However, I'd like this implemented in my own app.

那么,有没有人在玩这个?有谁找到解决方案?任何人都可以指向其他方向吗?

So, has anyone been playing around with this? Anyone find a solution? Can anyone point others in a direction?

感谢您的时间。

推荐答案

您所说的热点是PDF链接。查看 PDF规范,特别是关于链接批注的第8.4节。然后查看Quartz 2D Programming Guide,包括检查PDF文档结构。您需要熟悉 CGPDF * API调用。

The "hotspots" you speak of are PDF links. Look up the PDF spec, particularly section 8.4 on Link Annotations. Then look over the Quartz 2D Programming Guide including the section on Inspecting PDF Document Structure. You'll want to get familiar with the CGPDF* API calls.

这篇关于iPhone / iPad上的PDF超链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆