Wednesday, August 31, 2011

wumpus-drawing

Copperbox revision 2565.

I've updated the demos so they compile again.

At some point I should re-work them so they are more exemplary - currently they are really just test cases.

Tuesday, August 30, 2011

wumpus-drawing

Copperbox revision 2564.

I've changed the behaviour of pen updating in PathBuilder so it now does what I expect. This has changed the interface so it is a state update rather than a localize (cf. the Writer monad).

Off topic - Happy Birthday J.W.



Monday, August 29, 2011

wumpus-drawing

Copperbox revision 2563.

I've updated all the library code to work with the Path changes in Wumpus-Basic - removal of PathAlgs and replacing the DrawStyle enum type by two enums DrawMode and PathMode.

The demos will need updating.

wumpus

Copperbox revision 2562.

I've removed the PathAlgs code from Wumpus.Basic.Geometry. Having another Path type here was not really merited as it proliferated the number of Path-like objects. I've updated some of Wumpus-Drawing to accommodate this, but at least the shapes are currently broken. Also I've discovered a bug with localPen in the PathBuilder module that's been around a while.


Sunday, August 28, 2011

wumpus-basic

Copperbox revision 2561.

I've added more vector constructors to Displacement, there is now a good set of angular vector builders. Also I've changed the DrawStyle enum and added a similar enum for open and closed paths. This should help reduce the proliferation of path drawing functions in Wumpus-Drawing.

Saturday, August 27, 2011

wumpus-drawing

Copperbox revision 2560.

I've added a new module Paths.HPath for lightweight modular Path building. Paths.Base is not modular as it works directly with absolute paths which don't readily concatenate,  Paths.PathBuilder is modular, but heavyweight as it supports arbitrary decoration during path building.

Tuesday, August 23, 2011

wumpus-drawing

Copperbox revision 2559.

I've updated the demos to work with the connector changes. As connector props are no longer in the Drawing Context, connectors should now be instantiated with a properties record. This is as per the Token module in Parsec.

Monday, August 22, 2011

wumpus-drawing

Copperbox revision 2558.

I've added path division which is a preliminary step towards decorating paths. Because path shortening and tip point and direction queries were already in place, the code was pleasingly simple - it took me more time to realize I already had the pieces in place than it did to code the final algorithm.

Sunday, August 21, 2011

wumpus-drawing

Copperbox revision 2557.

I've fixed the bug with connector spacing / direction that crept in with the last commit. Connectors with spacing now draw correctly for all the connectors except the Bezier curves.


wumpus

Copperbox revision 2556.

I've changed connectors so the connector props are no longer in the DrawingContext and the new implementation should always respect the source and destination separators (they were largely ignored before).

Currently the implementation is a bit buggy...

Saturday, August 20, 2011

wumpus

Copperbox revision 2555.

Fixed a bug in chains where tables counted the row/column iterations incorrectly (Wumpus-Basic).

Finally implemented the squareWE path vamp (Wumpus-Drawing).

Friday, August 19, 2011

wumpus

Copperbox revision 2554.

Preliminary work drawing labelled axes for grids. This highlighted a bug in chains where the start point was iterated with the next-state function before anything had been drawn. The result being that chains never started at the start point.

Thursday, August 18, 2011

wumpus

Copperbox revision 2553.

Updates to the demos in Wumpus-Drawing, plus Tree and Rhythm to work with the Path module name changes.

Wednesday, August 17, 2011

wumpus-drawing

Copperbox revisions 2551 and 2552.

I've updated the directory hierarchy for Paths now that only AbsPaths are supported. Revision 2551 is the code changes, revision 2552 deletes the old Wumpus.Drawing.Paths.Base directory.

Tuesday, August 16, 2011

wumpus-drawing

Copperbox revision 2550.

I've changed PathBuilder to build AbsPaths rather than RelPaths. Also I've simplified the API of AbsPath to promote the idea of extension rather than concatenation.

wumpus

