为了账号安全,请及时绑定邮箱和手机立即绑定
function canvas1(){
    var canvas1 = document.getElementById("canvas1");
    canvas1.width = 500;
    canvas1.height = 500;
    var context1 = canvas1.getContext('2d');
    context1.moveTo(50,50);
    context1.lineTo(50,450);
    context1.lineTo(450,450);
    context1.lineTo(450,50);
    context1.lineTo(50,50);
    context1.moveTo(50,50);
    context1.lineTo(450,450);
    context1.moveTo(450,50);
    context1.lineTo(50,450);
    context1.lineWidth = 5;  //线条的宽度
    context1.strokeStyle = '#660000'; //线条的颜色
    context1.stroke();    
    }

正在回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信