📅  最后修改于: 2022-03-11 14:46:43.041000             🧑  作者: Mango
import tkinter as tk
root = tk.Tk()
root.tk.call('wm', 'iconphoto', root._w, tk.PhotoImage(file='/path/to/ico/icon.png')
root.mainloop()