QML Switch UI : Color property
Unsolved
QML and Qt Quick
-
How can I change the color of the Switch UI in QML. How to I access the property ?
-
I'm not sure if you are talking about what I think but if you talk about the Switch from Qt quick controls here is an example :
Switch { id: sw style: SwitchStyle { groove: Rectangle { implicitWidth: 50 implicitHeight: 20 radius: 9 border.color: "black" border.width: 1 color: sw.checked ? "blue" : "white" } handle: Rectangle{ implicitWidth: sw.width/2 implicitHeight: 20 radius: 9 border.color: "black" border.width: 1 } } }
For more information : SwitchStyle