How to set border color of certain Tkinter widgets?

前端 未结 2 1756
甜味超标
甜味超标 2020-12-29 03:23

I\'m trying to change the background color of my Tkinter app, but for certain widgets it leaves a white border around the edges.

For example, this:

f         


        
2条回答
  •  没有蜡笔的小新
    2020-12-29 04:15

    Just use

    widget.config(highlightbackground=COLOR)
    

    Furthermore, if you don't want that border at all, set the highlightthickness attribute to 0 (zero).

提交回复
热议问题