开发者

is it possiable apply stylename to <s:span > in flex4?

开发者 https://www.devze.com 2023-02-15 14:20 出处:网络
I have RichEditableText component , In this component I have created h开发者_如何学运维yper link label based on condition ,but no need inline style(color font-family) . I want to apply style name(CSS)

I have RichEditableText component , In this component I have created h开发者_如何学运维yper link label based on condition ,but no need inline style(color font-family) . I want to apply style name(CSS) . is it possible can apply style name for hyper link? Give some idea

<s:RichEditableText  editable="false" selectable="false"  mouseEnabled="{user.isSubscribed}" mouseChildren="{user.isSubscribed}">
    <s:content>
          <s:a click="linkelement1_clickHandler(event)" >
        <s:span styleName="bodyLinkContent10" >{user.isSubscribed ? "Contact Participant" : "Unavailable"}</s:span></s:a>
    </s:content>

    </s:RichEditableText>

style Name Does not apply ? Could you tell me reason for that ?

I tried

<s:RichEditableText  editable="false" selectable="false" styleName="{user.isSubscribed ? 'bodyLinkContent10':'bodyContentGrey10'" mouseEnabled="{user.isSubscribed}" mouseChildren="{user.isSubscribed}">
                        <s:content>
                            <s:a click="linkelement1_clickHandler(event)" fontSize="10"><s:span textDecoration="none" color="{user.isSubscribed ? 0x003399 : 0x666666}">{user.isSubscribed ? "Contact Participant" : "Unavailable"}</s:span></s:a>
                        </s:content>
                    </s:RichEditableText>

It is working fine But requirement is apply the CSS only.So any way for apply ?

0

精彩评论

暂无评论...
验证码 换一张
取 消