我正在尝试制作一个脚本,它将在pythongui中的图像上绘制线条。我已经能够在GUI上获得图像,但是不知道如何绘制额外的线条。脚本应该能够循环,这样我可以画更多的线。在
到目前为止我所拥有的:
import tkinter as Tk
root = Tk.Tk()
background_image=Tk.PhotoImage(file="map.png")
background_label = Tk.Label(root, image=background_image)
background_label.place(x=0, y=0, relwidth=1, relheight=1)
root.wm_geometry("794x370")
root.title('Map')
root.mainloop()
您可以先将图像放在画布上:
相关问题 更多 >
编程相关推荐