PDA

View Full Version : Remove tab panel padding



PCSpectra
3 Aug 2010, 9:46 AM
I have a tab setup and in each one I have a single grid. The padding of the tab is throwing off the interface, is must be possible to remove that padding/margin using CSS or even better through the object API/config options but for the life of me I cannot find the required information.

Can someone point me in the right direction?

Cheers,
Alex

PCSpectra
3 Aug 2010, 10:51 AM
I have tried applying bodyStyle like this:


xtype: 'tabpanel',
activeTab: 0,
frame: true,
defaults: {autoHeight: true},
items:
[
{
title: 'Work Order',
bodyStyle: 'padding: 0px; margin: 0px',
items: [sequence_list_secondary]

},
{
title: 'Quotesheet',
html: 'This is the quotesheet grid controler here'

}
]

However this still does not make the grid flush with the tab panel. I found a thread that suggested using another panel inside tab but that didn't work either. I'm at a loss for ideas, anyone?

Cheers,
Alex

Animal
3 Aug 2010, 1:10 PM
Why oh why do you put your grid inside a no layout Panel?

Just use the grid as an item!

Elijah
3 Aug 2010, 2:26 PM
LOL Animal you don't like dealing with us noobs that much. Time and time again we shall make these mistakes B)

I have something like the following.


var myGrid = {
xtype:'grid',
title: 'Work Order',
layout: 'fit',
draggable: false,
stripeRows: true,
border:false,
viewConfig: {
forceFit:true
},
...
};so try something like



xtype:'tabpanel',

activeTab: 0,
frame: true,
defaults: {autoHeight: true},
items:
[
myGrid,

{
title:'Quotesheet',
html: 'This is the quotesheet grid controler here'
}

]
If I am wrong I'm sure the seniors will correct me.

Animal
3 Aug 2010, 9:52 PM
Well that's not even valid Javascript is it?

You just throw it into IE, and hope for the best?

kalor
24 Nov 2011, 2:00 PM
Give him a better option.