How to chance alpha of static text?

7 vues (au cours des 30 derniers jours)
Jesse Abruzzo
Jesse Abruzzo le 20 Mar 2016
Hi everybody, i am trying to change the alpha of a static text object. I want to create a fading effect in the beginning of my GUI. Any help would be appercaited. I tried:
for i = 1:.1:0
pause(.5);
set(handles.IntroText, 'Aplhadata', i);
end
Not really sure how to set the alpha of a static text.

Réponse acceptée

Vlad Miloserdov
Vlad Miloserdov le 20 Mar 2016
If I understand your question correctly, you can do next
for i = 0:.1:0.9
pause(.5);
set(handles.text1,'ForegroundColor',[i i i])
end
  1 commentaire
Jesse Abruzzo
Jesse Abruzzo le 20 Mar 2016
Yup that was exactly what i needed. Thank You for Your help I apprecaite it.

Connectez-vous pour commenter.

Plus de réponses (1)

tan kei guan
tan kei guan le 20 Avr 2018
is it i need to delete the pause line if i wan to set a fix transparency ?

Catégories

En savoir plus sur Entering Commands dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by