In this video we’ll learn how to use the built in Icons for TTKBootstrap, Tkinter, and Python.
TTKBootstrap has 4-5 built in icons that you can use:
warning, icon, error, question, and info
In this video I’ll show you how to use them very easily!
Python Code: icony.py
(Github Code)
from tkinter import *
import ttkbootstrap as tb
from ttkbootstrap.icons import Icon
root = tb.Window(themename="superhero")
#root = Tk()
root.title("TTK Bootstrap! Icons!")
root.iconbitmap('images/codemy.ico')
root.geometry('500x350')
# Icons: warning, icon, error, question, info
img = PhotoImage(data=Icon.info)
# Label
my_label = tb.Label(image=img)
my_label.pack(pady=40)
root.mainloop()

Add comment