diff options
| author | Miguel <m.i@gmx.at> | 2019-03-17 13:26:19 +0100 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2019-03-17 13:26:19 +0100 |
| commit | dd2f9f78760a81ca68658f49663635ef9e128fd5 (patch) | |
| tree | 083a767f0fc94e02735abcd3936d9ffa794a2e05 /simpleSVG/TestSvg.hs | |
| parent | 64053f88a6dfb4a0d1f61125a24e9a655ce61b3f (diff) | |
added my simple haskell svg generator
Diffstat (limited to 'simpleSVG/TestSvg.hs')
| -rw-r--r-- | simpleSVG/TestSvg.hs | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/simpleSVG/TestSvg.hs b/simpleSVG/TestSvg.hs new file mode 100644 index 0000000..cb075d1 --- /dev/null +++ b/simpleSVG/TestSvg.hs @@ -0,0 +1,16 @@ +-- can be run simply via: stack runghc TestSvg.hs > example1.svg + +import SimpleSvg + +svgExample1 = svgAddList (svgEmpty (svgShGray 200) 300 200) $ + [ svgRedLine (0,0) (200,200) + ,svgRedLine (300,0) (100,200) + ,svgBluePoint (33,133) + ,svgBluePoint (33,22) + ,svgBluePoint (66,25) + ,svgFilledTriangle svgBlack svgWhite (20,20) (100,100) (10,90) + ,svgFilledCircle svgWhite svgGreen (150,120) 30 + ]++ + map (svgBluePoint . (,) 250) [50,60..150] + +main = putStr $ svgGenerate svgExample1 |
