亚洲国产日韩欧美一区二区三区,精品亚洲国产成人av在线,国产99视频精品免视看7,99国产精品久久久久久久成人热,欧美日韩亚洲国产综合乱

???? ???? ????.

Context ??? fillText(string, x, y) ???? ???? ??? ? ?????. ?? ???? ? ?? ?? ??? ??? ??, x ?? ? ???? y ?????. ???? ?? ??? ???? ??, ??, ???? ???? ???(?? ????? CSS? ?? ??? ?????). ?? ???? ?? ? ??? ???? ? ???? ??????? ???? ????. ? ?? ?? ??: fillText ???? ??? ? ??? ???? ????. ?, ?? ???? ? ?? ?????. ??? ?? ?? ???? ????? fillText ???? ?? ?? ???? ???.

??? ??? ????:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>huatu</title>
<body>
<canvas id="demoCanvas" width="500" height="600"></canvas>
<script type="text/javascript">
    //通過id獲得當(dāng)前的Canvas對(duì)象
 var canvasDom = document.getElementById("demoCanvas");
    //通過Canvas Dom對(duì)象獲取Context的對(duì)象
 var context = canvasDom.getContext("2d");
    context.moveTo(200,200);
    // 設(shè)置字體
 context.font = "Bold 50px Arial";
    // 設(shè)置對(duì)齊方式
 context.textAlign = "left";
    // 設(shè)置填充顏色
 context.fillStyle = "#005600";
    // 設(shè)置字體內(nèi)容,以及在畫布上的位置
 context.fillText("PHP中文網(wǎng)!", 10, 50);
    // 繪制空心字
 context.strokeText("ipnx.cn!", 10, 100);
</script>
</body>
</html>


???? ??
||
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>huatu</title> <body> <canvas id="demoCanvas" width="500" height="600"></canvas> <script type="text/javascript"> //通過id獲得當(dāng)前的Canvas對(duì)象 var canvasDom = document.getElementById("demoCanvas"); //通過Canvas Dom對(duì)象獲取Context的對(duì)象 var context = canvasDom.getContext("2d"); context.moveTo(200,200); // 設(shè)置字體 context.font = "Bold 50px Arial"; // 設(shè)置對(duì)齊方式 context.textAlign = "left"; // 設(shè)置填充顏色 context.fillStyle = "#005600"; // 設(shè)置字體內(nèi)容,以及在畫布上的位置 context.fillText("PHP中文網(wǎng)!", 10, 50); // 繪制空心字 context.strokeText("ipnx.cn!", 10, 100); </script> </body> </html>