nanovg-0.6.0.0: Haskell bindings for nanovg

Safe HaskellNone
LanguageHaskell2010

NanoVG.Internal.Paint

Synopsis

Documentation

newtype Extent Source #

Constructors

Extent (V2 CFloat) 
Instances
Eq Extent Source # 
Instance details

Defined in NanoVG.Internal.Paint

Methods

(==) :: Extent -> Extent -> Bool #

(/=) :: Extent -> Extent -> Bool #

Ord Extent Source # 
Instance details

Defined in NanoVG.Internal.Paint

Read Extent Source # 
Instance details

Defined in NanoVG.Internal.Paint

Show Extent Source # 
Instance details

Defined in NanoVG.Internal.Paint

Storable Extent Source # 
Instance details

Defined in NanoVG.Internal.Paint

data Paint Source #

Instances
Eq Paint Source # 
Instance details

Defined in NanoVG.Internal.Paint

Methods

(==) :: Paint -> Paint -> Bool #

(/=) :: Paint -> Paint -> Bool #

Ord Paint Source # 
Instance details

Defined in NanoVG.Internal.Paint

Methods

compare :: Paint -> Paint -> Ordering #

(<) :: Paint -> Paint -> Bool #

(<=) :: Paint -> Paint -> Bool #

(>) :: Paint -> Paint -> Bool #

(>=) :: Paint -> Paint -> Bool #

max :: Paint -> Paint -> Paint #

min :: Paint -> Paint -> Paint #

Read Paint Source # 
Instance details

Defined in NanoVG.Internal.Paint

Show Paint Source # 
Instance details

Defined in NanoVG.Internal.Paint

Methods

showsPrec :: Int -> Paint -> ShowS #

show :: Paint -> String #

showList :: [Paint] -> ShowS #

Storable Paint Source # 
Instance details

Defined in NanoVG.Internal.Paint

Methods

sizeOf :: Paint -> Int #

alignment :: Paint -> Int #

peekElemOff :: Ptr Paint -> Int -> IO Paint #

pokeElemOff :: Ptr Paint -> Int -> Paint -> IO () #

peekByteOff :: Ptr b -> Int -> IO Paint #

pokeByteOff :: Ptr b -> Int -> Paint -> IO () #

peek :: Ptr Paint -> IO Paint #

poke :: Ptr Paint -> Paint -> IO () #

linearGradient :: Context -> CFloat -> CFloat -> CFloat -> CFloat -> Color -> Color -> IO Paint Source #

Creates and returns a linear gradient. Parameters (sx,sy)-(ex,ey) specify the start and end coordinates of the linear gradient, icol specifies the start color and ocol the end color. The gradient is transformed by the current transform when it is passed to fillPaint or strokePaint.

boxGradient :: Context -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> Color -> Color -> IO Paint Source #

Creates and returns a box gradient. Box gradient is a feathered rounded rectangle, it is useful for rendering drop shadows or highlights for boxes. Parameters (x,y) define the top-left corner of the rectangle, (w,h) define the size of the rectangle, r defines the corner radius, and f feather. Feather defines how blurry the border of the rectangle is. Parameter icol specifies the inner color and ocol the outer color of the gradient. The gradient is transformed by the current transform when it is passed to fillPaint or strokePaint.

radialGradient :: Context -> CFloat -> CFloat -> CFloat -> CFloat -> Color -> Color -> IO Paint Source #

Creates and returns a radial gradient. Parameters (cx,cy) specify the center, inr and outr specify the inner and outer radius of the gradient, icol specifies the start color and ocol the end color. The gradient is transformed by the current transform when it is passed to fillPaint or strokePaint.

imagePattern :: Context -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> Image -> CFloat -> IO Paint Source #

Creates and returns an image patter. Parameters (ox,oy) specify the left-top location of the image pattern, (ex,ey) the size of one image, angle rotation around the top-left corner, image is handle to the image to render. The gradient is transformed by the current transform when it is passed to fillPaint or strokePaint.