On 3 February 2010 20:14, Boris Zbarsky <bzbar...@mit.edu> wrote:
> Yep.  canvas.width = canvas.getBoundingClientRect().width;

Ah yes that works nicely, with one minor caveat: it seems to include
the width of the border if there is one, so you have to take that into
account. You're right, this is a better solution.

Cheers.

Reply via email to