[Python-Dev] xturtle.py - a replacement for turtle.py
glingl at aon.at
Wed Jun 28 13:42:39 CEST 2006
xturtle.py, extended turtle graphics
is a new Tkinter based turtle graphics module for Python
xturtle.py (Version 0.91) can be found at:
(Request ID 1513695, and 1513699 for the docs)
together with a set of example scripts and a demoViewer
xturtle was first announced at edu-sig and is reported to
work properly on all major platforms (Mac, Linux and
Windows) I propose to use it as a replacement for turtle.py
It was suggested to me to discuss it on this list. So I'll try that.
For now I'll give only two introductory statements and then wait for a response, hoping that a fruitful
discussion will evolve.
(I) xturtle.py is a reimplementation of turtle.py, retaining its merits and is backward compatible to turtle.py. Enhancements over turtle.py are:
# Better animation of the turtle movements, especially of turning the
turtle. So the turtles can more easily be used as a visual feedback
instrument by the (beginning) programmer.
# Different turtle shapes, gif-images as turtle shapes, user defined and
user controllable turtle shapes, among them compound (multicolored) shapes.
# Fine control over turtle movement and screen updates via |delay()|,
and enhanced |tracer()| and |speed()|, |update()| methods.
# Aliases for the most commonly used commands, like |fd| for |forward|
etc., following the early Logo traditions. This reduces the boring work
of typing long sequences of commands, which often occur in a natural way
when kids try to program fancy pictures on their first encounter with
turtle graphcis (still not knowing loops).
# Some simple commands/methods for creating event driven programs
(mouse-, key-, timer-events). Especially useful for programming simple
# A scrollable Canvas class. The scrollable Canvas can be extended
interactively as needed while playing around with the turtle(s) (e. g.
to follow some escaped turtle). # Commands for controlling background
color or background image.
(II) Motives: My goal was to provide utmost easy access to a
sufficiently rich graphics toolkit. I consider this of crucial
importance for students and teachers who, e. g., have to decide which
language to use for introductory programming courses. Moreover I
consider turtle graphics as an excellent tool to visualize programming
concept. So I already used the current turtle.py as a central tool in
the first edition of my book "Python für Kids", despite of its apparent
Now I propose an alternative: xturtle.py. You will best understand my
intentions by having a look at the 25+ demo scripts using the
accompanying demoViewer, which are provided with turtle.zip at the above
mentioned website. (I do not propose to include these into the standard
distribution. Perhaps they could go into some special edudistro as Kirby
Urner suggested lately)
I would appreciate it very much if xturtle.py could go into Python2.5.
I'm ready to do the amendments, which may emerge as necessary from the
More information about the Python-Dev