File: doc/examples/svgdemo4.lhs A demonstration of the PcSet to Svg capability. You can build the svg files in this directory using 'make svg'. General case: a set in an alternative temperament. Now featuring customized rendering. > import qualified Data.PcSets as P To avoid a lot of aggravation in specifying the fields of the Rendering operator, the Svg is NOT being imported qualified as in previous demos: > import Data.PcSets.Svg [19-TET example continued from the discussion in svgdemo3.lhs] As a reminder, here's the C Major scale in 19-TET: > cMajor19 :: P.GenSet > cMajor19 = P.genset 19 [0,3,6,8,11,14,17] Here we will see how the 19-TET C Major scale looks with custom rendering. First, specify the style. The elements in the set will be yellow; the elements out of the set will be blue; the entire circle will be 70% of the frame size; and each pitch class element will be 15% of the main circle's radius. > altRen :: Rendering > altRen = Rendering > { > pxSize = 500, -- default size > lnColor = "black", > psColor = "yellow", -- ps, colors IN the set. > csColor = "blue", -- cs, colors complementary to the set. > axColor = "red", -- axis isn't used here. > relMain = 0.70, -- default is 80% of the frame. > relElem = 0.15, -- default is 10% of the main circle. > relAxis = 0.95 -- axis isn't used here. > } Next we turn it into a string using the primed version of pcSvg: > main :: IO () > main = putStrLn $ pcSvg' altRen cMajor19 --- This file is part of gpcsets: Pitch Class Sets for Haskell Copyright 2009 by Bruce H. McCosar. Distributed under a BSD3 license; see the file 'LICENSE' for details.