Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Create a text with drop shadow in AS3

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??

like image 853
fidoboy Avatar asked Oct 18 '09 04:10

fidoboy


1 Answers

_tf.filters = [new DropShadowFilter()];
like image 121
Amarghosh Avatar answered Sep 23 '22 02:09

Amarghosh