Slider/value bubble look&feel

I have a problem when setting the look and feel for the popup bubble that can be displayed while the Slider is changing.

It's background colour, shape, font, outline can be set from the LookAndFeel class that's set to parentForPopupDisplay component. But the bubble placement and font colour are taken from the LookAndFeel assigned to the Slider. So i need to split part of the LookAndFeel into two parts one in the parent component of the Slider and one in the Slider itself.

Is it possible to make it consistent so that the source of theese properties is in one place ?

I was also trying to set: TooltipWindow::textColourId as it is used to set the text colour of the bubble, my slider is called "rotation"

rotation.setPopupDisplayEnabled (true, nullptr);
setColour (TooltipWindow::textColourId, Colours::red);

Will not show the bubble font RED


rotation.setPopupDisplayEnabled (true, this);
setColour (TooltipWindow::textColourId, Colours::red);

Will show the text RED. But this is too general for my component that can hold other components using this colourId, and assgning that colourId to the slider itself does nothing.

I thought about removing that colourId using removeColour() and let it fall back to LookAndFeel, but now i see i can't overload findColour() in the LookAndFeel class. I'm a bit stuck here.

My brain is too tired to think this through right now - if you can suggest a sensible change, I'll consider it, but not really sure what you're looking for there..

Change the line 1281 in juce_Slider.cpp to, so the TooltipWindow::textColourId gets taken from the Slider that owns the popup and not the component that the popup appears on (or desktop)

g.setColour (owner.findColour (TooltipWindow::textColourId, true));

Excellent suggestion - will change that, thanks!