Label offset:X : Y :
RoboCompass has 10 drawing commands and 12 helper commands.Drawing commands can be assigned to labels and referenced in other commands.In effect,these commands can be combined in creative ways to produce all sorts of Geometrical constructions.
polygon(comma separated points)polygon(point(2,2),point(4,2),point(3,5)) polygon(A,B,C)
findangle(2 lines or a polygon)findangle(A,B)
As a general rule,where ever point is expected in an expression, we can use either point(2,3) or use its label or use a helper command which calculates and returns a point.Similarly wherever a line is expected we can give the label of a line or the label of two points.
For example arc(A,B,point(2,1),50,40) uses the distance from A to B and draws the arc from point(2,1).(note:- instead of point(2,1) we can use 'C' if we have a point labled C.
pos(polygon or line or arc,index)pos(B,2)
hide(comma separated labels)hide(A,B,C,D) show(A,B,C,D)
group(comma separated objects)C=group(A,B) m=group(a,b,c,d)
A variety of shapes can be created by applying boolean operations on simple shapes.These shapes can be tessellated by transformation commands. For example and(A,B,C)creates a polygonal region common (intersection) to A,B,C where A,B,C can be a arc or a polygon. Similarly or(A,E,polygon(0,0,2,3,4,1)) and diff(A,B) create union and difference of the given regions respectively. Regions with interiors holes are not supported (resulting from an xor operation) but the same result can be created by combining multiple polygons using the group command.
or(comma separated objects)or(A,E,polygon(0,0,2,3,4,1))
All standard Math functions like sin,cos,tan,asin,acos,atan,log,sqrt,max,min are supported. Note:Trignometric functions uses degrees as unit.