我正在尝试使 tkcalendar 与我的窗口融为一体。
import tkinter
from tkcalendar import Calendar
window = tkinter.Tk()
window.configure(background = "black")
cal = Calendar(window, background = "black" , disabledbackground = "black" , borderbackground = "black" , headersbackground = "black" , normalbackground = "black" )
cal.config(background = "black")
cal.pack()
window.mainloop()
我已经阅读了 tkcalendar 文档并尝试通过调用小部件类的 configure 方法来更改所有样式元素:
cal.configure(background = "black")
; 但是,我的日历仍然保持灰色,而不是融入黑色窗口背景。是否可以更改日历的实际背景颜色?