Flex 文字描边效果

在:字体

 

<mx:WindowedApplication spa

xmlns:mx="http://www.adobe.com/2006/mxml" orm

xmlns:filters="flash.filters.*"xml

 

...............ip

>ci

 

中加入上面红色语句,而后在Text或者Label中,例如:flash

 

<mx:Text id="bulletin" text="阿古柏" width="100%" textAlign="center" x="0" y="0" fontSize="20" verticalCenter="0"  mouseDown="show(event);">it

<mx:filters>io

<filters:GlowFilter color="0xFFFFFF"  strength="50"/>event

</mx:filters>

</mx:Text>

 

加入红色字段,就出现了字体描边效果,这里显示字体的白色描边背景效果

 

 

----------------------------------------------------------------------------------------------

 

还有,在Flex中加入一些效果必定要在mx:WindowedApplication 下,例如:

<mx:Style>

Alert {

   titleStyleName: "alertTitle";

   messageStyleName: "alertMessage";

   buttonStyleName: "alertButton";

   dropShadowEnabled: true;

   shadowDistance: 5;

   shadowDirection: right;

   cornerRadius: 5;

   background-color: #E9FFEA;

}

.alertTitle {

   letterSpacing: 0;

   fontSize: 16;

   color: red;

}

.alertMessage {

   letterSpacing: 0;

   fontSize: 16;

   fontWeight: normal;

   color: black;

}

.alertButton {

   letterSpacing: 0;

   fontSize: 16;

   cornerRadius: 10;

   fontWeight: normal;

}

 

         txtArea {

             backgroundAlpha: 1;

             borderStyle:none;

             backgroundColor: #ff0000;

             verticalScrollPolicy:off; 

            

         }

         

         ToolTip {

            fontSize: 14;

            fontWeight: normal;

            backgroundColor: #22DD00;

            dropShadowEnabled: true;

        }

        

        .body { 

       font-size: 12px; 

       font-family: Arial, Helvetica, sans-serif;

filter: style=1,startY=0,finishY=100,startX=100,finishX=100;

background-color: #666666;

}

        

     </mx:Style>

 

不然,若是加载到了其余界面(非mx:WindowedApplication ),就不能显示此效果,难道是Flex 3的一个bug??