packages feed

Thingie 0.5 → 0.51

raw patch · 2 files changed

+14/−14 lines, 2 files

Files

Graphics/Rendering/Thingie/Primitives.hs view
@@ -20,8 +20,8 @@ data Point2D = Point2D Double Double deriving (Show, Read)  -- | A 2D primitive in an arbitrary Cartesian 2d space-data Primitive = -      Arc                                               -- ^ A possibly filled pie slice or arc+data Primitive =       +      Arc                                               -- A possibly filled pie slice or arc         { center   :: Point2D                           -- ^ center of the arc         , radius   :: Double                            -- ^ radius of the arc         , angle1   :: Double                            -- ^ begin angle@@ -31,7 +31,7 @@         , outlined :: Bool                              -- ^ crustless pie?         , clipped  :: Bool }                            -- ^ add this to the clipping plane -    | Curve                                             -- ^ An arbitrary cubic spline+    | Curve                                             -- An arbitrary cubic spline         { begin    :: Point2D                           -- ^ starting point         , curve_segments :: [(Point2D,Point2D,Point2D)] -- ^ A sequential list of curve segments.  Note that the first two points are control points.         , closed   :: Bool                              -- ^ Whether or not to close this curve with a final line@@ -39,7 +39,7 @@         , outlined :: Bool                              -- ^ Whether or not to outline the curve         , clipped  :: Bool }                            -- ^ Add the curve to the clipping plane -    | Line                                              -- ^ An arbitrary series of line segments+    | Line                                              -- An arbitrary series of line segments         { begin    :: Point2D                           -- ^ Starting Point         , segments :: [Point2D]                         -- ^ Line segments.         , closed   :: Bool                              -- ^ Whether or not to finish this curve with a last line from the end segment to the begin point.@@ -49,7 +49,7 @@     | Pen          { moveto :: Point2D }                           -- ^ Move the current point.  Matters for arcs sometimes.  May remove the begin point for Curve and Line in favor of this. -    | Rectangle                                         -- ^ An possibly filled rectangle+    | Rectangle                                         -- An possibly filled rectangle         { topleft  :: Point2D                           -- ^ The top left point         , width    :: Double                            -- ^ The width         , height   :: Double                            -- ^ The height@@ -57,14 +57,14 @@         , outlined :: Bool                              -- ^ Draw the outline?         , clipped  :: Bool }                            -- ^ Add to the clipping plane? -    | Text                                              -- ^ A simple text string+    | Text                                              -- A simple text string         { str        :: String                          -- ^ The string to print           , bottomleft :: Point2D                         -- ^ The anchor point for the text.  Baseline, not bottom.         , filled     :: Bool                            -- ^ Fill the text?  Usually you want this and not outline.         , outlined   :: Bool                            -- ^ Draw the outline?         , clipped     :: Bool }                         -- ^ Add to the clipping plane? -    | Compound                                          -- ^ Use this to create an arbitrary shape before calling fill, stroke, and clip.+    | Compound                                          -- Use this to create an arbitrary shape before calling fill, stroke, and clip.         { primitives :: [Primitive]                     -- ^ primitives to use         , filled :: Bool                                -- ^ fill the result?         , outlined :: Bool                              -- ^ outline the result?@@ -78,14 +78,14 @@ arc :: Primitive -- ^ A unit circle by default, modifiable with record syntax. arc = Arc origin 1 0 (2*pi) False False True False -arc_filled :: Primitive -- ^ A filled unit circle by default, modifiable with record syntax.-arc_filled = Arc origin 1 0 (2*pi) False True False False+arcFilled :: Primitive -- ^ A filled unit circle by default, modifiable with record syntax.+arcFilled = Arc origin 1 0 (2*pi) False True False False  curve :: Primitive -- ^ A cubic spline with a starting point of the origin. curve = Curve origin [] False False True False -curve_filled :: Primitive -- ^ A filled loop with a starting point at the origin.-curve_filled = Curve origin [] True True False False+curveFilled :: Primitive -- ^ A filled loop with a starting point at the origin.+curveFilled = Curve origin [] True True False False  line :: Primitive -- ^ A line starting at the origin. line = Line origin [] False False True False@@ -99,8 +99,8 @@ rectangle :: Primitive -- ^ an outlined rectangle rectangle = Rectangle (Point2D 0 1) 1 1 False True False -rectangle_filled :: Primitive -- ^ A filled, but not outlined rectanglee-rectangle_filled = Rectangle (Point2D 0 1) 1 1 True False False+rectangleFilled :: Primitive -- ^ A filled, but not outlined rectanglee+rectangleFilled = Rectangle (Point2D 0 1) 1 1 True False False  text :: Primitive -- ^ A rendered string starting at the origin. text = Text [] origin True False False 
Thingie.cabal view
@@ -1,5 +1,5 @@ Name:           Thingie-Version:        0.5+Version:        0.51 Cabal-Version:  >= 1.2 License:        BSD3 License-File:   LICENSE