2024-05-13 22:44:21 发布
网友
有没有一种简单的方法可以改变按钮中文本的颜色?
我使用button['text'] = 'input text here'来更改按钮文本在按下后的内容。对于颜色的变化,button['color'] = 'red'是否存在类似的现象?
button['text'] = 'input text here'
button['color'] = 'red'
使用foreground选项设置按钮中文本的颜色。 示例:
foreground
button.configure(foreground="red")
使用
foreground
选项设置按钮中文本的颜色。示例:
相关问题 更多 >
编程相关推荐