Monday, July 6, 2015

What the use of Canvas Element in HTML5


The canvas element is used to draw graphics images on a web page by using javascript like below
<canvas id="pcdsCanvas" width="500" height="400"></canvas> <script type="text/javascript">
var pcdsCanvas=document.getElementById("pcdsCanvas");
var pcdsText=pcdsCanvas.getContext("2d");
pcdsText.fillStyle="#82345c";
pcdsText.fillRect(0,0,150,75);
</script>

3 comments:

  1. This is a great inspiring article.I am pretty much pleased with your good work.You put really very helpful information. Keep it up. Keep blogging. Looking to reading your next post. landscape canvas prints

    ReplyDelete