Share on Google+Share on Google+

Panel layout container

Advertisement
Panel layout container are like HBox, VBox, canvas containers but let you add a title bar, a caption, a border also along with content area for its children.

Panel layout container

     

Panel layout container are like HBox, VBox, canvas containers but let you add a title bar, a caption, a border also along with content area for its children. By default, panel container arranges its children vertically but you can change its layout property to horizontal or absolute also.

<?xml version="1.0" encoding="utf-8"?>

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">

<mx:Panel x="50" y="50" title="Nature Pics" titleIcon="@Embed('assets/images/rose.jpeg')" headerHeight="30" borderColor="white" borderAlpha="1.0" width="449" height="150" backgroundColor="#FFE6FF" layout="horizontal" verticalAlign="middle">

<mx:Image width="100" height="76">

<mx:source>assets/images/Sunset.jpg</mx:source>

</mx:Image>

<mx:Image width="100" height="76">

<mx:source>assets/images/Blue hills.jpg</mx:source>

</mx:Image>

<mx:Image width="100" height="76">

<mx:source>assets/images/Water lilies.jpg</mx:source>

</mx:Image>

<mx:Image width="100" height="76">

<mx:source>assets/images/Winter.jpg</mx:source>

</mx:Image>

</mx:Panel>

</mx:Application>

Output:



Download the code:
PanelLayoutContainer.zip

Advertisements

Posted on: November 14, 2009 If you enjoyed this post then why not add us on Google+? Add us to your Circles

Share this Tutorial Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.

Discuss: Panel layout container  

Post your Comment


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 
Comments:0