Safe Haskell | None |
---|
Graphics.Rendering.Chart.Types
Description
- data Point = Point {}
- data Vector = Vector {}
- data Color = Color {}
- vscale :: Double -> Vector -> Vector
- pvadd :: Point -> Vector -> Point
- pvsub :: Point -> Vector -> Point
- psub :: Point -> Point -> Vector
- type PointMapFn = Point -> Point
- data Rect = Rect Point Point
- data RectEdge
- mkrect :: Point -> Point -> Point -> Point -> Rect
- vmap :: Range -> Range -> Double -> Double
- data CEnv = CEnv {
- cenv_point_alignfn :: Point -> Point
- newtype CRender a = DR (ReaderT CEnv Render a)
- runCRender :: CRender a -> CEnv -> Render a
- c :: Render a -> CRender a
- newtype CairoPointStyle = CairoPointStyle (Point -> CRender ())
- data CairoLineStyle = CairoLineStyle {
- line_width :: Double
- line_color :: Color
- line_dashes :: [Double]
- line_cap :: LineCap
- line_join :: LineJoin
- newtype CairoFillStyle = CairoFillStyle (CRender ())
- data CairoFontStyle = CairoFontStyle {}
- type Range = (Double, Double)
- type RectSize = (Double, Double)
- black :: Color
- grey8 :: Color
- white :: Color
- red :: Color
- green :: Color
- blue :: Color
- defaultColorSeq :: [Color]
- moveTo :: Point -> CRender ()
- lineTo :: Point -> CRender ()
- alignp :: Point -> CRender Point
- setClipRegion :: Point -> Point -> CRender ()
- strokeLines :: [Point] -> CRender ()
- rectPath :: Rect -> CRender ()
- setFontStyle :: CairoFontStyle -> CRender ()
- setLineStyle :: CairoLineStyle -> CRender ()
- setFillStyle :: CairoFillStyle -> CRender ()
- setSourceColor :: Color -> Render ()
- textSize :: String -> CRender RectSize
- data HTextAnchor
- = HTA_Left
- | HTA_Centre
- | HTA_Right
- data VTextAnchor
- = VTA_Top
- | VTA_Centre
- | VTA_Bottom
- | VTA_BaseLine
- drawText :: HTextAnchor -> VTextAnchor -> Point -> String -> CRender ()
- preserveCState :: CRender a -> CRender a
- filledCircles :: Double -> Color -> CairoPointStyle
- hollowCircles :: Double -> Double -> Color -> CairoPointStyle
- hollowPolygon :: Double -> Double -> Int -> Bool -> Color -> CairoPointStyle
- filledPolygon :: Double -> Int -> Bool -> Color -> CairoPointStyle
- plusses :: Double -> Double -> Color -> CairoPointStyle
- exes :: Double -> Double -> Color -> CairoPointStyle
- stars :: Double -> Double -> Color -> CairoPointStyle
- solidLine :: Double -> Color -> CairoLineStyle
- dashedLine :: Double -> [Double] -> Color -> CairoLineStyle
- solidFillStyle :: Color -> CairoFillStyle
- defaultPointStyle :: CairoPointStyle
- defaultFontStyle :: CairoFontStyle
- isValidNumber :: RealFloat a => a -> Bool
Documentation
A point in two dimensions
type PointMapFn = Point -> PointSource
a function mapping between points
A rectangle is defined by two points
mkrect :: Point -> Point -> Point -> Point -> RectSource
Create a rectangle based upon the coordinates of 4 points
The environment present in the CRender Monad.
Constructors
CEnv | |
Fields
|
Instances
runCRender :: CRender a -> CEnv -> Render aSource
newtype CairoPointStyle Source
Abstract data type for the style of a plotted point
The contained Cairo action draws a point in the desired style, at the supplied device coordinates.
Constructors
CairoPointStyle (Point -> CRender ()) |
data CairoLineStyle Source
Data type for the style of a line
Constructors
CairoLineStyle | |
Fields
|
newtype CairoFillStyle Source
Abstract data type for a fill style
The contained Cairo action sets the required fill style in the Cairo rendering state.
Constructors
CairoFillStyle (CRender ()) |
data CairoFontStyle Source
Data type for a font
Constructors
CairoFontStyle | |
Fields
|
setClipRegion :: Point -> Point -> CRender ()Source
strokeLines :: [Point] -> CRender ()Source
stroke the lines between successive points
setFontStyle :: CairoFontStyle -> CRender ()Source
setLineStyle :: CairoLineStyle -> CRender ()Source
setFillStyle :: CairoFillStyle -> CRender ()Source
setSourceColor :: Color -> Render ()Source
data HTextAnchor Source
Constructors
HTA_Left | |
HTA_Centre | |
HTA_Right |
data VTextAnchor Source
Constructors
VTA_Top | |
VTA_Centre | |
VTA_Bottom | |
VTA_BaseLine |
drawText :: HTextAnchor -> VTextAnchor -> Point -> String -> CRender ()Source
Function to draw a textual label anchored by one of it's corners or edges.
preserveCState :: CRender a -> CRender aSource
Execute a rendering action in a saved context (ie bracketed between C.save and C.restore)
Arguments
:: Double | radius of circle |
-> Color | colour |
-> CairoPointStyle |
Arguments
:: Double | radius of circle |
-> Double | thickness of line |
-> Color | |
-> CairoPointStyle |
Arguments
:: Double | radius of circle |
-> Int | Number of vertices |
-> Bool | Is right-side-up? |
-> Color | |
-> CairoPointStyle |
Arguments
:: Double | radius of circle |
-> Double | thickness of line |
-> Color | |
-> CairoPointStyle |
Arguments
:: Double | radius of circle |
-> Double | thickness of line |
-> Color | |
-> CairoPointStyle |
Arguments
:: Double | width of line |
-> Color | |
-> CairoLineStyle |
Arguments
:: Double | width of line |
-> [Double] | the dash pattern in device coordinates |
-> Color | |
-> CairoLineStyle |
isValidNumber :: RealFloat a => a -> BoolSource