How to change the colour of a selected menu item?


#1

Hello,

I’m trying to change the colour of the selected item in a menu (of a ComboBox) from the default blue to red. I tried many things like setting PopupMenu::highlightedBackgroundColourId to the desired colour, but nothing worked. How is this done correctly?

As I’m relatively new to JUCE, what is the correct way of finding such things out? I was searching in juce_ComboBox.cpp and juce_LookAndFeel.cpp but that didn’t help me much.

And maybe a bit more advanced question: How can I change the default colours to something else? Do I need to subclass LookAndFeel for this?

Thanks in advance for helping me with this,
Fritz