diff --git a/autotests/folding/highlight.scad.fold b/autotests/folding/highlight.scad.fold new file mode 100644 index 0000000..68de2e0 --- /dev/null +++ b/autotests/folding/highlight.scad.fold @@ -0,0 +1,23 @@ +/*Basic test file +Written by Julian Stirling, 2018 +License: MIT*/ + + +// This is a comment +x=5; +y=6; +z=5; +r=2; +for (n = [-1.5:1:1.5]){ + translate([n*x,0,0]){cubehole([x,y,z],r);} +} + +module cubehole(size,holerad) +{ + $fn=28; + difference() + { + cube(size,center=true); + cylinder(size[2]+1,r=holerad,center=true); + } +} diff --git a/autotests/html/highlight.scad.html b/autotests/html/highlight.scad.html new file mode 100644 index 0000000..31a7b10 --- /dev/null +++ b/autotests/html/highlight.scad.html @@ -0,0 +1,30 @@ + + + +highlight.scad + +
+/*Basic test file
+Written by Julian Stirling, 2018
+License: MIT*/
+
+
+// This is a comment
+x=5;
+y=6;
+z=5;
+r=2;
+for (n = [-1.5:1:1.5]){
+    translate([n*x,0,0]){cubehole([x,y,z],r);}
+}
+
+module cubehole(size,holerad)
+{
+    $fn=28;
+    difference()
+    {
+        cube(size,center=true);
+        cylinder(size[2]+1,r=holerad,center=true);
+    }
+}
+
diff --git a/autotests/input/highlight.scad b/autotests/input/highlight.scad new file mode 100644 index 0000000..3ca4ec3 --- /dev/null +++ b/autotests/input/highlight.scad @@ -0,0 +1,23 @@ +/*Basic test file +Written by Julian Stirling, 2018 +License: MIT*/ + + +// This is a comment +x=5; +y=6; +z=5; +r=2; +for (n = [-1.5:1:1.5]){ + translate([n*x,0,0]){cubehole([x,y,z],r);} +} + +module cubehole(size,holerad) +{ + $fn=28; + difference() + { + cube(size,center=true); + cylinder(size[2]+1,r=holerad,center=true); + } +} \ No newline at end of file diff --git a/autotests/reference/highlight.scad.ref b/autotests/reference/highlight.scad.ref new file mode 100644 index 0000000..8fb00f3 --- /dev/null +++ b/autotests/reference/highlight.scad.ref @@ -0,0 +1,23 @@ +/*Basic test file
+Written by Julian Stirling, 2018
+License: MIT*/
+
+
+// This is a comment
+x=5;
+y=6;
+z=5;
+r=2;
+for (n = [-1.5:1:1.5]){
+ translate([n*x,0,0]){cubehole([x,y,z],r);}
+}
+
+module cubehole(size,holerad)
+{
+ $fn=28;
+ difference()
+ {
+ cube(size,center=true);
+ cylinder(size[2]+1,r=holerad,center=true);
+ }
+}
diff --git a/data/syntax/openscad.xml b/data/syntax/openscad.xml new file mode 100644 index 0000000..b5005df --- /dev/null +++ b/data/syntax/openscad.xml @@ -0,0 +1,164 @@ + + + + + + + + include + import + use + + + echo + for + intersection_for + if + else + module + function + + + + circle + square + polygon + text + + + + sphere + cube + cylinder + polyhedron + + + + + translate + rotate + scale + resize + mirror + multmatrix + color + color + offset + hull + minkowski + + + + union + difference + intersection + + + + abs + sign + sin + cos + tan + acos + asin + atan + atan2 + floor + round + ceil + ln + len + let + log + pow + sqrt + exp + rands + min + max + + + + concat + lookup + str + chr + search + version + version_num + norm + cross + parent_module + + + + Generate + Conditions + Assignments + + + + linear_extrude + rotate_extrude + surface + projection + render + children + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +