Combo box text color problem

I’m trying to set the color of the label text for a ComboBox, and the color change isn’t working. In my code I call:

myComboBox->setColour(ComboBox::textColourID, Colours::white);

but the menu item that has been selected is consistantly black.

I don’t see where the ComboBox sets its text color on the Label member. Could that be the problem? I see that’s what’s done in lookAndFeelChanged()

Yeah, I think I need to add a check to keep that updated when you change the colour. Adding this method should do it:

void ComboBox::colourChanged() { lookAndFeelChanged(); }

1 Like

thanks! That worked like a dream