I want to remove the blue border of button when a user clicks on it. There is no blue border when i use the normal tkinter button, i'm using tkmacosx button through which i can change its background color but it has a blue border around it.
This is the code.
import tkinter as tk
import tkmacosx as tkm
root = tk.Tk()
b1 = tk.Button(root, text='Submit')
b1.pack()
b2 = tkm.Button(root, text='Submit', bg='#ADEFD1', borderless=1)
b2.pack()
root.mainloop()
Photo 1: I want the button to look like this even after the user clicks on it without any border.
Photo 2: I get this after the user clicks on it.
How can i remove or hide the blue border?
Please help thank you
From @Saad answer I have solved my issue and completely removed the focus button border. Just configure takefocus
as 0.
import tkinter as tk
import tkmacosx as tkm
root = tk.Tk()
tkm.Button(root, text='Submit', bg='#ADEFD1', borderless=1, takefocus=0).pack()
root.mainloop()