Scale an Image with Embed setting
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
<mx:Script>
[Embed(source="logo.png", scaleGridTop="5", scaleGridBottom="10", scaleGridLeft="5", scaleGridRight="10")]
[Bindable]
public var imgCls:Class;
</mx:Script>
<mx:Label text="Original Image" />
<mx:Image source="@Embed('logo.png')" />
<mx:Spacer height="10" />
<mx:Label text="Scale9-Scaled Image" />
<mx:Image source="{imgCls}" width="100" height="100"/>
</mx:Application>
Related examples in the same category