+1

# I am confused in x,y cordinates of drawing Canvas

I have checked some courses on YouTube but they all explain the way which they got me confused Please here is anyone who can explain it clearly

3/22/2020 9:52:52 AM

Abdulaziz Abdurasul

+3

HonFu let me check it out i will thank you later 😁❤

+2

Have you tried any written explanations yet? https://www.w3schools.com/html/html5_canvas.asp

+1

Hm. 🤔

+1

It is explained in our HTML course here though. Do you remember that part? https://www.sololearn.com/learn/HTML/2201/

+1

X depends on "left" or "right" Y depends on "top" or "bottom" (0, 0) means an element is at x0(left) and y0(top)

0

@HonFu there is no any explanation ((((((((( Even for MDN IS NOT GOOD ABOUT CORDONATE

0

HonFu const canvas = document.getElementById('canvas'); var me = canvas.getContext('2d'); me.beginPath(); me.moveTo(50, 50); // Its similar to margin to left and top me.lineTo(300, 100); // explain this values I got that x=300 , y=100 but how all this works I am confused. me.stroke();