|
@@ -0,0 +1,19 @@
|
|
|
+<!DOCTYPE html>
|
|
|
+<html>
|
|
|
+ <head>
|
|
|
+ <meta charset="utf-8">
|
|
|
+ <title></title>
|
|
|
+ </head>
|
|
|
+ <body>
|
|
|
+ <canvas width="1024px" height="256px" id="canvas" style="background-color: antiquewhite;"></canvas>
|
|
|
+ </body>
|
|
|
+</html>
|
|
|
+<script>
|
|
|
+ let canvasObj = document.getElementById('canvas');
|
|
|
+ let context = canvasObj.getContext('2d');
|
|
|
+ context.fillStyle = 'rgba(255,0,0,0.9)';
|
|
|
+ context.font = 'bold 240px 微软雅黑';
|
|
|
+ context.textAlign = 'left';
|
|
|
+ context.textBaseline = 'bottom';
|
|
|
+ context.fillText('我是一个立', 12, 250, 1000);
|
|
|
+</script>
|