当前位置: 代码迷 >> Web前端 >> 格局之anchor布局
  详细解决方案

格局之anchor布局

热度:75   发布时间:2012-10-20 14:12:48.0
布局之anchor布局
<HTML>
<HEAD>
	<TITLE>使用EXT输出HelloWorld</TITLE>
	<!-- 导入extjs配置 … ... -->
	<link rel="stylesheet" type="text/css" href="./../ext/resources/css/ext-all.css"/>
	<script type="text/javascript" src="./../ext/adapter/ext/ext-base.js"></script>
	<script type="text/javascript" src="./../ext/ext-all.js"></script>
	<script type="text/javascript">
		Ext.onReady(function(){
			Ext.BLANK_IMAGE_URL='./../ext/resources/images/default/s.gif';
			var panel = new Ext.Panel({
				title: '父面板',
				layout: 'anchor',
				anchorSize: {width: 800,height: 600},
				renderTo: 'form',
				items:[{
					title: '面板一',
					html: 'pig',
					anchor: '50% 50%'
				},{
					title: '面板二',
					html: 'ba',
					anchor: '-5 30%'

				},{
					title: '面板三',
					html: 'jie',
					anchor: 'right 30%'
				}]
			});
			 	
		});
	</script>
</HEAD>
<body id="form">
</body>
</HTML>
?