diagrams-lib-1.3.0.6: Embedded domain-specific language for declarative graphics

Copyright(c) 2011 diagrams-lib team (see LICENSE)
LicenseBSD-style (see LICENSE)
Maintainerdiagrams-discuss@googlegroups.com
Safe HaskellNone
LanguageHaskell2010

Diagrams.TwoD.Model

Contents

Description

Tools for visualizing diagrams' internal model: local origins, envelopes, traces, etc.

Synopsis

Showing the local origin

showOrigin :: (TypeableFloat n, Renderable (Path V2 n) b, Monoid' m) => QDiagram b V2 n m -> QDiagram b V2 n m Source

Mark the origin of a diagram by placing a red dot 1/50th its size.

showOrigin' :: (TypeableFloat n, Renderable (Path V2 n) b, Monoid' m) => OriginOpts n -> QDiagram b V2 n m -> QDiagram b V2 n m Source

Mark the origin of a diagram, with control over colour and scale of marker dot.

data OriginOpts n Source

Constructors

OriginOpts 

Fields

_oColor :: Colour Double
 
_oScale :: n
 
_oMinSize :: n
 

Instances

oScale :: forall n. Lens' (OriginOpts n) n Source

oMinSize :: forall n. Lens' (OriginOpts n) n Source

Showing an approximation of the envelope

showEnvelope :: (Enum n, TypeableFloat n, Renderable (Path V2 n) b) => QDiagram b V2 n Any -> QDiagram b V2 n Any Source

Mark the envelope with an approximating cubic spline using 32 points, medium line width and red line color.

showEnvelope' :: (Enum n, TypeableFloat n, Renderable (Path V2 n) b) => EnvelopeOpts n -> QDiagram b V2 n Any -> QDiagram b V2 n Any Source

Mark the envelope with an approximating cubic spline with control over the color, line width and number of points.

Showing an approximation of the trace

showTrace :: (Enum n, TypeableFloat n, Renderable (Path V2 n) b) => QDiagram b V2 n Any -> QDiagram b V2 n Any Source

Mark the trace of a diagram by placing 64 red dots 1/100th its size along the trace.

showTrace' :: (Enum n, TypeableFloat n, Renderable (Path V2 n) b) => TraceOpts n -> QDiagram b V2 n Any -> QDiagram b V2 n Any Source

Mark the trace of a diagram, with control over colour and scale of marker dot and the number of points on the trace.

data TraceOpts n Source

Constructors

TraceOpts 

Fields

_tColor :: Colour Double
 
_tScale :: n
 
_tMinSize :: n
 
_tPoints :: Int
 

Instances

tScale :: forall n. Lens' (TraceOpts n) n Source

tMinSize :: forall n. Lens' (TraceOpts n) n Source

tPoints :: forall n. Lens' (TraceOpts n) Int Source

Showing labels of all named subdiagrams