Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- plotno=document.querySelector('canvas')
- wartosc=plotno.getContext('2d')
- wartosc.fillStyle = "red"
- wartosc.fillRect(100, 50, 50, 120)
- wartosc.fillRect(151,70,50,100)
- wartosc.fillRect(202,30,50,140)
- wartosc.fillRect(253,90,50,80)
- wartosc.fillRect(304,70,50,100)
- wartosc.beginPath();
- wartosc.moveTo(100, 30);
- wartosc.lineTo(100, 170);
- wartosc.lineTo(400, 170);
- wartosc.stroke();
- wartosc.font = "italic bold 20px Arial";
- wartosc.fillText("ilość", 40, 170)
- wartosc.fillText("czas", 100, 190)
- wartosc.beginPath();
- wartosc.moveTo(90, 40);
- wartosc.lineTo(100, 30);
- wartosc.lineTo(110, 40);
- wartosc.stroke();
- wartosc.beginPath();
- wartosc.moveTo(390, 160);
- wartosc.lineTo(400, 170);
- wartosc.lineTo(390, 180);
- wartosc.stroke();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement