| Copyright | (c) Marcin Mrotek, 2015 |
|---|---|
| License | BSD-3 |
| Maintainer | marcin.jan.mrotek@gmail.com |
| Stability | experimental |
| Safe Haskell | None |
| Language | Haskell2010 |
| Extensions |
|
Diagrams.Backend.HsQML.Render
Description
Interface to the Diagrams backend machinery.
- data HsQML = HsQML
- sizeSpec :: Functor f => (SizeSpec2D -> f SizeSpec2D) -> Options HsQML R2 -> f (Options HsQML R2)
- addAnnotation :: String -> DiagramObj ()
- useStyle :: Style R2 -> DiagramObj ()
- renderHsQML :: Options HsQML R2 -> RTree HsQML R2 Annotation -> Render HsQML R2
- renderTrail :: P2 -> Trail R2 -> DiagramObj ()
- renderSeg :: P2 -> Segment Closed R2 -> DiagramObj ()
- closeSeg :: Segment Open R2 -> P2 -> P2 -> DiagramObj ()
Documentation
Constructors
| HsQML |
Instances
| Typeable * HsQML | |
| Backend HsQML R2 | |
| Renderable Text HsQML | |
| Renderable (Path R2) HsQML | |
| Renderable (Trail R2) HsQML | |
| data Options HsQML R2 = HsQMLOptions {} | |
| type Result HsQML R2 = IO (ObjRef (DiagramObj ())) | |
data Render HsQML R2 = HsQMLRender {
|
sizeSpec :: Functor f => (SizeSpec2D -> f SizeSpec2D) -> Options HsQML R2 -> f (Options HsQML R2) Source
A lens from HsQML backend options to a SizeSpec2D.
sizeSpec ::Lens'(OptionsHsQMLR2)SizeSpec2D
addAnnotation :: String -> DiagramObj () Source
Currently not supported, returns mempty.
useStyle :: Style R2 -> DiagramObj () Source
Apply style to a Context2D. Currently supports the following Attributes:
renderHsQML :: Options HsQML R2 -> RTree HsQML R2 Annotation -> Render HsQML R2 Source
Render a RTree to an intermediate representation.
renderTrail :: P2 -> Trail R2 -> DiagramObj () Source
Render a trail, closing loops.