Skip to main content
Inspiring
Mar 8, 2009 12:27 AM UTC
Answered

rollOver effect on a link element

Sorry to be a dim bulb. I've looked at doc and examples, out there by can't seem to get a rollOver effect to happen on a link element. I have tried this
var myText:String =
"<TextFlow xmlns=' http://ns.adobe.com/textLayout/2008' fontFamily='Arial' fontSize='12' textIndent='15' marginBottom='15' paddingTop='4' paddingLeft='4'>" +
"<CharacterFormat id='hoverOverLink' color='0xff0000'/>" +
"<p><span>Here is a test of a </span>" +
"<a id='word_id' href='WORD' linkHoverFormat='hoverOverLink'><span fontStyle='italic'>word</span></a>" +
"</p></TextFlow>";

Also I'm wondering what is the best way to get the quality smooth anti-aliased text that you get when you use static text in the Flash authoring tool.

Thanks very much in advance for help with this.
This topic is closed to new replies. Start a new post to keep the conversation going.
rdermerCorrect answer
Inspiring
Mar 8, 2009 7:39 PM UTC
In the posted TextLayoutComponent for CS4 I believe you'd need {}s around hoverOverLink like this linkHoverFormat='{hoverOverLink}'

This changed quite a bit in TLF build 370. In that build the markup would be:
<TextFlow fontSize="12" verticalAlign="inherit" paddingBottom="inherit" paddingLeft="4" textIndent="15" paddingRight="inherit" fontFamily="Arial" paddingTop="4" lineBreak="inherit" marginBottom="15" whiteSpaceCollapse="preserve" xmlns=" http://ns.adobe.com/textLayout/2008"><p><span>Here is a test of a </span><a id="word_id" href="WORD"><linkHoverFormat color="0xff0000"/><span fontStyle="italic">word</span></a></p></TextFlow>

Richard

3 replies

Inspiring
Mar 9, 2009 4:55 PM UTC
If the field is editable press the ctrl key while hovering.
Translate
SPGAnneAuthor
Inspiring
Mar 8, 2009 8:10 PM UTC
Richard - thanks...tried what you suggested, when I move my mouse over the link I still don't get a color change.
Translate
rdermerCorrect answer
Inspiring
Mar 8, 2009 7:39 PM UTC
In the posted TextLayoutComponent for CS4 I believe you'd need {}s around hoverOverLink like this linkHoverFormat='{hoverOverLink}'

This changed quite a bit in TLF build 370. In that build the markup would be:
<TextFlow fontSize="12" verticalAlign="inherit" paddingBottom="inherit" paddingLeft="4" textIndent="15" paddingRight="inherit" fontFamily="Arial" paddingTop="4" lineBreak="inherit" marginBottom="15" whiteSpaceCollapse="preserve" xmlns=" http://ns.adobe.com/textLayout/2008"><p><span>Here is a test of a </span><a id="word_id" href="WORD"><linkHoverFormat color="0xff0000"/><span fontStyle="italic">word</span></a></p></TextFlow>

Richard
Translate