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

Copyright(c) 2011 Brent Yorgey
LicenseBSD-style (see LICENSE)
Maintainerbyorgey@cis.upenn.edu
Safe HaskellNone
LanguageHaskell2010

Diagrams.Animation.Active

Contents

Description

A few utilities and class instances for Active (from the active package). In particular, this module defines

  • An instance of V for Active: V (Active a) = V a
  • HasOrigin, Transformable, and HasStyle instances for Active which all work pointwise.
  • A TrailLike instance for Active p where p is also TrailLike, which simply lifts a pathlike thing to a constant active value.
  • A Juxtaposable instance for Active a where a is also Juxtaposable. An active value can be juxtaposed against another by doing the juxtaposition pointwise over time. The era of juxtapose v a1 a2 will be the same as the era of a2, unless a2 is constant, in which case it will be the era of a1. (Note that juxtapose v a1 a2 and liftA2 (juxtapose v) a1 a2 therefore have different semantics: the second is an active value whose era is the combination of the eras of a1 and a2).
  • An Alignable instance for Active a where a is also Alignable; the active value is aligned pointwise over time.

Synopsis

Documentation

Orphan instances

Juxtaposable a => Juxtaposable (Active a) Source #

An active value can be juxtaposed against another by doing the juxtaposition pointwise over time. The era of juxtapose v a1 a2 will be the same as the era of a2, unless a2 is constant, in which case it will be the era of a1. (Note that juxtapose v a1 a2 and liftA2 (juxtapose v) a1 a2 therefore have different semantics: the second is an active value whose era is the combination of the eras of a1 and a2).

Methods

juxtapose :: Vn (Active a) -> Active a -> Active a -> Active a #

HasStyle a => HasStyle (Active a) Source # 

Methods

applyStyle :: Style (V (Active a)) (N (Active a)) -> Active a -> Active a #

Transformable a => Transformable (Active a) Source # 

Methods

transform :: Transformation (V (Active a)) (N (Active a)) -> Active a -> Active a #

HasOrigin a => HasOrigin (Active a) Source # 

Methods

moveOriginTo :: Point (V (Active a)) (N (Active a)) -> Active a -> Active a #

TrailLike t => TrailLike (Active t) Source # 

Methods

trailLike :: Located (Trail (V (Active t)) (N (Active t))) -> Active t Source #