Copperbox revision 2549.

I've bumped version numbers in the cabal files in Wumpus-Basic and Wumpus-Drawing, and I've changed the representation of AbsPath in Drawing. I think Wumpus-Drawing should be able to manage with one path type, rather than need both absolute paths and relative paths. The first step towards this is changing AbsPath so it supports cheap movement, with cheap movement it should be able to cover the use-cases that RelPath previously handled.

Monday, August 15, 2011

new releases - wumpus-basic-0.21.0, wumpus-drawing-0.6.0 and wumpus-tree-0.17.0

Copperbox revision 2547.

Updates to demos and cabal files prior to new releases for Hackage.


Copperbox revision 2548.

New release archives including Wumpus-Tree this time.

wumpus-basic-0.21.0
wumpus-drawing-0.6.0
wumpus-tree-0.17.0

The most notable change is the new distinction in Wumpus-Basic between "drawings" (collective) and graphic "objects" (elementary - possibly grouped). The includes the new LocDrawing module.

Sunday, August 14, 2011

wumpus-tree

Copperbox revision 2546.

I've simplified the one-to-many connector type back to almost its old definition, and uncommented the drawing functions for the other connector styles. All the example trees in Demo01 draw correctly again.

wumpus

Copperbox revision 2545.

I've changed the implementation of LocDrawing so that the run function uses translation, rather than monadically thread an immutable start point (Reader). Trying to thread a start point was tying me up in semantic knots - a rethink was necessary.

This has got simple radial connector tree drawing working again (last commit it compiled but ran with a bug). The other connectors need re-implementing.

Saturday, August 13, 2011

wumpus-tree

Copperbox revision 2544.

Initial work getting Wumpus-Tree to compile again.

The simplest example compiles again, but a lot of code is out of spec (Wumpus-Tree was actually somewhat broken when I diverted my attention to ZSnd / Majalan), so it looks like it needs a substantial re-design.


Friday, August 12, 2011

wumpus-basic

Copperbox revision 2543.

I've added a new drawing LocDrawing that effectively supports a local coordinate system. It works like TraceDrawing, but the result is a LocImage not a picture, so the drawing can be moved, redrawn etc. within a single affine frame.

wumpus

Copperbox revision 2542.

Updates to get Wumpus-Rhythm back working - bug fix to PosObject in Wumpus-Basic re-enabled pivot path drawing in Wumpus-Drawing.

Thursday, August 11, 2011

wumpus-basic

Copperbox revision 2541.

I've moved LocTrace into Wumpus-Basic from Wumpus-Drawing and improved the code so it follows the pattern of the Chain module. The two modules are almost the same, but Chain consumes next moves from a supply of points, whereas LocTrace controls where to go next with turtle like movement.

wumpus-drawing

Copperbox revision 2540.

I've updated Wumpus-Drawing to work with the combinator changes in Wumpus-Basic.

Unfortunately the code seems to be one function call longer in many places, but at least it is uniform.

Wednesday, August 10, 2011

wumpus-basic

Copperbox revision 2539.

I've rationalized the set of combinators exported by the Image, LocImage, LocThetaImage and Connector types. They not have combinators to promote to the object or query; combinators to apply the object or query; and combinators to change between object and query.

wumpus-basic

Copperbox revision 2538.

More restructuring - I've made a separate directory for the collective drawing modules Chain, CtxPicture and TraceGraphic. Elementary drawing objects remain in Kernel.Objects.

wumpus-basic

Copperbox revision 2537.

I've moved the Image and Query types from the Objects.Basis module into their own module Objects.Image.

new releases - wumpus-basic-0.20.0 & wumpus-drawing-0.5.0

Copperbox revision 2536.

New releases for Wumpus-Drawing and Wumpus-Basic.

