t-oster/VisiCut — pull request #78 by t-oster (2013-02-22 00:18:37+00:00)
Title: Add support for a Scripting Language...

As discussed here:
http://redmine.laoslaser.org/boards/3/topics/266?r=268#message-268

I want to add scripting features to VisiCut.
This is my first draft. It allows you to write Laser-Jobs in plain JavaScript, while using the pre-defined functions:

move(x, y) - moves the laser-head to the coorinates (in mm) with laser off
line(x, y) - moves the laser-head to the coordinates (in mm) with laser on
set(key, value) - set's the property denoted by key to value for the following commands (keys are what is displayed in "Edit Laser Settings", e.g. "power", "speed", "ventilation")
get(key) - gets a property.

An example file can be found here:
https://github.com/t-oster/VisiCut/blob/feature-laserscript/distribute/files/examples/LaserScriptExample.ls

A build of the latest commit can be found here:
http://137.226.142.25:5080/wwwshare/VisiCutNightly/Experimental/

Comments, Bug-Reports and suggestions welcome.
Happy scripting.