1 import sys
; sys
.path
.insert(0, "../..")
7 c
.stroke(path
.line(0, 0, 1, 0))
9 l1a
= c
.layer("1.a", below
="1.b")
11 l1b
.text(0.22, 0, "1b", [color
.rgb
.red
, text
.halign
.center
, text
.vshift
.mathaxis
])
12 l2
.text(0.5, 0, "2", [color
.rgb
.green
, text
.halign
.center
, text
.vshift
.mathaxis
])
13 l1a
.text(0.75, 0, "1a", [color
.rgb
.blue
, text
.halign
.center
, text
.vshift
.mathaxis
])
14 l1a
.stroke(path
.line(0.25, -0.25, 0.25, 0.25), [color
.rgb
.blue
])
16 c
.writeEPSfile("test_layer", page_paperformat
=document
.paperformat
.A4
, page_fittosize
=1)
17 c
.writePDFfile("test_layer", page_paperformat
=document
.paperformat
.A4
, page_fittosize
=1)
18 c
.writeSVGfile("test_layer", page_paperformat
=document
.paperformat
.A4
, page_fittosize
=1)