[plt-dev] update on experiment in re-implementing MrEd

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sun Mar 29 14:00:42 EDT 2009

At Sun, 29 Mar 2009 18:41:52 +0100, Noel Welsh wrote:
> 1. The Cairo code will be mostly generic, so I think there should be a
> dc base class/mixin/trait in common

Yes.

> 2. The Cairo drawing model is quite different to the dc model. dc is
> immediate -- you call functions and the shapes appear immediately. The
> Cairo model is to specify the path completely and only then stroke
> and/or fill the path. Presumably this enables GPU optimisations. This
> naturally leads to functions like line_to etc. The Cairo model also
> goes beyond dc, offering alpha channel, masking, etc. No doubt you
> know all this. How do you envisage extending the dc to offer these
> features?

`dc<%>' already supports `dc-path%', which is close to the Cairo (i.e.,
PostScript) model. There's also already a global alpha, and we'll add
more things like rotation (or, more generally, a transformation
matrix).

Is masking different from clipping? I guess I'll find out...


BTW, I'm writing this message in a SirMail that's running on top of
`editor<%>' classes that are implemented in Scheme instead of C++
(which is phase 1 of this re-implement MrEd experiment). If testing
continues to go well, I may be able to merge to the trunk soon.



Posted on the dev mailing list.