Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Utilities for creating diagram-building tools

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 latex
Octocat-spinner-32 src
Octocat-spinner-32 .gitignore
Octocat-spinner-32 .travis.yml
Octocat-spinner-32 CHANGES.markdown
Octocat-spinner-32 LICENSE
Octocat-spinner-32 README.markdown
Octocat-spinner-32 Setup.hs
Octocat-spinner-32 diagrams-builder.cabal
README.markdown

Build Status

diagrams-builder provides backend-agnostic tools for dynamically turning code into rendered diagrams, using the hint wrapper to the GHC API. It supports conditional recompilation using hashing of diagrams source code, to avoid recompiling code that has not changed. It is useful for creating tools which compile diagrams code embedded in other documents. For example, it is used by the BlogLiterately-diagrams package (a plugin for BlogLiterately) to compile diagrams embedded in Markdown-formatted blog posts.

An executable specific to the cairo backend is included (more executables specific to other backends will be included in the future). It takes an input file and an expression to render and outputs an image file, using the cairo backend. If you want it you must explicitly enable the cairo flag with -fcairo.

A LaTeX package, diagrams-latex.sty, is also provided in the latex/ directory of the source distribution, which renders diagrams code found within diagram environments. It makes use of the diagrams-builder-cairo executable, so if you want to use diagrams-latex.sty you should install diagrams-builder with the -fcairo option. Note that diagrams-latex.sty is licensed under the GPL.

Something went wrong with that request. Please try again.