Box (HBox VBox)--Kit box

Source: Internet
Author: User

The use of the Hbox, VBox components in box is described below. Create a new Mxml file with the command boxhv.mxml. Below is the detailed code for this file.

<?xml version= "1.0" encoding= "Utf-8"?>
<mx:application xmlns:mx= "Http://www.adobe.com/2006/mxml" layout= "vertical" verticalalign= "middle" horizontalalign= "Center"
Backgroundgradientcolors= "[0x000000,0x323232]" paddingtop= "0"
Fontfamily= "Arial" fontsize= "12"
>
<mx:panel title= "Horizontal assembly box" layout= "vertical" color= "0xffffff" borderalpha= "0.15"
Paddingtop= "Ten" paddingright= "paddingbottom=" "paddingleft=" horizontalalign= "Center" >
<mx:label width= "356" color= "0x323232" textalign= "center"
Text= "Below is a horizontal assembly box, in which the component arrangement is arranged horizontally"/>
<mx:hbox borderstyle= "SOLID" paddingtop= "ten" paddingbottom= "10"
Paddingleft= "Ten" paddingright= "color=" 0x707070 ">
<mx:button label= "button 1"/>
<mx:button label= "button 2"/>
<mx:button label= "button 3"/>
</mx:HBox>
</mx:Panel>

<mx:panel title= "Vertical Assembly Box" layout= "vertical" color= "0xffffff" borderalpha= "0.15"
paddingtop= "paddingright=" paddingbottom= "paddingleft=" horizontalalign= "Center" >
<mx:label width= "356" color= "0x323232" textalign= "center"
Text= "Below is a vertical assembly box, in which the components are arranged in a vertical arrangement"/>
<mx:vbox borderstyle= "SOLID" paddingtop= "ten" paddingbottom= "10"
Paddingleft= "Ten" paddingright= "color=" 0x707070 ">
<mx:button label= "button 1"/>
<mx:button label= "button 2"/>
<mx:button label= "button 3"/>
</mx:VBox>
</mx:Panel>
</mx:Application>
Screenshot after run:

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.