如何使用 tkinter 更新 python 中的 canvas?

How to update the canvas in python using tkinter?

我需要更新我的 canvas 但是 tkinter.update() 说 tkinter 没有属性 "update"。可能的解决方案是什么。提前致谢。

您需要在 canvas 对象上调用 update 而不是 tkinter,即 canvas.update().