packages feed

wumpus-tree 0.11.1 → 0.12.0

raw patch · 8 files changed

+56/−58 lines, 8 filesdep ~containersdep ~vector-spacedep ~wumpus-basicPVP ok

version bump matches the API change (PVP)

Dependency ranges changed: containers, vector-space, wumpus-basic, wumpus-core

API changes (from Hackage documentation)

Files

CHANGES view
@@ -1,4 +1,26 @@ +0.11.0 to 0.11.1:++  * Removed unused @InnerSpace@ constriant on functions in +    @Wumpus.Tree.Draw@.++0.10.0 to 0.11.0:++  * Changed types of drawing functions so they can be run with +    glyph metrics (read from file in the IO monad). ++  * Generalized the unit type of the /design/ functions to some +    numeric @u@ rather than Double.++  * The demo has been duplicated - one version uses GhostScript +    glyph metrics and the other Adobe glyph metrics, as the +    metrics are in different formats and need different font +    loaders from Wumpus-Basic.+  +0.9.0 to 0.10.0:++  * Internal changes to track updates to Wumpus-Basic.+ 0.8.0 to 0.9.0:    * Stopped re-exporting @DrawingContext@ from Wumpus-Basic in 
demo/Demo01.hs view
@@ -16,11 +16,11 @@  import Wumpus.Tree -import Wumpus.Basic.Colour.SVGColours           -- package: wumpus-basic-import Wumpus.Basic.FontLoader.AfmLoader-import Wumpus.Basic.FontLoader.GSLoader-import Wumpus.Basic.Graphic-import Wumpus.Basic.SafeFonts+import Wumpus.Basic.Kernel                      -- package: wumpus-basic+import Wumpus.Basic.System.FontLoader.Afm+import Wumpus.Basic.System.FontLoader.GhostScript+import Wumpus.Drawing.Colour.SVGColours+import Wumpus.Drawing.Text.SafeFonts  import Wumpus.Core                              -- package: wumpus-core @@ -39,15 +39,19 @@     createDirectoryIfMissing True "./out/"     case (mb_gs, mb_afm) of              (Just dir, _) -> do { putStrLn "Using GhostScript metrics..."-                          ; loadGSMetrics  dir ["Times-Roman"] >>= makePictures +                          ; (metrics,msgs) <- loadGSMetrics  dir ["Times-Roman"]+                          ; mapM_ putStrLn msgs+                          ; makePictures metrics                           }       (_, Just dir) -> do { putStrLn "Using AFM v4.1 metrics..."-                          ; loadAfmMetrics dir ["Times-Roman"] >>= makePictures+                          ; (metrics,msgs) <- loadAfmMetrics dir ["Times-Roman"]+                          ; mapM_ putStrLn msgs+                          ; makePictures metrics                           }       _             -> putStrLn default_font_loader_help  -makePictures :: BaseGlyphMetrics -> IO ()+makePictures :: GlyphMetrics -> IO () makePictures base_metrics = do      --     let pic1 = runDrawingU (makeCtx 18 base_metrics) tree_drawing1@@ -70,8 +74,8 @@     writeEPS "./out/tree05.eps"  pic5     writeSVG "./out/tree05.svg"  pic5 -makeCtx :: FontSize -> BaseGlyphMetrics -> DrawingContext-makeCtx sz m = fontface times_roman $ metricsContext sz m+makeCtx :: FontSize -> GlyphMetrics -> DrawingContext+makeCtx sz m = fontFace times_roman $ metricsContext sz m   @@ -84,7 +88,7 @@ -- This should be drawn in the /family tree/ style... --  tree_drawing3 :: DTreeDrawing-tree_drawing3 = drawScaledFamilyTree charNode (uniformScaling 30) tree3+tree_drawing3 = drawScaledFamilyTree charNode (uniformScaling 25) tree3   tree_drawing4 :: DTreeDrawing
src/Wumpus/Tree.hs view
@@ -41,8 +41,8 @@ import Wumpus.Tree.Design import Wumpus.Tree.Draw -import Wumpus.Basic.Dots.AnchorDots             -- package: wumpus-basic-import Wumpus.Basic.Graphic+import Wumpus.Basic.Kernel                      -- package: wumpus-basic+import Wumpus.Drawing.Dots.AnchorDots  import Wumpus.Core                              -- package: wumpus-core 
src/Wumpus/Tree/Base.hs view
@@ -1,4 +1,3 @@-{-# LANGUAGE TypeFamilies               #-} {-# LANGUAGE FlexibleContexts           #-} {-# OPTIONS -Wall #-} @@ -26,10 +25,10 @@    ) where +import Wumpus.Basic.Kernel                      -- package: wumpus-basic+import Wumpus.Drawing.Dots.AnchorDots  import Wumpus.Core                              -- package: wumpus-core-import Wumpus.Basic.Dots.AnchorDots             -- package: wumpus-basic-import Wumpus.Basic.Graphic  import Data.Tree @@ -45,7 +44,6 @@ -- type CoordTree u a = Tree (Point2 u, a) -type instance DUnit (CoordTree u a) = u   type TreeNode u = DotLocImage u
src/Wumpus/Tree/Design.hs view
@@ -31,7 +31,7 @@  import Wumpus.Tree.Base -import Wumpus.Basic.Graphic             -- package: wumpus-basic+import Wumpus.Basic.Kernel              -- package: wumpus-basic  import Data.List  import Data.Maybe
src/Wumpus/Tree/Draw.hs view
@@ -24,10 +24,11 @@  import Wumpus.Tree.Base +import Wumpus.Basic.Kernel                      -- package: wumpus-basic+import Wumpus.Drawing.Dots.AnchorDots+ import Wumpus.Core                              -- package: wumpus-core -import Wumpus.Basic.Dots.AnchorDots-import Wumpus.Basic.Graphic      import Control.Monad@@ -109,7 +110,7 @@    where      hh         = halfHeight pt_from p1      downtick   = straightLine (vvec (-hh)) `at` pt_from-     horizontal = midline (vdisplace (-hh) pt_from) xs +     horizontal = midline (displaceV (-hh) pt_from) xs       upticks    = map (straightLine (vvec hh) `at`) xs  midline :: (Fractional u, Ord u) => Point2 u -> [Point2 u] -> Graphic u@@ -131,5 +132,5 @@     | otherwise = openStroke $ vertexPath [a,m1,m2,b]    where     hh = halfHeight a b-    m1 = vecdisplace (vvec (-hh)) a  -    m2 = vecdisplace (hvec $ xb - xa) m1+    m1 = displaceV (-hh)     a  +    m2 = displaceH (xb - xa) m1
src/Wumpus/Tree/VersionNumber.hs view
@@ -22,7 +22,7 @@  -- | Version number ----- > (0,11,1)+-- > (0,12,0) -- wumpus_tree_version :: (Int,Int,Int)-wumpus_tree_version = (0,11,1)+wumpus_tree_version = (0,12,0)
wumpus-tree.cabal view
@@ -1,5 +1,5 @@ name:             wumpus-tree-version:          0.11.1+version:          0.12.0 license:          BSD3 license-file:     LICENSE copyright:        Stephen Tetley <stephen.tetley@gmail.com>@@ -32,34 +32,7 @@   .   Changelog:   .-  0.11.0 to 0.11.1:-  .-  * Removed unused @InnerSpace@ constriant on functions in -    @Wumpus.Tree.Draw@.-  .-  0.10.0 to 0.11.0:-  .-  * Changed types of drawing functions so they can be run with -    glyph metrics (read from file in the IO monad). -  .-  * Generalized the unit type of the /design/ functions to some -    numeric @u@ rather than Double.-  .-  * The demo has been duplicated - one version uses GhostScript -    glyph metrics and the other Adobe glyph metrics, as the -    metrics are in different formats and need different font -    loaders from Wumpus-Basic.-  .  -  0.9.0 to 0.10.0:-  .-  * Internal changes to track updates to Wumpus-Basic.-  .-  0.8.0 to 0.9.0:-  .-  * Stopped re-exporting @DrawingContext@ from Wumpus-Basic in -    the module Wumpus.Tree. Clients must now import -    @Wumpus.Basic.Graphic@ to get the @DrawingContext@ type and -    the constructor @StandardContext@.+  v0.11.1 to v.0.12.0:   .   * Internal changes to track updates to Wumpus-Basic.   . @@ -77,10 +50,10 @@ library   hs-source-dirs:     src   build-depends:      base              <  5, -                      containers        >= 0.3.0     && < 0.6.0,-                      vector-space      >= 0.6,-                      wumpus-core       == 0.40.0,-                      wumpus-basic      == 0.13.0+                      containers        >= 0.3.0     && <= 0.6.0,+                      vector-space      >= 0.6       && <  1.0,+                      wumpus-core       == 0.41.0,+                      wumpus-basic      == 0.14.0       exposed-modules: