Reputation: 7514
I'd like to be able to change the style options of one of the default ttk styles (clam).
Whats the best way to make this menubutton match the default white of the entries around it?
Upvotes: 1
Views: 825
Reputation: 10532
The thing that makes them look different is mostly the background, so i assume you want to make the background white?
You can change the background using:
s = ttk.Style()
s.theme_use('clam')
s.configure('TMenubutton', background='white')
However, the background then changes back to normal when you hover you mouse over it (when it's active). To make the background white all the time use:
s.map('TMenubutton', background=[('active','white')])
Upvotes: 3