Change backround colour of pushbutton to black in GUI
Mostrar comentarios más antiguos
Hi!
I have created a GUI with a piano in matlab. My problem is I want the colour of the pushbuttons at top to be black to make it look more like a Piano, but I'm only able to change the frame colour not the backround colour.
Respuestas (3)
matt dash
el 10 de Nov. de 2014
0 votos
Instead of setting the BackgroundColor property, you can use the CData property to superimpose an image onto your button. (This at least worked on Macs several years ago, i haven't tried it recently) If you can draw the button you want, e.g. in photoshop, you can then import it to use on your button.
As a test, try setting the CData property to zeros(m,n,3) where m and n are the width and height of your button in pixels.
1 comentario
Gry
el 11 de Nov. de 2014
Gry
el 12 de Nov. de 2014
0 votos
Categorías
Más información sobre Just for fun en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!