byorgey/diagrams-doc — pull request #1 by ian-ross (2011-11-05 21:54:12+00:00)
Title: Examples...

Here's a first go at this. Go to the example directory, do "ghc --make Build", then "./Build cairo-pdf" and you'll get a directory with all the examples built using the Cairo PDF backend. There are a couple of obvious things to fix: other backends, picking up height and width information for raster backends, etc.

All the examples are built from .lhs that corresponds to the format used in the web pages. The Build script does a bit of file munging to turn these into things that can be built standalone.

I've fiddled with a bunch of examples to make them work with the latest version of the library, but there are two (in the to-do directory) that complain about needing an instance for Fractional (Double, Double) in cubicSpline. I've not looked at fixing that yet.