views:

624

answers:

1

I'm trying to create a simple text with a drop shadow in ActionScript 3.0; for example:

_tf = new TextField();
_tf.autoSize = TextFieldAutoSize.CENTER;
_tf.selectable = false;
var format:TextFormat = new TextFormat();
format.font = "Arial";
format.bold = true;
format.color = 0xffffff;
format.size = 12;
_tf.text = "Drop shadow";
_tf.defaultTextFormat = format;
addChild(_tf);

How can i get this text with a drop shadow??

+3  A: 
_tf.filters = [new DropShadowFilter()];
Amarghosh
And how can i give the parameters to adjust the shadow?
fidoboy
Look up the constructor arguments to DropShadowFilter() here: http://help.adobe.com/en_US/AS3LCR/Flash_10.0/flash/filters/DropShadowFilter.html#DropShadowFilter%28%29
Cameron