LMS知識社群歷程檔案Login
Position: 吳驊軒 > GBook > py
import tkinter as tk
win=tk.Tk()
win.geometry('300x200+80+50')
win.title('Label 標籤')
win.resizable(True,False)
win.maxsize(500,200)
win.minsize(100,200)
win.configure(bg='yellow'
lb=tk.Label(text='test',bg='lightblue',cursor='cross')
lb.pack()
lb.pack(side='bottom',pady=10)
bt=tk.Button(text='hello bt')
bt.pack()
tk.Label(win,text='Label 標籤',fg='blue',bg='lightblue',\
    compound='left').pack
msg=('誇三小')
tk.Label(win,text=msg,width=28,wraplength=240,\
    pady=10).pack()
btok=tk.Button(win, text='確定',command=btok)
btok.pack()    
win.mainloop()
def btok():
    print('e04')
    


Reply