【发布时间】:2011-08-09 14:05:25
【问题描述】:
我在我的 iPad 应用程序中显示本地存储的 pdf。代码如下:
NSString *path = [[NSBundle mainBundle] pathForResource:@"About Downloads" ofType:@"pdf"];
NSURL *targetURL = [NSURL fileURLWithPath:path];
NSURLRequest *request = [NSURLRequest requestWithURL:targetURL];
[pdfWebView loadRequest:request];
现在,默认情况下,您不能从由 UIWebView 呈现的 PDF 中复制文本或图像。有没有办法让用户从 pdf 中复制文本和/或图像?
我对 CATitledLayer 不熟悉,所以我想知道在这种情况下它是否有帮助?
【问题讨论】:
-
从 iOS5 开始更改,您现在可以在 UIWebView 中选择文本。
标签: ios ipad pdf uiwebview catiledlayer