PDA

View Full Version : Newbie: TabPanel



rmanchu
30 Jul 2009, 11:37 PM
I have searched the forums but I have not found a solution to this.

How to align the tabs (in the tab strip) of a TabPanel to center. The default aligns it left. I would like the tab strip to be center aligned.


____________|tab1|_|tab2|_|tab3|____________

wvmaaren
31 Jul 2009, 12:25 AM
I'm not sure! But I guess u have a alignment property!

check the Api documentation

rmanchu
31 Jul 2009, 12:52 AM
I tried < buttonAlign: 'center' > but that does not work.

rmanchu
31 Jul 2009, 12:55 AM
thought I would post the code as well.

=========

var tabsNumbering = new Ext.TabPanel({
renderTo: document.body,
activeTab: 0,
autoWidth: true,
height: 550,
plain: true,
// defaults: {autoScroll: true},
buttonAlign: 'center',
items:[
{
title: '<span style="font-size: larger;">Announcements</span>',
layout: 'vbox',
layoutConfig: {
align: 'center'
},
...

Condor
31 Jul 2009, 4:02 AM
This is not supported by default.

Maybe you can modify the code from this post (http://extjs.com/forum/showthread.php?t=66127) to center tabs.