📜  如何在 tkinter python 代码示例中创建标签

📅  最后修改于: 2022-03-11 14:45:18.307000             🧑  作者: Mango

代码示例1
from tkinter import *  # Importing the tkinter module
root = Tk()  # Creating a window
label = Label(root, text="Your Text")  # Creating a label
label.pack()  # Putting the label on the window
label.mainloop()  # Opening the window