Mar-22-2023, 04:20 PM
(This post was last modified: Mar-22-2023, 04:21 PM by deanhystad.)
The font used for printing to the console was set by your shell. It is not the font used by tk.
import tkinter as tk root = tk.Tk() label = tk.Label(root) entry = tk.Entry(root) print("Label font", label["font"]) print("Entry font", label["font"])
Output:Label font TkDefaultFont
Entry font TkTextFont
My guess is neither TkDefaultFont nor TkTextFont contain the characters you need. Look for fonts on your computer and find a font that does. Then set that as the font for your text widgets.import tkinter as tk root = tk.Tk() label = tk.Label(root, font=("Times",)) entry = tk.Entry(root, font=("Helvetica",)) print("Label font", label["font"]) print("Entry font", entry["font"])
Output:Label font Times
Entry font Helvetica