首页 > 代码库 > HTML新特性之一----canvas

HTML新特性之一----canvas

 <canvas id="me"></canvas>//申请一个canvas标签
    <script>
       
        var canvas = document.getElementById("me");//脚本控制
        var can = canvas.getContext("2d");
        can.fillStyle = "#FF000";
        can.fillRect(0, 0, 80, 1000);
        </script>

HTML新特性之一----canvas