Register Now

Login

Lost Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Which of the following methods must empty the list of subpaths so that the context once again has zero subpaths?

a) closePath()
b) beginPath()
c) moveTo(x, y)
d) endPath()

Answer: b
Explanation: ClosePath() creates a path that starts from current point up to the starting point. The beginPath() method begins a path, or resets the current path. MoveTo(x, y) moves the point specified in canvas but without creating the line. There is nothing like endPath() in canvas.

Join The Discussion