PDA

View Full Version : TabPanel with differents size



Bouki
10 Mar 2011, 3:50 AM
Hi
I've a TabPanel fitting the screen wich contains multiple panels
I would like to set size for one of that panel only (and if tabpanel is too small, then use scroll because content can't be reduced).

So I've tried this :


new Ext.Panel({
title: 'Photo',
width: 1024,
height: 768,
autoScroll: true,
region: 'center',
html: '<div style = "width:1024px;height:768px;background:#000;"></div>'
});


however this doesn't work, scrolls are not appearing

walldorff
11 Mar 2011, 4:56 PM
This works:
var tabPanel = new Ext.TabPanel({
renderTo : Ext.getBody(),
frame : true,
activeTab : 0,
width : 400,
height : 200,
items : {
title : 'Photo',
width : 1024,
height : 768,
bodyStyle : 'background-color:#000;color:#fff;',
autoScroll : true,
html : '<div style="width:1024px;height:768px;">Hello world</div>'
}
});