Copperbox revision 2286.
I've re-implemented DocText as an interpretation like the new relative path drawing. This means I can implement left and right fills properly. One problem, at the moment, is that the code to change drawing properties is convoluted - this indicates that the PosObject in Wumpus-Basic is not right.
Sunday, April 3, 2011
wumpus-drawing
Copperbox revision 2285.
I've added curveto operation and replaced pen-up and pen-down with moveto. I wonder how I didn't initially spot that moveto is as expressive as pen-up / pen-down, less complicated and already present in PostScript...
Also I've added "vamps" on paths - these are basically a moveto combined with a drawn decorative path. Only the moveto forms part of the accumulated path - the dotted square in the doodle below is drawn with a vamp:
I've added curveto operation and replaced pen-up and pen-down with moveto. I wonder how I didn't initially spot that moveto is as expressive as pen-up / pen-down, less complicated and already present in PostScript...
Also I've added "vamps" on paths - these are basically a moveto combined with a drawn decorative path. Only the moveto forms part of the accumulated path - the dotted square in the doodle below is drawn with a vamp:
Saturday, April 2, 2011
wumpus-drawing
Copperbox revision 2284.
I've extended the path command syntax to include multiple segments with DrawingContext changes. This allows paths to change pen colour, line width etc. "during" drawing:
I've extended the path command syntax to include multiple segments with DrawingContext changes. This allows paths to change pen colour, line width etc. "during" drawing:
wumpus-drawing
Copperbox revision 2283.
I've added pen-up and pen-down commands for drawing relative paths. This means the drawing of stroked paths can be broken and resumed - this is something I've not been able to model with a more functional approach. Hopefully this increases the expressiveness of path drawing quite a bit - enough to compensate for the representation change of building with commands rather than functions.
I've added pen-up and pen-down commands for drawing relative paths. This means the drawing of stroked paths can be broken and resumed - this is something I've not been able to model with a more functional approach. Hopefully this increases the expressiveness of path drawing quite a bit - enough to compensate for the representation change of building with commands rather than functions.
wumpus-drawing
Copperbox revision 2282.
Initial work on building relative paths.
Currently paths are built with commands that are interpreted rather than combinators. This might turn out to be simpler - the monad that interprets the commands is quite complicated, and it should be more memory efficient (whether or not this will matter much in practice). At the moment the code can just extend the path and decorate the path with insert patterned after the TikZ command of the same name.
Initial work on building relative paths.
Currently paths are built with commands that are interpreted rather than combinators. This might turn out to be simpler - the monad that interprets the commands is quite complicated, and it should be more memory efficient (whether or not this will matter much in practice). At the moment the code can just extend the path and decorate the path with insert patterned after the TikZ command of the same name.
Friday, April 1, 2011
wumpus-core
Copperbox revision 2281.
I've exposed relative path building functions in the Picture API. Internally, paths are relative in Wumpus-Core but I'd overlooked building them directly in the API.
I've exposed relative path building functions in the Picture API. Internally, paths are relative in Wumpus-Core but I'd overlooked building them directly in the API.
wumpus-drawing
Copperbox revision 2280.
It looks like a relative path is merited. The current path models building a connector between known points, but it is doesn't work for building paths that might want to be drawn as a LocGraphic. This would be the job for a relative path that builds when supplied a start point.
I've renamed the Base module in Drawing.Paths to Absolute so relative alternative can be added.
It looks like a relative path is merited. The current path models building a connector between known points, but it is doesn't work for building paths that might want to be drawn as a LocGraphic. This would be the job for a relative path that builds when supplied a start point.
I've renamed the Base module in Drawing.Paths to Absolute so relative alternative can be added.
Subscribe to:
Posts (Atom)
Blog Archive
About Me
- Stephen Tetley
- 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.