I won't be making a version of Wumpus-Tree to match these releases as I consider them somewhat interim releases. There are a lot of changes in Wumpus-Basic, which is why I want to put out a new release; but the changes haven't really been consolidated in Wumpus-Drawing. If I waited until I had a consolidated release of Wumpus-Drawing, the change delta may be huge, so putting out the current interim seems preferable.

Wumpus-Basic-0.20.0
Wumpus-Drawing-0.5.0

wumpus-drawing

Copperbox revision 2535.

I've updated most of the examples to run again. A couple are now out-of-spec with Wumpus-Drawing's capabilities, so I've left them as is. I think all the distributed examples compile.


Tuesday, August 9, 2011

wumpus-drawing

Copperbox revision 2534.

I've removed the out-of-date text modules and updated the Multi-line example.

wumpus

Copperbox revision 2533.

I've re-implemented DocText to use PosObject directly, previously the implementation interpreted a syntax tree. The new version is much clearer.

Note - the Text modules in Drawing will need a re-organization as some have been superseded by new code in Wumpus-Basic.

wumpus-basic

Copperbox revision 2532.

I've added rotate text drawing to PosObject.

This is only applicable to single-line text - multi-line text would need a new set of concatenation operations to account for incline.

wumpus-basic

Copperbox revision 2531.

I've moved and re-implemented the simple text functions (PosChar, single and multi-line text) from Wumpus-Drawing to Wumpus-Basic. The PosObject module seems a better home for them.

Monday, August 8, 2011

wumpus-basic

Copperbox revision 2530.

Initial work moving the simple text elements, the ones that just rely on PosObject, from Wumpus-Drawing to Wumpus-Basic. The single character and single line objects don't really merit their own modules - so I'm moving them into the PosObject module.

wumpus-basic

Copperbox revision 2529.

I've changed the obliterate method of the Decorate class. Implementations are now expect to simply swap and accumulated CatPrim for mempty.

wumpus-drawing

Copperbox revision 2528.

I've re-implemented monadic path building. The new version follows the recent improvements to monadic builders like Chain where the run function produces a LocImage and so the monad can support the general drawing classes like DrawingCtxM.

Sunday, August 7, 2011

wumpus

Copperbox revision 2527.

The demos are working again in Basic and Drawing. Pleasingly, the demos that use chains didn't need much to update them. The new chain representation seems like a good improvement, but its handy that the API is almost the same.

wumpus-basic

Copperbox revision 2526.

I've changed the argument order of the run functions to be more conventional (monadic expression first, parameters following). I actually prefer the other way round, but with reflection, being conventional seems better.

wumpus-basic

Copperbox revision 2525.

I've added user state to the Chain monad.

wumpus-basic

Copperbox revision 2524.

I've added Parsec-like user state to the TraceDrawing monad. This should compensate for the loss of expressiveness due to removing the transformer version.

User state is a generic class - adding it to at least Chain is pending...

wumpus-basic

Copperbox revision 2523.

I've updated the demos so they run again and fixed a bug in rendering PosObjects with bounding boxes.

Saturday, August 6, 2011

wumpus-basic

Copperbox revision 2522.

I've re-implemented Chains as a monadic type with an explicit next operation to draw a node and advance the chain.

This is a refinement of the work from Majalan.

wumpus-drawing

Copperbox revision 2521.

I've updated the library code so that Wumpus-Drawing works with the changes to Wumpus-Basic. It is likely some of the examples will need updating.

wumpus-basic

Copperbox revision 2520.

As per the previous post, I've simplified the PosObject type to a reader-writer monad.

wumpus-basic

Copperbox revision 2519.

I've simplified the implementation of AdvObject so it is a fairly idiomatic reader-writer monad, previously it was a rather esoteric "split" object.

Again, this is another simplification due to Majalan.

wumpus-basic

Copperbox revision 2518.

I've removed the transformer version of TraceDrawing. Again, this follows the Majalan experience where it was not possible to implement run functions for transformer versions of many drawing objects. It is actually possible to write a run function for TraceDrawingT but favouring uniformity suggests it is not a compelling exception.

