Skip to main content
July 28, 2009
Question

Controling linkActive color on TextFlow

  • July 28, 2009
  • 2 replies
  • 1685 views

So, what if I wanted to tell a link when to use it's Active color, hover color, and normal color. Is there anyway I can tell the textflow or the link to switch colors?

The situation I'm in is that I have a button that functions as a link and text next to the button that is also a link. I want the link text to use it's active color when the button is selected and it's normal color when the button isn't selected.

Any help would be great.

This topic has been closed for replies.

2 replies

July 28, 2009

So, I had all the link elements from the textflow stored in an array. I tried to pull out the one that corresponded to the button that was clicked and I tried to update it's linkNormal Color right there but it didn't work. Nothing happened.

Any other ideas?

Participating Frequently
July 28, 2009

Are you using TLF by itself? Did you call updateAllContainers() after changing linkNormal? TLF doesn't have an automatic revalidation model like Flex has, so after you change the model you have to tell the view to redraw.

Gordon Smith

Adobe Flex SDK Team

daslicht
Known Participant
May 10, 2011
Participating Frequently
July 28, 2009

When the button is selected, couldn't you set the link's normal color to its active color?

Gordon Smith

Adobe Flex SDK Team

July 28, 2009

That sounds like it would work.

I'll try it and let you know.