I have a mac 10.13.4, and am using python 3.4.4 .
Here is my code:
####################
The button command functions perfectly, but the button itself does not show that it is being clicked on when I run the program. However, I accidentally discovered that if I click off the screen an back on, then the button shows when it is being clicked. I'd like to fix my program so that it acts this way all of the time. Any help would be greatly appreciated.
Here is my code:
####################
from tkinter import * root = Tk() canvas = Canvas(root, height = 1000, width = 1000) canvas.pack() def button_function(): print("hello") button = Button(root, text="button", font = ("Helvetica", 25), command=button_function, height = 4, width = 25) button.place(x = 63, y = 800)####################
The button command functions perfectly, but the button itself does not show that it is being clicked on when I run the program. However, I accidentally discovered that if I click off the screen an back on, then the button shows when it is being clicked. I'd like to fix my program so that it acts this way all of the time. Any help would be greatly appreciated.