wumpus-basic

Copperbox revision 2517.

I've removed the PrimW type and made the code that previously used it follow the more idiomatic Reader monad style.

This is the first of the code improvements due to Majalan.

majalan-basic

Copperbox revision 2516.

I've remade the PosEvent type. Previously it had a rather exotic implementation because concatenating two PosEvents needed the orientation of the second before it could be computed (!). To avoid this I've added cheap displacement to the event answer type CatPrim. This means CatPrims can be moved after they have been computed, so PosEvent can directly support arrangements such as overlay or side-to-side.

Again, this is another improvement that would be good to back port to Wumpus.

Friday, August 5, 2011

majalan-basic

Copperbox revision 2515.

I've removed the PrimW type so code that collects CatPrims is more like regular Writer monad code. Again, this another simplification that should transfer to Wumpus.

majalan-basic

Copperbox revision 2514.

I've re-implemented AdvEvent as a monad. It actually took quite a bit of debugging so I'd hasten to call the code a definitive improvement on the old version, but it does use prosaic technology (State + Reader) unlike its predecessor. So, it's probably a win on points and a candidate for porting back to Wumpus .

Thursday, August 4, 2011

majalan-basic

Copperbox revision 2513.

I've improved the Chain type so the state is hidden by an existential. This should allow changing chain scheme mid chain as per TikZ. Also, I've added two sample chain schemes.

majalan-basic

Copperbox revision 2512.

I've changed the "next step" code for chains. With the previous formulation I couldn't work out how to write any interesting iterators, with the new one anything that can be written as a unfold should be implementable.

Wednesday, August 3, 2011

majalan-basic

Copperbox revision 2511.

I've removed the transformer versions of the Chain and Turtle monads. The type changes to the non-transformer monads to allow them to use localize on the context invalidated the run functions of the transformers. As I think the new types are the right way to go, I've removed the transformers.

majalan-basic

Copperbox revision 2510.

Work on score representations - primarily the Turtle score object (and design variation CtxTurtle). This has an unfortunate name, but essentially it models turtle drawing as sometimes used in Wumpus.

The work so far has unearthed some problematic design ideas with Wumpus, particularly in relation to context handling - CtxTurtle in Majalan can support the local operation of a reader monad whereas the counterparts in Wumpus cannot.

Tuesday, August 2, 2011

majalan-basic

Copperbox revision 2509.

I've updated Majalan-Basic to match the changes to instrument number resolution in Majalan-Core.

majalan-core

Copperbox revision 2508.

I've changed the instrument number resolution to use a dictionary of (byte) string keys. Whilst this potentially allows conflicts that the previous version avoided it is substantially simpler, so the trade off is acceptable.

fmss

Copperbox revision 2507.

I've updated the FM bell example so it works again. The output now seems to be correct: no syntax errors and "fully featured", i.e. no tricky bits left unimplemented.

Monday, August 1, 2011

fmss

Copperbox revision 2506.

Major simplification / re-working of FMSS.

I've removed the translation phase and changed the ConfigMonad so that FMSS now works essentially as a macro-expander. The ConfigMonad no longer produces a set of datatypes that are translated into Csound code, instead it emits Csound statements "directly". Some ConfigMonad operations actually produce 2 or 3 lines of Csound code, but otherwise there is no translation hence it works like a macro-expander.

I actually spent all of Saturday and Sunday making FMSS much bigger and more complicated (none of the immediate results were worth committing to Copperbox). It had got so complicated by Sunday evening, that I decided all the new code was invalid and a simplification was desperately needed.

Blog Archive

About Me

My photo
Disambiguating biog as there are a few Stephen Tetley's in the world. I'm neither a cage fighter or yachtsman. I studied Fine Art in the nineties (foundation Bradford 1992, degree Cheltenham 1992 - 95) then Computing part-time at Leeds Met graduating in 2003. I'm the Stephen Tetley on Haskell Cafe and Stackoverflow.