In an MXML component, one that does not contain the mx:Application tag,
you cannot define a type selector, only a class selector.
Stephen
-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Abdul Qabiz
Sent: Thursday, May 19, 2005 2:06 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] using the Style control tag
Hi,
You can use style tag as shown below, not sure why you got errors. Which
version of Flex you are using?
You can see into flex docs under section Using Styles and Fonts:
http://livedocs.macromedia.com/flex/15/flex_docs_en/0532.htm
##StyleTagExample.mxml##
mx:Application width=800 height=600
xmlns:mx=http://www.macromedia.com/2003/mxml;
mx:Style
LinkBar {
color:#00;
border-style:solid;
background-color:#FF;
textRollOverColor:#FF;
}
.myStyle {
color:#FF;
font-family:Georgia;
}
/mx:Style
mx:LinkBar
click=getURL('http://www.macromedia.com/' +
String(event.label).toLowerCase(), '_blank');
mx:dataProvider
mx:Array
mx:StringFlash/mx:String
mx:StringDirector/mx:String
mx:StringDreamweaver/mx:String
mx:StringColdFusion/mx:String
/mx:Array
/mx:dataProvider
/mx:LinkBar
mx:Button label=aButton styleName=myStyle / /mx:Application
Hope that helps..
-abdul
-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of cnewroth55
Sent: Thursday, May 19, 2005 11:20 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] using the Style control tag
not sure if anyone else knows this, but I tried to use the mx:Style
tag to set a style in one of my components, and when I did i got an
error that said CSS type selectors are not supported in components,
here is what I had:
mx:Style
LinkBar {some style stuf
}
/mx:Style
however this is wrong and the error message was kind of misleading,
based on it i thought that i could NOT use the tag/style in a component;
but when I changed it to this; mx:Style myLinkBar.LinkBar {some style
stuff } /mx:Style noticed i added a ID to the LinkBar style it worked
just fine...just thought someone might what to know...
Craig
Yahoo! Groups Links
Yahoo! Groups Links
Yahoo! Groups Links
* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/
* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/