Looking for guidance on implementing JavaScript in PDF files
I am seeking advice from those familiar with adding JavaScript actions to PDF documents, as this is a new area of exploration for me. While I have experience with JavaScript in web development, the specific requirements within a PDF document are unknown to me.
It appears that NitroPDF and Adobe Acrobat are two platforms that support JavaScript functionality in PDFs. Are there established standards regarding the objects and functions used to manipulate PDF files through JavaScript? So far, my research has led me to Adobe documentation, but I am curious if there exists a broader industry standard beyond Adobe's guidelines.
Furthermore, do all PDF viewers have the capability to execute JavaScript actions?
The most comprehensive resource I could find on this topic was Adobe's Acrobat JavaScript Scripting Guide. While NitroPDF also provides information on JavaScript in PDF files, it largely mirrors Adobe's approach.
Additional insights can be gained from Scribus' guide on enhancing PDF forms using JavaScript, although the content is limited to code snippets.
Is it possible to debug JavaScript within a PDF file using an IDE other than Adobe's, with features akin to Firebug? This would greatly enhance the development process.
Note:
Please refrain from discussing methods for manipulating PDFs within a web browser environment. The focus here is specifically on executing JavaScript code directly within a PDF document. I am particularly interested in utilizing functions from quickpdflibrary for adding custom JavaScript functionality to existing PDFs.
An additional valuable resource is Developing with Acrobat JavaScript, which indicates that JavaScript in PDFs is often referred to as AcroJS or Acrobat JavaScript.