NISHIO Hirokazu[Translate]
canvasエレメントはwidthとstyle.widthを別個に持つ
>Note further that the height and width are the logical canvas dimensions used for drawing and are different from the style.height and style.width CSS attributes.
:
// Make a canvas that has a blurry pixelated zoom-in // with each canvas pixel drawn showing as roughly 2x2 on screen canvas.width = 400; canvas.height = 300; canvas.style.width = '800px'; canvas.style.height = '600px';

"Engineer's way of creating knowledge" the English version of my book is now available on [Engineer's way of creating knowledge]

(C)NISHIO Hirokazu / Converted from [Scrapbox] at [Edit]