Draw on an image in Python and Django

Hello dear friends

I am creating a web application with django and python and I am stuck on the drawing part. How to use a compass, a ruler, a pencil to draw on a picture. For example on a mark, we draw on the mark to draw a straight line.
My question is, how to use a compass, pencil, python ruler through buttons.
Thank you

Briefly, you don’t.

What you are looking for is some JavaScript application to allow you to do that in the browser.