More than 1 LookAndFeel?

Hi all,

I’m writing a simple app that will allow the user to switch between different slider appearances. To do this, I have set up a combobox with values of “Default”, “Type1”, “Type2” etc…
I can get a new LookAndFeel working but how can I implement this so it will respond to the user’s choice. I’m using various image strips created in Knobman. I can see that the demo allows you to choose between 2 skins from the menu but I can’t get my head around how it works!

Thanks for any help…

[quote=“omen”]
I can get a new LookAndFeel working but how can I implement this so it will respond to the user’s choice.[/quote]
The comboBoxChanged() callback from ComboBox::Listener should work here.

Chris

Thanks Chris. Although I need to figure out how to associate more than one slider image to the drawRotarySlider () method. So for example I have the combobox with 10 options for the lookandfeel. When the user selects one it should show the relevant slider appearance. I can get it working switching between default and one other custom l+f. But how do I have more than one custom l+f without having multiple drawRotarySlider () methods?

Thanks…

Component::setLookAndFeel().

Ok think I got that much working. Is it possible though to change a rotary slider without changing the other widgets? When I use Component::setLookAndFeel() it changes all widgets on that component.

The slider is a component, so just do slider->setLookAndFeel()

Thanks Graeme for the simple solution!