takluyver / mobilechelonian

Turtles on a notebook
Other
100 stars 37 forks source link

New version for this extension #22

Closed kandjiabdou closed 3 years ago

kandjiabdou commented 3 years ago

Hi guys,

I forked your repository for the purpose of an internship to correct some errors and personalize it for teaching at the IUT de villetaneuse. So I created a new extension from yours (here is the link). That extension was made as part of a 3-month internship at the iut of villetaneuse under the supervision of M. Lacroix. I did a complete rewrite of some files and organized in a clean way.

Test it on binder Binder

So I observed a strange effect when the turtle near the edge of the drawing area and bugs on the turtle speed display, sometimes the lines are not drawn and other issues.

Here are some bugs fixed

# This code does not draw a perfect square due to limitations
from mobilechelonian import Turtle
t = Turtle()
t.speed(5)
for i in range(4):
    t.right(90)
    t.forward(300)

image1

# This code does not draw the line
# because the speed is greater than the added variation
t = Turtle()
t.speed(5)
for i in range(10):
    t.forward(5)
t.penup()
t.forward(100)

image2

Greetings Abdou KANDJI

takluyver commented 3 years ago

Thanks! Do you think it's practical to try merging your changes into this repository, or do you prefer to maintain it separately?

kandjiabdou commented 3 years ago

Thanks! Do you think it's practical to try merging your changes into this repository, or do you prefer to maintain it separately?

Yes if you wish we can merge it, no problem.