=== Quote from MM docs:
Usage
new TextFormat([font:String, [size:Number, [color:Number, [bold:Boolean,
[italic:Boolean, [underline:Boolean, [url:String, [target:String,
[align:String, [leftMargin:Number, [rightMargin:Number, [indent:Number,
[leading:Number]]]]]]]]]]]]]) : TextFormat
===

You should either use parameters passed (in order exactly as above) to
constructor:
   var tf:TextFormat = new TextFormat("Arial", 24);
   
OR use no params with constructor and set properties later:
   var tf:TextFormat = new TextFormat();
   tf.underline = true;
   tf.color = 0xFFFFFF;

The 2nd way usually is better :-)

-- 
Best regards,
 GregoryN                        
================================
http://GOusable.com
Flash components development.
Usability services.

>________ "Mendelsohn, Michael" wrote:
> 
> Hi list...
> 
> I thought you could instantiate a TextFormat object like this:
> 
> var tf:TextFormat = new TextFormat(underline:true, color:0xFFFFFF);
> 
> But that doesn't work as there's a compile error.  Why?


_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to