<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" width="347" height="291" backgroundGradientColors="[#ffffff, #ffffff]">
	
	<!-- Farzad Qasim
	
	www.ilovenicii.com
	
	-->
	
		<mx:Style>
			Panel {
   borderColor: #33cccc;
   borderAlpha: 1;
   borderThicknessLeft: 10;
   borderThicknessTop: 5;
   borderThicknessBottom: 13;
   borderThicknessRight: 10;
   cornerRadius: 10;
   headerHeight: 26;
   highlightAlphas: 0.6, 0.16;
   backgroundColor: #66cccc;
   titleStyleName: "mypanelTitle";
}

.mypanelTitle {
   fontSize: 14;
}

Button {
   cornerRadius: 5;
   fillAlphas: 1, 1, 1, 1;
   fillColors: #ff3366, #ff99cc, #ff3366, #ff99cc;
   color: #000000;
   textRollOverColor: #333333;
   textSelectedColor: #000000;
   borderColor: #aab3b3;
   themeColor: #ff6666;
   fontWeight: bold;
}


ToolTip {
   backgroundColor: #ff3366;
}
		</mx:Style>
		
		
		
		
		<mx:Script>
		<![CDATA[

			
			
		public function texter():void
		{
			if(aa.text.length > 21)
			{

			aa.setStyle("fontSize",9);
			
			}
		}	
			
			
		]]>
	</mx:Script>

	
<mx:Panel x="14" y="4" width="318" height="281" layout="absolute">
	
	<mx:Label id="aa" x="10" y="10" text="My Length is very long" fontSize="12"/>
		<mx:Label x="10" y="38" text="My Length is very long" fontSize="12" width="132" truncateToFit="true"/>
	<mx:Button label="CHECK" click="texter();" x="164" y="10"/>
	
	</mx:Panel>
</mx:Application>
