lovasoa / elm-diagrams

An Elm library for creating diagrams, inspired by Brent Yorgey's Diagrams library for Haskell.

Home Page:http://package.elm-lang.org/packages/vilterp/elm-diagrams/latest

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

elm-diagrams

An Elm library for creating diagrams, inspired by Brent Yorgey's Diagrams library for Haskell.

Support for

  • Layout: Position diagrams next to, above, and atop each other
  • Picking: Given a diagram and a point, find what was clicked on
  • Getting coordinates: Given a tag path, find what coordinates it was placed at in a diagram.
  • Getting width & height of diagrams
  • Rendering with Elm's Graphics.Collage

Under construction; many bugs and TODOs. File them under GitHub Issues.

Examples

There are a few examples under examples/. To run them, run elm-reactor in the root directory of the repository (not the examples directory — if you run it there, the Reactor will not find the library code in Diagrams.elm). Open them in debug mode (click wrench or append "?debug" to URL) to see some interesting signals related to mouse picking.

About

An Elm library for creating diagrams, inspired by Brent Yorgey's Diagrams library for Haskell.

http://package.elm-lang.org/packages/vilterp/elm-diagrams/latest

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:Elm 100.0%