ttk Entry widget ignores font applied via style?
问题 from tkinter import Tk from tkinter.ttk import Style, Entry import tkinter.font as tkfont root = Tk() font = tkfont.Font(family='Helvetica', size=30, slant='italic') style = Style() style.configure('Custom.TEntry', font=font, foreground='green') entry_font = Entry(root, font=font, foreground='green') entry_font.insert(0, 'directly configured') entry_font.pack() entry_style = Entry(root, style='Custom.TEntry') entry_style.insert(0, 'styled entry') entry_style.pack() root.mainloop() The first