Title: Message
Yes, this should work.
 
The MXML compiler simply converts a CSS file into an ActionScript method of the autogenerated MyApplication class which creates stylesheets hanging off of StyleManager.styles. All of these stylesheets are accessible at runtime.
 
- Gordon
-----Original Message-----
From: Matthew Shirey [mailto:[EMAIL PROTECTED]
Sent: Thursday, April 07, 2005 12:31 PM
To: [email protected]
Subject: Re: [flexcoders] Dynamically Changing an entire CSS

Okay, I am starting to see how this could work.  Is there a way to change a css class definition tho?  Using your example would that be like:
 
StyleManager.styles.myClass.setStyle("fontSize", 14);
 
I am just guessing here.  I have a long series of defined css classes that I would have to modify.  If there is a way to modify these then this might indeed be easier than my own solution.
 
-- Matthew
 
On Apr 7, 2005 12:16 PM, Gordon Smith <[EMAIL PROTECTED]> wrote:
Sorry, I don't have any examples. I was just offering a theoretical solution. ; )
 
But you should be able to programmatically change a global style like this:
 
    StyleManager.styles.global.setStyle("fontSize", 14);
 
and a style for all instances of a particular component like this:
 
    StyleManager.styles.Button.setStyle("fontSize", 14);
 
- Gordon


Yahoo! Groups Links

Reply via email to