我有一个包含图像的 pdf 文本框。现在我想使用 itext 从代码中以编程方式添加到该图像的超链接。我怎样才能做到这一点?
问问题
1165 次
1 回答
0
Download the ExtractImages and MyImageRenderListener sample code. Rewrite it so that it doesn't extract the images, but use it to get the ImageRenderInfo and use its getMatrix()
method. The Matrix gives you the coordinates and size of the images in your PDF.
Now use these coordinates to create a link annotation as is done in the TimetableAnnotations2 example.
于 2013-02-20T14:54:55.850 回答