[英]How to add a background color to a Tkinter window?
I am a beginner here.我是这里的初学者。 I want to know how to add a background color to a Tkinter main window apart from root.config(bg='black')
.我想知道如何将背景颜色添加到 Tkinter main window 除了root.config(bg='black')
。
You can use:您可以使用:
root['bg'] = 'color you want'
It works perfectly well.它工作得很好。 But I think the config method will be a better opinion.但我认为 config 方法会是一个更好的意见。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.