Package curve.control

Class Interpreter

java.lang.Object
curve.control.Interpreter

public class Interpreter extends Object

The xxx file format will follow this structure. This structure will be maintained in memory.

All editor screen actions will be fed into this table.

Define hoop:

  • HP width, height

Define colours:

  • CO id, r,g,b
  • CC id - current colour at time of saving, set at end of load

Define layer:

  • LN id
  • LO id1, id2, id3 - layer order
  • LC id - current layer at time of saving, set at end of load

Define points(unique only to complete drawing):

  • PE sid X Y layer_id - end point
  • PC sid X Y layer_id - control point
  • PA sid X Y layer_id colour orientation - area point

Define lines:

  • LS sid ep0 ep1 colour_id(default black) width (default 1)
  • LQ sid ep0 cp ep1 colour_id thickness
  • LC sid ep0 cp0 cp1 ep1 colour_id thickness
  • LD sid - line delete

Move cursor - for ctl z undo:

  • MC x, y, lastx, lasty
  • consecutive cursor will be consolidated if from the same point

Pan Screen:

  • PS x, y

Zoom:

  • ZM scale, last Z scale

Record all actions so they can be unrolled ctl z or re-actioned with ctl y

All measurements in cm, with two decimal places, accurate to 0.1 mm