View Full Version : Cant get tabpanel to fill max height

18 Feb 2015, 9:22 AM
I am sorry, I have been trying to find a solution without asking. Everything I seem to try is failing. I just want the tab panel to take 100% height/width of its parent.

Ext.create('Ext.panel.Panel', {
renderTo: Ext.getBody(),
layout: {
align: 'stretch'
items: [
Ext.create('Ext.tab.Panel', {
items: [{
title: 'Foo',
html: 'Hello World!'
}, {
title: 'Bar',
html: 'Testingggggggg',
tabConfig: {
title: 'Custom Title',
tooltip: 'A button tooltip'

18 Feb 2015, 9:53 AM
Ok I finally got it working, but I had to give the Panel that renders to the body an explicit height. Is there a way to make this 100% height and width?

Ext.create('Ext.panel.Panel', {
renderTo: Ext.getBody(),
layout: 'fit',
border: 0,
height: 600,
items: ....

27 Feb 2015, 11:18 AM
Yes, you can do it with viewport, just replace the wrapping Ext.panel.Panel with Ext.container.ViewPort. :D