I'm working on a script in python,tkinter that draws a triangle and moves it around the screen. unfortunately I can't get the arrow to move. I've tried using canvas.move() but that wants an x and a y not the set of 3 coordinates I have to make it a triangle. Is there something I'm missing or maybe an easier way to move it? and help would be appreciated.

5 Years
Discussion Span
Last Post by Thropian

Those are the coordinates you need to set for a traingle. Most graphical programs use an x,y coordinate system like so.
|(0,0) (1,0) (2,0)
|(0,1) (1,1) (2,1)
|(0,2) (1,2) (2,2)

A triangle can be described as 3 points or this may also suprise you but possibly 4 points. If we start our triangle at (0,0), next draw a line to (0,2), then a line to (2,2), to finish we draw a line back to (0,0).


thanks for the try predator but I have 3 (x,y) sets but the canvas.move() wants a move for the x axis and the y axis. I'm looking for a way to define the new location.

Edited by Thropian: I realized what .move() was doing


Well what direction do you want it to move and when? You should only have to specify an offset for your new location. For example (x+1),(y+0). Beyond that I believe we may have to take a look at your code to see what you are trying to achieve.


I'm trying to get the arrow to move and turn by user actions I'll see if I can get a small working section of the code for you guys


well I figured out what was wrong in my program. I was using

canvas.coords(tag,coordinates)#to move the object but I also needed
canvas.tag_raise(tag)#to make the object appear on top
Votes + Comments
glad you got it working :)
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.