Working with phoneGap implementing drawing with Canvas. The catch we\'ve run into is that canvas expects specific pixel dimensions. This is fine except that the iPhone 4\'s
EDIT: Just noticed I posted the wrong link for the demo!
Retina (or other hdpi display) canvas resolution is definitely possible. There is a working example here:
http://spencer-evans.com/share/github/canvas-resizer/
I've also bumped into this a few times. The accepted answer code is essentially correct, but you could also use a library solution. I whipped one up to handle intelligent canvas re-sizing to make the element more responsive and higher resolution (as shown in the demo).
https://github.com/swevans/canvas-resizer