Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


Share this Page URL
Help

Skinning > Scale Nine - Pg. 278

278 Customizing the user interfaCe <mx:FormItem label="Password"> <s:TextInput/> </mx:FormItem> <mx:FormItem> <s:Button label="Submit"/> </mx:FormItem> </mx:Form> This works as we expect so we could say "mission accom- plished." But what if the form gets bigger? The result is shown in Figure 5.36 and this is probably not expected. As you can see the default behavior of the Flex framework is to stretch all the images to fit the dimensions of the form. There is a way to prevent this, called scale nine. scale nine figure 5.36 a form with a stretched background. Scale nine is an approach to formatting that allows defining nine areas of an image, as in Figure 5.37. This division allows us to instruct the rendering of fixed and stretchable areas, like the central one. The syntax to define these