默认布局和FIT布局的实例

<script type="text/javascript">
Ext.onReady(function(){
    new Ext.Panel({
        renderTo:"hello",
        width:500,
        heihgt:200,
        //layout:"fit",  //把注释去掉就属于FIT布局方式
        items:[{
        title:"one",
        html:'one is one'
        },{
        title:"two",
         html:'two is two'
        },{
        title:"three",
        html:'three is three'
        },{
        title:"four",
        html:'four is four'
        },{
        title:"five",
         html:'five is five'
        }]
});
  
});
    </script>
  </head>
 
  <body>
   
    <div id="Hello"></div>
  </body>
</html>

你可能感兴趣的:(html,ext)