我正在尝试放置在 aLabelFrame
中显示的Label
aCanvas
但是我收到此错误:
TclError: can't use .28425672.27896648 in a window item in this canvas
这是我的代码:
from Tkinter import LabelFrame, Label, Tk, Canvas
root = Tk()
canvas = Canvas(root)
canvas.pack()
label_frame = LabelFrame(text="I'm a Label frame")
label = Label(label_frame,text="Hey I'm a Label")
canvas.create_window(10,20,window=label)
root.mainloop()