Change the Color of the Switch in the app designer?

40 visualizaciones (últimos 30 días)
Jay Vaidya
Jay Vaidya el 8 de Jun. de 2021
Comentada: Maruan Alberto Bracci el 18 de En. de 2023
I am using app designer and I would like to change the color of the switches. Available switch options were 'Rocker Switch', 'Toggle Switch' and 'Switch' but neither of them has a .Color attribute.
I know I can use a lamp instead to display the status of the switch but I would like to change the color of the switch if possible.
Or I would like to have 'On' or 'Off' but only one of the two visible when the switch is in either of the states.
Thanks in advance!

Respuesta aceptada

Timor
Timor el 8 de Jul. de 2021
I added a lamp on top of the switch at the "on" position that is visible only when switch value is "on". works nice.
  2 comentarios
Liam Vanderschaaf
Liam Vanderschaaf el 7 de En. de 2022
Love this idea, but how did you do it? Whenever I try to drag a lamp onto the switch, the switch gets replaced.
Maruan Alberto Bracci
Maruan Alberto Bracci el 18 de En. de 2023
Then you can't click the lamp to turn off the switch, but you have to click in the gray area. Does it have the same behavior for you too?

Iniciar sesión para comentar.

Más respuestas (1)

Reshma Nerella
Reshma Nerella el 11 de Jun. de 2021
Hi,
Currently we do not support Color property for Switch components. I have brought this issue to the notice of the concerned people and it might be considered for a future release.
  2 comentarios
Ruben Kopischke
Ruben Kopischke el 15 de Feb. de 2022
I'd love this as well
Jiri Hajek
Jiri Hajek el 11 de Mayo de 2022
This would be much appreciated...

Iniciar sesión para comentar.

Categorías

Más información sobre Develop Apps Using App Designer en Help Center y File Exchange.

Productos


Versión

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by