Script

data class Script(val constants: Map<String, Expression>, val dimension: Expression = Point(Number(100), Number(100)), val backgroundColour: Expression = Colour(Number(255), Number(255), Number(255)), val instructions: List<Instruction>)

Abstract DrawScript script.

Parameters

constants

Constants defined within the scope of the script.

dimension

Display window dimension. Default: (100, 100).

backgroundColour

Display window background color. Default: |255|255|255| (White).

instructions

List of script Instructions.

Constructors

Link copied to clipboard
constructor(constants: Map<String, Expression>, dimension: Expression = Point(Number(100), Number(100)), backgroundColour: Expression = Colour(Number(255), Number(255), Number(255)), instructions: List<Instruction>)

Functions

Link copied to clipboard

Is the script valid? That is, are there no SemanticErrors in it?

Link copied to clipboard
open override fun toString(): String
Link copied to clipboard

Validates the script, outputting a list of SemanticErrors.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard