ttkbootstrap got an unexpected keyword argument 'themes_file' , why?

141 Views Asked by At

I always used this as part of my tkinter app without any issues:

# STYLE settings
themefile = os.path.dirname(sys.argv[0])
s = Style(theme="finaltb", themes_file=f"{themefile}\\tbtheme.json")

s.configure("TEntry", relief="flat", borderwidth=1)
s.configure("TCombobox", relief="flat", borderwidth=1)

app = s.master
app.title("bla")
width = app.winfo_screenwidth()
height = app.winfo_screenheight()
app.geometry("1000x850")
app.minsize(1000, 850)
app.iconbitmap("logo5.ico")

After letting my program untouched for around 6 month now I get this error message when I try to run it:

Traceback (most recent call last):

File "....GUI.py", line 76, in <module>
s = Style(theme="finaltb", themes_file=f"{themefile}\\tbtheme.json")        

TypeError: Style.__new__() got an unexpected keyword argument 'themes_file'
0

There are 0 best solutions below