-
29 Dec 2011 3:51 AM #1
Answered: What kind of buttons are on a Panel that is docked at the bottom?
Answered: What kind of buttons are on a Panel that is docked at the bottom?
Hello, I am trying to build buttons that look and act like the buttons on a tab.Panel that are docked at the bottom.
I was wondering what kind of buttons these are. I could not find anything in the documentation.
And is there a way to create from the Ext.Button a button that looks and acts like the buttons on a tab.Panel?
Thanks in advanced!, Regards Chris.
stylequestion.jpg
-
Best Answer Posted by chrismobile
Oke, I found the solution how to style the icons at this topic:
http://www.sencha.com/forum/showthre...abPanel-buttonAnd I got it working using not the Ext.Toolbar but using the Ext.tab.Bar instead.
This is the code I used to make it all work
Code:var tabBar = Ext.create('Ext.tab.Bar', { cls: Ext.baseCSSPrefix + 'tabpanel', docked: 'bottom', layout: { type: 'hbox', pack: 'center' }, scrollable: { direction: 'horizontal', indicators: false }, items: [ { title: 'home', iconCls: 'home' }, { title: 'activiteiten', iconCls: 'activiteiten' }, { title: 'contact', iconCls: 'contact'}, { title: 'agenda', iconCls: 'agenda', handler : function() { alert("click"); } }, { title: 'fotos', iconCls: 'photos' }, { title: 'bookmarks', iconCls: 'bookmarks', handler : function() { alert("click"); } } ] }); //use this to set an icon active tabBar.setActiveTab(2)
Greetings, Chris.
-
29 Dec 2011 7:17 AM #2
Oke, I found the solution how to style the icons at this topic:
http://www.sencha.com/forum/showthre...abPanel-buttonAnd I got it working using not the Ext.Toolbar but using the Ext.tab.Bar instead.
This is the code I used to make it all work
Code:var tabBar = Ext.create('Ext.tab.Bar', { cls: Ext.baseCSSPrefix + 'tabpanel', docked: 'bottom', layout: { type: 'hbox', pack: 'center' }, scrollable: { direction: 'horizontal', indicators: false }, items: [ { title: 'home', iconCls: 'home' }, { title: 'activiteiten', iconCls: 'activiteiten' }, { title: 'contact', iconCls: 'contact'}, { title: 'agenda', iconCls: 'agenda', handler : function() { alert("click"); } }, { title: 'fotos', iconCls: 'photos' }, { title: 'bookmarks', iconCls: 'bookmarks', handler : function() { alert("click"); } } ] }); //use this to set an icon active tabBar.setActiveTab(2)
Greetings, Chris.Last edited by chrismobile; 29 Dec 2011 at 10:34 PM. Reason: fixed it !


Reply With Quote