简体   繁体   English

Delphi TAcroPDF - 禁用保存按钮、工具栏面板和右键单击弹出菜单

[英]Delphi TAcroPDF - disable Save button, toolbar panel and rightclick popupmenu

I am working with strong restricted environment.我在强大的受限环境中工作。 Application can show PDF files inside window, but I would like to disable some features: - save button - show toolbar Adobe Reader button - right click mode - use only hand tool应用程序可以在窗口内显示 PDF 文件,但我想禁用一些功能: - 保存按钮 - 显示工具栏 Adob​​e Reader 按钮 - 右键单击​​模式 - 仅使用手动工具

The PDF file should be only in ReadMode, with possibility to print. PDF 文件应仅处于读取模式,可以打印。

I am used "#toolbar=0&navpanes=0" as parameter, but toolbars could be activated by right click.我使用“#toolbar=0&navpanes=0”作为参数,但可以通过右键单击激活工具栏。

Any ideas or other, more flexible and free library for PDF ?任何想法或其他更灵活和免费的 PDF 库?

Windows 7 x64, Delphi Seattle Adobe Reader XI Windows 7 x64,Delphi Seattle Adob​​e Reader XI

I'm posting this as an answer partly because there is more to say than will fit in a comment.我将此作为答案发布,部分原因是要说的比评论中的要多。

Firstly, iirc, the automation of Acrobat Reader was only ever intended to assist it being embedded in IE and, over the years, there have been some changes which were apparently intended to restrict other use (even supposing your current Reader licence permits it).首先,iirc,Acrobat Reader 的自动化只是为了帮助它嵌入到 IE 中,多年来,已经发生了一些明显旨在限制其他用途的更改(即使假设您当前的 Reader 许可证允许它)。

Anyway, in your position, I would implement the PDF functions by calls to the PdfTK utility无论如何,在您的位置上,我将通过调用 PdfTK 实用程序来实现 PDF 函数

https://www.pdflabs.com/docs/pdftk-man-page/ https://www.pdflabs.com/docs/pdftk-man-page/

having checked its licence of course.当然已经检查了它的许可证。

I've always found PdfTK to be ultra-reliable and it can do things that even the automation library of the full Acrobat cannot, like "flattening" PDF documents, properly embedding watermarks, etc.我一直发现 PdfTK 非常可靠,它可以完成即使是完整 Acrobat 的自动化库也无法做到的事情,例如“展平”PDF 文档、正确嵌入水印等。

Btw, PdfTK is a command-line utility and operates on files, so requires access to a file system, which may of course rule it out for your situation.顺便说一句,PdfTK 是一个命令行实用程序,可以对文件进行操作,因此需要访问文件系统,这当然可以根据您的情况排除它。

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

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