zoukankan      html  css  js  c++  java
  • Flex4中使用HDividedBox,VDividedBox

    flex4中推荐使用spark组件来布局,所以在工具箱里把HDividedBox,VDividedBox这二个非常有用的东东给隐藏掉了,只能手动在source视图下手动写标签,如下:
    <?xml version="1.0" encoding="utf-8"?>
    <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" 
    			   xmlns:s="library://ns.adobe.com/flex/spark" 
    			   xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="400" minHeight="300">
    	<fx:Style>
    		@namespace s "library://ns.adobe.com/flex/spark";
    		@namespace mx "library://ns.adobe.com/flex/mx";		
    		global{font-size:18px;font-family:"微软雅黑"}
    	</fx:Style>
    	<s:Group right="20" left="20" top="20" bottom="20">
    		<s:layout>
    			<s:VerticalLayout/>
    		</s:layout>
    		<mx:HDividedBox width="100%" height="50%">
    			<s:TextArea text="左边的文本框" height="100%" width="50%" contentBackgroundColor="#F3EEEE"/>
    			<s:TextArea text="右边的文本框" height="100%" width="50%" chromeColor="#C3EBB6" contentBackgroundColor="#F3EEEE"/>		
    		</mx:HDividedBox>
    		
    		<mx:VDividedBox width="100%" height="50%">
    			<s:TextArea text="上面的文本框" width="100%" height="50%" chromeColor="#F0E676" contentBackgroundColor="#F0E676"/>
    			<s:TextArea text="下面的文本框" width="100%" height="50%" contentBackgroundColor="#F0E676"/>
    		</mx:VDividedBox>
    	</s:Group>	
    </s:Application>
    
    效果图
    作者:菩提树下的杨过
    出处:http://yjmyzz.cnblogs.com
    本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。
  • 相关阅读:
    Unity3D 学习笔记
    Python中os和sys模块
    合并两个排序的链表
    反转链表 难
    链表中倒数第k个结点
    调整数组顺序使奇数在偶数前 14
    javascript中this详解
    静态方法实例方法
    强制类型转换
    javascript类型判断方法
  • 原文地址:https://www.cnblogs.com/yjmyzz/p/2007607.html
Copyright © 2011-2022 走看看