Transformations for the Adobe ExtendScript API Documentation
This project contains the XSLT transformation files for creating a readable documentation of the Adobe ExtendScript APIs. The transformation is optimised for the InDesign DOM, but should work for other Adobe Extendscript DOMs as well. The files are transformed to DITA XML data model. I found the intermediate format particularly helpful for validating all references. It could also used to add more help information via DITA Topics by your own. You can set up your own DITA-OT Transformation to publish an output format of your like. I rendered a WebHelp Documentation with oXygen DITA-OT Webhelp.
Before you start
- Java and XSLT 2.0 Processor. For example Saxon XSLT Processor
- Put the Adobe InDesign and ExtendScript Toolkit source files in Folder
XML file locations
The XML source files can be found in the following locations on Mac OS X.
/Library/Application Support/Adobe/Scripting Dictionaries CC/CommonFiles
On Windows the Files are located at:
C:\Program Files (x86)\Common Files\Adobe\Scripting Dictionaries CC\CommonFiles\
The copyright of the original Files is by Adobe Systems Incorporated.
The idea is, to create a merged and fixed DOM/API XML file. From this file several formats can be achieved. In this repository the XSLT for DITA (as used in the webhelp anbd Sublime Text Code Completions are included.
Create a merged and fixed DOM-File
- Merge the Source files and get rid of namespace bugs with
- Fix DOM Structure for further processing with
fixDom.xsl. All ScriptUI classes are postfixed with
(SUI). Please note: There are some ugly hacks, basically replace() to get it working, probably some unrecognized bugs wil be produced. This file could also serve as a nice datasource for Sublimetext Code Completion Files.
Create DITA Topics
- Transform DOM Structure to DITA Topics and create a DITA Map with
dom2dita.xslYou'll find the results in folder
- Please note: For a readable output format you've to set up an DITA-OT Transformation.
Create Sublime Text Code Completions
- Transform DOM Structure to DITA Topics to Sublime Text Code Completions with
dom2sublimeCodeCompletion.xsl. Use the result from
fixDom.xsl. Create a
jsx.sublime-completionsfile and put this into your Sublime Text Packages folder On Windows:
\Users\[Username]\AppData\Roaming\Sublime Text 3\PackagesOn MacOS: ``/Library/Application Support/Sublime Text 3/Packages`
Other than InDesign
The transformation was adapted for Photoshop. The
dom2dita.xsl has still a lot of "InDesign" Strings and the mini hierarchy won't work.
extendscriptApiDocTransformations by Gregor Fellenz is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
Based on a work at http://www.adobe.com/.
This project ist based on the fantastic ExtendScript API HTML from Theunis de Jong aka Jongware. Without his efforts and inspiration I would not have realized it. Thank you!