[whatwg] Canvas suggestions

Jordan OSETE jordan.osete at laposte.net
Tue Apr 17 13:37:16 PDT 2007


Stefan Haustein wrote :
> Hi Jordan,
> 
> in my opinion, preserving the path for re-use does not buy much: Path
> construction at this level is just appending a few coordinates and
> meta-information to an array. Since there is no knowledge about future
> transformations, one needs to keep the original coordinates instead of
> the device coordinates, and it is not possible to calculate segment
> count for Bezier curves etc.
> 
> Moreover, if the path is not re-used, keeping the original coordinates
> is unnecessary overhead.
> 
> I doubt reusing just a simple path with different transformations is a
> significant use case that justifies this overhead,

Now that you say it, it's true that if the web application draws it 
once, drawing it again is as simple as putting the drawing code in a 
separate function and calling it again, with a different transform 
matrix set.

> and most implementations seem not to support it anyway.

Opera 9 seems to support it, though. And if the canvas was created by 
Apple, safari probably does too (Konqueror doesn't seem to have <canvas> 
implemented yet...?).

> So I would prefer to keep it simple and to see the spec reflect the
> current reality over having both or incompatible changes in
> implementations.

You mean replace the spec with the way it currently works in firefox?
Well, i would be OK with that, personnally, but maybe having both 
doesn't mean *significant* overhead?

Anyway it's possible the FF folks want to keep their way anyway (as a 
proprietary extension for now, let's say), for backwards compatibility.
Even if they implement the standard version too in a not-too-distant 
future as well, they will probably keep it. So why not try to find a way 
to have it compatible with the current spec, without removing anything?

Anyway FF is currently quite popular, so if webdesigners design their 
canvas stuff for it, assuming that "it should work like that", other 
implementations will be somehow forced to implement it as well. It's not 
fair, but that's the way it has always been...
That is why i think keeping at least room for improvement in this area 
of the spec would be good. :)

Now what about my other suggestions? Would some of them OK as is, or 
could they be improved to better fit the needs? Am i asking too much 
somewhere?

> 
> Best regards,
> Stefan
Regards.
Jordan

PS: is it OK to post suggestions on the message board (at 
http://forums.whatwg.org/) instead of the mailing lists? Or maybe less 
people would read it? I didn't see any "suggestions" subcategory...
I ask that because i find message boards more "user friendly" than 
mailing lists. And i think probably people are more comfortable with MB 
than ML, so maybe we could get more interrested people to get involved 
by allowing suggestions there as well?




More information about the whatwg mailing list