我写了以下程序:
{-# LANGUAGE NoMonomorphismRestriction #-}
{-# LANGUAGE FlexibleContexts #-}
{-# LANGUAGE GADTs #-}
import Diagrams.Prelude
import Diagrams.Backend.SVG.CmdLine
main = mainWith (my_diagram :: Diagram B)
my_diagram = circle 1 # fc blue
# lw veryThick
# lc purple
# dashingG [0.2, 0.05] 0
但该程序产生一个黑色轮廓的白色圆圈 - 没有颜色或潇洒。任何人都知道什么可能是错的?
我在Haskell Platform 7.10.2(Windows 8)上的沙箱中运行
P.S。图表版本为1.3,程序生成以下SVG文件:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg xmlns="http://www.w3.org/2000/svg" height="400.0000" stroke-opacity="1" viewBox="0 0 400 400" font-size="1" width="400.0000" xmlns:xlink="http://www.w3.org/1999/xlink" stroke="rgb(0,0,0)" version="1.1">
<defs>
</defs>
<defs>
</defs>
<g stroke-linejoin="miter" stroke-opacity="1.0" fill-opacity="0.0" stroke="rgb(0,0,0)" stroke-width="1.6" fill="rgb(0,0,0)" stroke-linecap="butt" stroke-miterlimit="10.0">
<path d="M 400.0000,200.0000 c 0.0000,-110.4569 -89.5431,-200.0000 -200.0000 -200.0000c -110.4569,-0.0000 -200.0000,89.5431 -200.0000 200.0000c -0.0000,110.4569 89.5431,200.0000 200.0000 200.0000c 110.4569,0.0000 200.0000,-89.5431 200.0000 -200.0000Z"/>
</g>
</svg>