Icon at the top of a window

Asked

Viewed 1,793 times

-2

I need to change the icon in the left corner of a window I created, the code I have as an example is the following, but it doesn’t work:

objeto.tk.call("icone.ico");

How can I do?

1 answer

1

You must use the method iconbitmap

import Tkinter

window = Tkinter.Tk()
window.iconbitmap('CAMINHO_COMPLETO_PARA_O_ICON/ICON.ICO')
window.mainloop()

Reference

Browser other questions tagged

You are not signed in. Login or sign up in order to post.