This folder contains example scripts that can be run in the Quickscript window, or from the project view when the kit is opened as a Project. Some of the scripts demonstrate the basics of scripting and interacting with SE. Others demonstrate how to use specific features.
Scripting Examples |
|
| guessing-game.js | Demonstrate basic scripting using a simple number guessing game. |
| insert-component.js | Advanced console features and basic GUI construction/interaction with Java. |
| tool-bar.js | How to use the custom component API to add components to the main application window. |
| editor-listeners.js | Installs event listeners that allow you to react when a new editor is added, or when editors are selected, deselected, or closed. |
| card-deck-example.js | How to simulate a deck of AH cards using the cards library. |
| batch-example.js | Using a script to perform batch processing on components. |
| convert-jpeg2000.js | Batch convert .jp2 images into .png images; useful for working with SE resources if your graphics editing tools do not support JPEG2000. You can also convert images from within a project. |
| ui-library-example.js | Uses the ui library to add a new tab to an investigator editor; the tab has a text field whose content is printed on the back of the card. |
| constant-skill-lines.js | Sets an on-paint handler that modifies the current investigator so that the skill sliders do not vary. |
| config-subpixel.js | Allows configuration of the subpixel anti-aliasing options using controls embedded in the script console. |
| performance.js | Runs timing tests that compare various JavaScript features and perform basic computations. Allows you to compare the various script engine optimization levels (set in the Preferences dialog). Also demonstrates some newer/lesser known features of JavaScript such as destructuring assignment, generators, interaction with Java. |
| filter-accelerator-test.js | Compares the performance of image processing filters with and without a filter accelerator. Filter accelerators were added in 2.1a11 and can be used to speed up compatible image filters on systems with multicore CPUs. |
| page-shape-demo.js | Creates a DIY component that allows you to experiment with the PageShape system. A PageShape allows you to change the margins of a block of mark-up text so that it conforms to a shape. |